Postman Installation and hitting basic APIs


Follow below steps to to add Postman chrome's extension:
1. Launch chrome in your system and navigate to this URL: https://downloads.digitaltrends.com/postman/windows. You will get navigated to below screen:
2. Click on Download button shown in above screen, you will get prompt with below screen:
3. Do not click on above download button as it will download unnecessary softwares. Just click on the highlighted link i.e. No thanks, continue to download postman (Chrome Extension). After clicking you will get navigated to below screen:
4. After clicking on above highlighted link, you will get prompt with below screen. Here you click on Add to Chrome button.
5. After clicking on Add to Chrome, you will get prompt with below screen, here you click on Add App button:
6. Now in some time you will see postman tool got added and is shown as below:
7. In above screen, you are seeing two tabs, click on first one and you will get navigate to below screen:
8. Now Click on Launch app, you will get prompt with below screen:
9. Do not register, just click on the highlighted link shown above. You will get prompt with below screen::
10. Just close above prompt screen and you are now ready to hit APIs.

APIs details which all are used for explanation in our API Automation tutorials:

1. GET Request to fetch all available users: http://localhost:8081/users
2. GET Request to get specific user details whose Id is provided in URL itself: http://localhost:8081/users/1
3. GET Request to fetch specific user details whose Id is provided as Query Paramater: http://localhost:8081/users/?data=1

4. POST Request to add new User:

API: http://localhost:8081/users

Payload:

{ "id": 3, "name": "Sumesh", "dob": "2020-05-25", "addressDetails": { "houseNumber": "H-57", "aadharNumber": 327000, "addressLine1": "Mg Road", "addressLine2": "14th Cross-5", "landmark": "Landmark 1", "pin": 54, "officeAddress": { "buildingNumber": 5.2, "addressLine1": "XYZ-5", "addressLine2": "Bus Stand", "landMark": "Near 6 lane Line hotel", "cardId": "EMP-001", "pin": 1231 } } }
5. PUT Request to update user details

API: http://localhost:8081/user/1

Payload:

{ "name": "Erwin", "dob": "12-12-12" }
6. DELETE Request to delete available user using query parameter: http://localhost:8081/users?data=1

Comments

Popular posts from this blog

Prerequisite/Setup for Automation-Selenium/Appium/API using JAVA Maven Project