Greetings! I’m excited to share how I have been utilising the Postman’s features while working.
As a full stack developer, I am often required to Develop, Test and Integrate APIs to the codebase. When I started working on the Team’s project, each member was using their own instance of APIs for testing. I stepped in to bring the team on the same platform to work collaboratively.
As they say, DRY (Don’t Repeat Yourself), same also applies when a team works individually.
While working, I also got to learn some awesome features that I, now, use on daily basis. You might be using the CodeGen feature of Postman to convert your request in Postman to use it in your code. But did you know you can also paste a curl command in a URL and Postman autopopulates the request URL, Body Data and Headers by itself. I use this feature along with DevTools. I copy a sent request from Networks tab
as cUrl
and pastes in Postman. This helps me autopopulate the fields and headers I passed while sending the request. Then I can simply modify the request in Postman. This often helps me while updating a certain data.
Another feature I often use in Postman is its Workflow and Post Response Scripting. One example
is for most of my work, a user is required to be authenticated and authorized using an Authorization token. To generate this token I call a POST request login user
which returns a Json object with accessToken in its Key-Value pair. To automate the Authorization task, I used Post Response Script to parse the json to get accessToken value and stored as Environment Variable. Then I passed this Environment Variable to all requests headers as Bearer {{accessToken}}
to use it dynamically.
But guess what? I generated this specific Post Script using PostBot. We also use PostBot for API Documentation as well. We work in different environments, switching between Local, Dev and Master as required. And most of the tasks in APIs are are easily streamlined via collaboration tools.
To conclude, I have been using Postman in API development to Functional Testing. and throughout this API journey I also got to learn a lot. And also got the chance to share with the team and community.
Thanks for reading it till the end. I wish you also got to learn something new from my post.
I have also created a video, demonstrating the features. Hope you like it