Monitors in Postman and How to Set Up Monitoring Over Collections in Postman

Introduction

You can automate the testing and monitoring of your APIs with Postman's useful feature of being able to monitor collections of API requests. To help you assure the dependability and performance of your APIs, we'll walk you through the process of setting up monitoring over collections in Postman in this blog article.


Why is monitoring API collections essential?


Monitoring API collections in Postman is essential because of below reasons:

  • Automated testing: This feature enables you to conduct a specified set of queries at certain intervals to automate the testing of your APIs. This assists in identifying problems early in the development cycle.
  • Tracking performance: By keeping tabs on response times and error rates over time, you can keep an eye on how well your APIs are working. This information is essential for locating problems and implementing fixes.
  • Alert notifications: When a collection run experiences failures or deviates from expected behavior, Postman may deliver alerts, enabling you to take immediate corrective action.

 

Must have's

Make sure you have the following criteria before you begin:

  • You must have a Postman account in order to utilize the monitoring function.
  • Create an API collection if you wish to track a particular set of API requests. Before continuing, create one collection if you haven't already done.


Setting up a monitor for the collection of requests

To set up monitoring for your API collection, follow these steps:

1. Open Postman and go to your workplace where your collection exists and you want to set up a Monitor over it.




2. Go to the Monitoring Dashboard.

After logging in, select the "Monitor" tab in the left sidebar to move to the "Monitoring" section.


3. Set up a new Monitor.

To create a new monitoring environment, click the "New Monitor" button.




4. Setup Monitor Settings

The following details must be entered into the monitor configuration:
















  • Name: Provide your monitor with an easily recognizable name.

  • Collection: Select the existing API collection on which you want to setup a monitor.
  • Collection tag: Keep it as it is "CURRENT" (No change).
  • Environment: Choose the environment in which you want to run the collection. You can create new environments from the "Environments" tab in Postman.

  • Monitor Type: Choose from "Continuous Integration" and "Monitoring." While monitoring conducts the collection at predetermined intervals, continuous integration executes it whenever changes are made. (Continuous Integration is paid feature)






  • Data file and Variables: Select CSV or JSON data file if you have for the data driven testing and Define any necessary variables for your collection. These might be testing-specific values or environment-specific variables.
  • Frequency of execution: Establish how frequently you want the collection to run. Options like hourly, daily, weekly, etc. are available for selection. Here we have selected weekly and on every Sunday at 8:00 am.
  • Region: Keep it as Automatically select region. (Manual region selection is paid feature)
  • Alert notification and Execution report over email: Configure your preferences for receiving notifications about test results. You may combine other services or get updates through email. Here, I have given our email address softwaretestingbypassion@gmail.com for reports and alerts. We can put multiple email addresses here.

  • Retry if fails, Set request timeout & Set delay between requests: We can make use of these options in case required.


5. Click on 'Create Monitor' and monitoring for your collection has started.

Once you've finished setting everything up, you may start the monitoring procedure by clicking "Create Monitor" button.











6. Set up alert notifications.

You may define alerting options in the monitor settings to get notifications for failed tests or other problems. This guarantees that you'll be informed right away if there are any issues with your APIs.


7. Review monitoring results and logs.

In Postman's "Monitoring" feature, you can keep track of how your collection runs are doing. You may see details on the most recent runs, test results, and any failures that came up while testing here.

Monitor's collection execution reports and detail logs along with execution history shared over the email provided by us is shown below:






















Summary

Every API development and testing process benefits from the habit of setting up monitoring over collections in Postman. You may track performance, automate testing, execute your regression suites more often and get notifications when problems appear. Now, it's your turn to get your hands dirty and setup your own monitors over postman collections.

Keep learning, keep exploring!


Popular posts from this blog

Software Testing Job Updates: Your Gateway to Exciting Opportunities.

A Comprehensive Guide on How to Prepare a Well-Structured Test Plan for Software Testing

Important API Testing Interview Questions

Manual to Automation Testing: A Complete Beginner's Roadmap.

Mastering JIRA: A 15-Day Learning Plan for Project and Test Management

Linux and Unix Commands, Shell Scripting Concepts, Operating System, for Beginners and Experts - The Essential Linux and Unix Handbook