Postman (CRUD operations)

Reading Time: 3 minutes

Postman is the collaboration platform for API development. Postman simplifies each step of building an API and streamlines collaboration so you can create better APIs

CRUD operations

CRUD Meaning: CRUD is an acronym that comes from the world of computer programming and refers to the four functions that are considered necessary to implement a persistent storage application: create, read, update and delete.

Persistent storage refers to any data storage device that retains power after the device is powered off, such as a hard disk or a solid-state drive.

GET: This method retrieves the information identified by the request URI. The method used for read operations (the R in CRUD).

POST: Method used to instruct the server to accept the entity enclosed in the request as a new resource. The create operations typically mapped to this HTTP method.

PUT: This method requests the server to store the enclosed entity under the request URI. As per the HTTP specification, the server can create the resource if the entity does not exist. It is up to the web service designer to decide whether this behavior should be implemented or resource creation should only be handled by POST requests.

DELETE: The last operation not yet mapped is for the deletion of resources. The HTTP specification defines a DELETE method .

Using dummy api for performing reqres.in

Create

Create : (Post) Used to create a new resource, but can also modify the underlying state of a system.

Below is the example of creating a user . here URL :- https://reqres.in/api/users

Response :- 201

201 :- Success , means User created

Read


Read : (Get) Used to retrieve a represenataion of resource.

Below is the example of Reading all users from the api . here URL :- https://reqres.in/api/users?page=2

Response :- 201

200 :- Success , Data fetched

Below is the example of Reading single user from the api . here URL :- https://reqres.in/api/users/2

200 :- Success , Data fetched

Update

Update : (Put/Patch) Update an existing resource.

Below is the example of updating a user from the api . here URL :- https://reqres.in/api/users/2

201 :- Success

User updated

Delete

Deleted : (Delete) Delete a resource.

Below is the example of delete a user from the api . here URL :- https://reqres.in/api/users/2

201 :- Success

Data deleted

Conclusion

In this blog we learned about the Crud operation using postman

Written by 

Chiranjeev kumar is a Software intern at Knoldus. He is passionate about the java programming . He is recognized as a good team player, a dedicated and responsible professional, and a technology enthusiast. He is a quick learner & curious to learn new technologies. His hobbies include listening music , playing video games.