pdring - 1 month ago

Can the API module expose a stream as JSON with GET and PUT requests? I have a functional Angular demo using AG-Grid and dummy REST data which I would now like to couple to a PyroCMS installation.

ryanthompson - 1 month ago

The API module is ready only out of the box - and can expose any stream you want and decorate data too. However for putting information - you would wanna make your own endpoints which is also very easy.

https://pyrocms.com/documentation/api-module/2.0/usage/api-routes#defining-api-routes

ryanthompson - 1 month ago

There is the groundwork for saving / deleting in the API but I've not enabled it. Need to work on API permissions a little for the next version and will be able to support that as well out of the box.

pdring - 1 month ago

So is it indeed possible to update and delete stream entries through a REST API, just not out of the box? I see an increasing number of applications rely on this method.

ryanthompson - 1 month ago

That's correct, yes. Just define your own endpoints (which is a route/controller method).