Advanced dev

Testing Backend APIs with Postman

Outline

What is Postman?

Postman is a useful tool for testing the functionality of API endpoints. Besides providing a friendly user interface for constructing HTTP requests (as opposed to using command line tools like curl or wget), Postman also gives us the ability to write tests against the responses of requests to see if the server is returning the correct results. Requests constructed in Postman can also be bundled into a collection and easily exported or shared, making Postman great for collaborating on and sharing API specifications with others. Postman collections can also be used with continuous integration systems so that the same collection used to test an API locally while developing can also be used to determine whether or not the codebase should be pushed live onto production.

Installing Postman

Before we can get started with Postman, we'll need to make sure we have it installed first. Postman can be installed natively on macOS and Windows (Linux is coming soon!) and can also be installed as a stand-alone Chrome extension on platforms that support Chrome.

Install the lastest version of Postman from here

If you're having trouble installing Postman, check out the installation instructions for Chrome or native

With Postman installed, we're ready to get our hands dirty and start making requests! In the next section, we'll go over the different parts of Postman's user interface, and how to use Postman to make our first HTTP request.

 

I finished! On to the next chapter