|
| 1 | +# OS2Web REST API module |
| 2 | + |
| 3 | +## Module purpose |
| 4 | + |
| 5 | +The module purpose is to provide URL's for fetching data via REST API. |
| 6 | + |
| 7 | +## How does it work |
| 8 | + |
| 9 | +After enabling module there is available URL's that could be used as REST API. |
| 10 | + |
| 11 | +Most of them are coming from [RESTful Web Services module](https://www.drupal.org/docs/8/core/modules/rest/overview) |
| 12 | +that is included in Drupal core. |
| 13 | + |
| 14 | +Module provides preconfigured REST sources and Views for fetching lists nodes |
| 15 | +and terms in JSON-format |
| 16 | +* /node/[node id]?_format=json - particular node |
| 17 | +* /rest/os2web/list/term - list of taxonomy terms |
| 18 | +* /rest/os2web/list/node/[taxonomy term id] - list of nodes filtered by |
| 19 | +[taxonomy term id] |
| 20 | + |
| 21 | + |
| 22 | +## Install |
| 23 | +Module is available to download via composer. |
| 24 | +``` |
| 25 | +composer require os2web/os2web_rest_api |
| 26 | +drush en os2web_rest_api |
| 27 | +``` |
| 28 | + |
| 29 | +## Update |
| 30 | +Updating process for OS2Web REST API module is similar to usual composer package. |
| 31 | +Use Composer's built-in command for listing packages that have updates available: |
| 32 | + |
| 33 | +``` |
| 34 | +composer outdated os2web/os2web_rest_api |
| 35 | +``` |
| 36 | + |
| 37 | +## Contribution |
| 38 | + |
| 39 | +Project is opened for new features and os course bugfixes. |
| 40 | +If you have any suggestion or you found a bug in project, you are very welcome |
| 41 | +to create an issue in github repository issue tracker. |
| 42 | +For issue description there is expected that you will provide clear and |
| 43 | +sufficient information about your feature request or bug report. |
| 44 | + |
| 45 | +### Code review policy |
| 46 | +See [OS2Web code review policy](https://github.com/OS2Web/docs#code-review) |
| 47 | + |
| 48 | +### Git name convention |
| 49 | +See [OS2Web git name convention](https://github.com/OS2Web/docs#git-guideline) |
0 commit comments