4 ms·
>That POST is actually meant for updates and PUT is meant for new entities No.. So any creation or update can be a POST. If your operation is idempotent, then
by voidlogic 10y ago
>That POST is actually meant for updates and PUT is meant for new entities
No.. So any creation or update can be a POST. If your operation is idempotent, then you can make it a PUT. If you take the subset of POSTS that are idempotent in your application, this is what could be made a PUT.
So a set operation foobar=50, would could be a POST, but since its idempotent, it could also be a PUT.
A increment operations foobar++, would have to be a POST, but could not be a PUT since it is not idempotent.