Postman First API Request
Postman First API Request
Now that you’re familiar with the interface, it’s time to make your first API request.
Creating a New Request
In the main interface, click on the New button at the top left corner and select Request.
Give your request a name (e.g., “My First Request”), and choose a collection to save it to or create a new collection.
Once you’ve named your request and selected the collection, click Save.
Setting Up the Request
In the Request URL field, enter the URL of the API endpoint you want to test.
For example, let’s use the following API for testing.
- https://postman-echo.com/get
Enter https://postman-echo.com/get in the URL field.
Select the HTTP method you want to use. For this example, choose GET (to retrieve data from the API).
Sending the Request
After setting up the request, click the Send button to execute it. Postman will contact the server and display the response below.
Viewing the Response
After the request is sent, the response will appear in the lower section of the window. You will see the Status Code (e.g., 200 OK), the Response Time, and the Response Body.
The response body should contain the data returned by the API, usually in JSON format. You can also view the response in other formats, such as raw text or pretty (formatted JSON).
Congratulations! You’ve just made your first API request using the Postman tool.