3 ms·
> understand why the thing at the end of a GET or PUT url should be a "thing" not an operation what do you mean by this?
by bobthebuilders 5y ago
> understand why the thing at the end of a GET or PUT url should be a "thing" not an operation
what do you mean by this?
- RegW 5y agoThe URL identifies an entity. In the old static website days this meant a file - a html file or an image on a file system. With REST, the idea was to create a virtual filesystem and take advantage of the HTTP infrastructure already in place with regards to caching etc. So often when I get involved in "REST" projects, I find URLs that include words like "update" or "add", or where the GET returns JSON with a completely different shape to that the PUT accepts. Does it matter? If you don't cache anything - probably not, but it isn't REST as it was understood.