In my opinion the REST API needs to be improved, as it stands it is not
very RESTful. A RESTful API uses the HTTP methods as follows:
POST is used to create a resource on the server
GET is used to retrieve a resource
PUT is used to change the state of a resource or to update it
DELETE is used to remove or delete a resource
There are currently many places where these methods are used incorrectly
and thus confusingly.
Before heading off down the route of redefining the REST API I'd like to
understand if it is used or not.
My suspicion is that it is not used a great deal (indeed in trying to
use it this last few days I have found that parts of it just don't
work). Examining the Moodle plugin the REST API is not used at all
(there are todo items all over it to change the code to use the REST API).
Can we consider rebuilding it now before people start to adopt it?
Should we instead adopt a deprecate and replace approach?
Ross