-
Improvement
-
Resolution: Won't Do
-
Minor
-
None
-
4.3
-
None
-
MOODLE_403_STABLE
This issue is to explore the idea of creating a new REST Web Service endpoint.
Some pertinent points:
- At this point this issue is exploratory in nature. No decisions have been made about the nature or direction of this work
- A new REST endpoint would not immediately replace our existing external services system but they would co-exist for some considerable time
Initially identified requirements include:
- using valid/correct method verbs for actions, that is:
- GET = fetch
- POST = create
- PUT = update
- DELETE = delete
- PATCH = apply changes (basically update)
- HEAD = information
- OPTIONS = fetch available actions
- correct response codes, for example:
- 200 = OK
- 403 = Access denied
- 404 = Not found
- 405 - invalid verb
- etc.
Other thoughts:
- remove requirement for a db/services.php type of definition
- the API should be self-documenting
- ideally it should also be capable of creating a Postman-compatible collection for import into Postman and similar
- Ideally should generate a Swagger UI
- Support OAuth 2.0 authorization (or cookie)