On the SitePoint PHP blog author Younes Rafie has returned with another tutorial, this time with a focus on how Postman can help master your API workflow by making use of several of the features it already includes.
Building good APIs is hard, and anyone who had the chance to do so can relate to this. A project can easily grow to become a mess. One can keep trying to adopt an approach to make it more enjoyable, like trying a documentation-first workflow, but something always feels clumsy.
I was trying out Postman lately, a tool we’ve briefly covered before, and I discovered that they’re doing a great job by providing an integrated environment for different components of an API, like authorization, testing, documentation, versioning, etc.
He then goes through the use of the tool, including screenshots along the way for:
- Making requests
- Environment Variables
- Validating JSON schemas
- Working with collections
The post finishes up with a look at generating documentation for the API using Postman's "View in Web" feature including integrating example calls and publishing it. There's also a look at exporting and importing data and a few links to some other helpful resources.