For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Postman
PricingEnterprise
Contact SalesSign InSign Up for Free
HomeDocs
HomeDocs
      • Overview
        • Overview
        • Run tests manually
        • Run tests on a schedule
        • Run tests in CI/CD pipelines
        • Run tests with monitors
Postman API Platform

Product

  • Postman Overview
  • Enterprise
  • Spec Hub
  • Flows
  • Agent Mode
  • API Catalog
  • Fern
  • Postman CLI
  • Integrations
  • Workspaces
  • Plans and pricing

API Network

  • App Security
  • Artificial Intelligence
  • Communication
  • Data Analytics
  • Database
  • Developer Productivity
  • DevOps
  • Ecommerce
  • eSignature
  • Financial Services
  • Payments
  • Travel

Resources

  • Postman Docs
  • Academy
  • Community
  • Templates
  • Intergalactic
  • Videos
  • MCP Servers

Legal and Security

  • Legal Terms Hub
  • Terms of Service
  • Postman Product Terms
  • Security
  • Website Terms of Use

Company

  • About
  • Careers and culture
  • Contact us
  • Partner program
  • Customer stories
  • Student programs
  • Press and media
Twitter iconLinkedIn iconGithub iconYouTube iconInstagram iconDiscord icon
Download Postman
Privacy Policy

© 2026 Postman, Inc.

On this page
  • Monitor an API endpoint
  • Monitor an entire API
  • Run API tests
  • Monitor HTTP response codes
  • Monitor latency
Tests and scriptsRun and automate tests

Run API tests using Postman Monitors

||View as Markdown|
Was this page helpful?
Previous

Run API tests in your CI/CD pipeline using Postman

Next

Application Inventory overview

Built with

With Postman Monitors, you can continuously check the health and performance of your APIs, automatically running Postman tests when the monitor is triggered to run. When you set up a monitor, choose a collection with the requests and tests you want to run. You can choose if you’d like the monitor to run on a schedule or only run when triggered by the Postman CLI. You’re notified if a test fails, experiences an error, or times out, and all results are recorded on the monitor’s results.

The following are some ways you can use monitors to test your APIs and ensure they’re functioning correctly.

For examples of monitors in action, visit the Postman API Monitoring Examples public workspace to find example collections for some common monitoring use cases. You can fork the collection to collaborate on it in your own workspace.

Monitor an API endpoint

To monitor an API endpoint, create a collection with one or more requests for that endpoint, along with tests to validate the responses. You can include different variations of the request, such as query parameters, headers, or request bodies. This enables you to verify how the endpoint behaves under different conditions.

Monitors run the collection and your tests to help ensure the endpoint is working as expected over time. To learn more about writing tests, see Write scripts to test API response data in Postman.

Monitor an entire API

To monitor an entire API, create a collection with multiple requests that represent important endpoints and workflows. Use environment variables to manage shared values like the base URL.

You can also pass data between requests to simulate real-world usage. This enables you to validate how different parts of your API interact and ensure everything works together as expected.

Run API tests

When testing APIs with dependent requests, you can save part or all of a response as a variable and reuse it in later requests. This is useful for passing data such as IDs, tokens, or other values between requests.

Postman stores variables as strings. To work with complex data like objects or arrays, convert them to a string using JSON.stringify() before saving them, and use JSON.parse() to read them later. Once stored, you can reuse this value in subsequent requests, for example as part of a request body.

1// Set the value
2pm.environment.set("data", JSON.stringify({ id: 123 }));
3
4// Get the value
5const data = JSON.parse(pm.environment.get("data"));

Monitor HTTP response codes

You can validate HTTP response status codes in your post-response scripts.

1pm.test("Status code is 200", function () {
2 pm.response.to.have.status(200);
3});

Monitor latency

You can validate how long requests take to complete in post-response scripts. Add tests to ensure response times stay within an acceptable threshold:

1pm.test("Response time is acceptable", function () {
2 // responseTime is in milliseconds
3 pm.expect(pm.response.responseTime).to.be.below(1000);
4});