Recall & Review
beginner
What is a POST request in API testing?
A POST request is used to send data to a server to create or update a resource. It usually includes data in the request body.
Click to reveal answer
beginner
In Postman, where do you add the data for a POST request?
You add the data in the 'Body' tab of the Postman interface, usually in formats like JSON, form-data, or x-www-form-urlencoded.
Click to reveal answer
beginner
Why do we use POST requests instead of GET for sending data?
POST requests send data in the request body, which is more secure and can handle larger amounts of data. GET requests send data in the URL, which is limited and less secure.
Click to reveal answer
intermediate
What HTTP status code usually indicates a successful POST request?
The status code 201 means 'Created', indicating the POST request successfully created a resource. Sometimes 200 (OK) is also used.
Click to reveal answer
intermediate
How can you validate the response of a POST request in Postman?
You can write tests in the 'Tests' tab using JavaScript to check status codes, response body content, headers, and more.
Click to reveal answer
What is the main purpose of a POST request?
✗ Incorrect
POST requests send data in the request body to create or update resources on the server.
Where do you add the data payload in Postman for a POST request?
✗ Incorrect
The Body tab is where you add the data to send with a POST request.
Which HTTP status code indicates a resource was successfully created by a POST request?
✗ Incorrect
201 means 'Created', showing the POST request succeeded in creating a resource.
Why is POST preferred over GET for sending sensitive data?
✗ Incorrect
POST sends data in the body, keeping it hidden from the URL and browser history.
How can you check the response status code in Postman tests?
✗ Incorrect
The correct syntax to check status code 201 in Postman tests is pm.response.to.have.status(201);
Explain how to create and test a POST request in Postman.
Think about the steps from setting up the request to validating the response.
You got /6 concepts.
Describe the difference between POST and GET requests in simple terms.
Focus on where data is sent and the purpose of each request.
You got /5 concepts.