Google News
logo
Rest API - Interview Questions
What’s the difference between PUT and POST operations in Rest API?
PUT POST
The PUT method is a call when you have to modify a single resource, which is part of resource collection. POST method is a call when you have to add a child resource under resource collection.
The PUT method is idempotent POST method is not idempotent
PUT for UPDATE operations. POST for CREATE operations.
If the PUT request is used more than one time, the results will remain the same. If a POST request is used multiple times, the results will be different.
PUT works as specific. POST work as abstract.
Advertisement