Difference between PUT and POST
PUT modifies a resource on the web server. Typically,
data is sent with a
PUT request that defines the content of the resource.
A POST does not modify such a resource, but rather uploads data for being processed by the web server.
A POST is sometimes used to create new resource, yet with a different URL than being used in the request.
In such scenarios, a
PUT might be considered analogous to an SQL
update statement and a
POST to an
insert statement.
If a new resource was created, the answer's
status code typically is
201 Created.
Status codes
The
status code 501 (Not Implemented) indicates that the server either does not recognize or has no implementation for the specific method.
405 (Method not allowed) indicates that the method is recognized and implemented, but not allowed for the requested resource.