First 5 Things to Try if You’re New to Postman

Avatar

New to Postman? Welcome!

Even though there’s a ton of developers already using Postman everyday, the number of new users just now discovering Postman is mind-boggling ?.

If you’re reading this, I’ll assume you’ve already downloaded the Postman app and created a Postman account. Maybe you’ve sent a request, and inspected the response. Maybe you’ve created a collection already. Maybe not.

At this point, I would normally welcome you into the proverbial Postman fold, step-kicking with jazz-hands, and sing about new features to explore.

Due to the technological limitations of this blog post format, instead, I’ll just tell you with written words—the first 5 things to try if you’re new to Postman.

First 5 things to try if you’re new to Postman

#1 Send a request

Most everybody knows Postman as an HTTP client—a handy way to send a request and receive a response. If you haven’t already done this, go ahead and try it out. Hit your favorite endpoint and inspect your response. Play around with different HTTP verbs, headers, and auth types.

If you don’t have a favorite endpoint at the ready, the Postman Echo collection is included in your Postman app download. It’s a good way to try out different request types.

#2 Write a test

For a lot of people, Postman is synonymous with API testing. For some, that might mean sending and inspecting a response like we did in Step #1. It could also mean writing assertions to validate that an endpoint is returning the appropriate responses. It can also mean setting up logic to mirror your workflow and automating the tests.

The easiest way to get started with writing tests in Postman is to take a look at the snippets on the right side of the Tests tab. Clicking on a snippet will append the JavaScript code into the editor. If you’re comfortable writing your own tests, or updating the boilerplate code, the world is your oyster!

Send your request again, and now you can see the results of your test on the bottom, under the corresponding Tests tab in the response viewer.

Dig deeper with this blog post about writing tests.

#3 Create and run a collection

Collections are the cornerstone for all advanced Postman features. At its simplest, a collection is a way to group together requests and run those requests in a pre-determined sequence. In all its glory, a collection is an executable description of an API.

Save your example request to a collection, and maybe add a few more if you feel like it. Click on the chevron (>) next to the collection name, and hit the blue Run button to open the collection runner in a new window.

When you run your collection in the Postman app with the Collection Runner, you will see the requests being sent and the tests running.

Dig deeper with this blog post about the collection runner.

#4 Chain your requests

You can chain requests so that you can use the first request’s response in the next request. Is it magic? No, it’s the Postman sandbox.

Once you create and select an environment, you can store information in key-value pairs within a Postman environment. Let’s try it out.

Use the pm.* API to set and get environment variables in the scripting sections. Under the Tests tab, set an environment variable with pm.environment.set("variableName", variableValue). Now that you’ve initialized the variable, you can use this value in any subsequent requests in the text sections like {{variableName}} or in the scripting sections like pm.environment.get("variableName").

Dig deeper with this blog post about chaining requests.

#5 Take it further

Once you’ve mastered those Postman basics, try these out for further study:

Or level up your Postman game with one of our advanced features:

API documentation with Postman

Fake APIs for real developers

API monitoring with Postman

Team collaboration with Postman

Dig deeper into these concepts with How Postman feeds my sushi addiction ?


Run into roadblocks? Check out these helpful resources:

What do you think about this topic? Tell us in a comment below.

Comment

Your email address will not be published. Required fields are marked *


This site uses Akismet to reduce spam. Learn how your comment data is processed.

1 thought on “First 5 Things to Try if You’re New to Postman

    Avatar

    I like this, I already use Postman to test the VisiFIle API. Thanks!