PO

Postman API Resource Management for MCP Server

Manage Postman resources on your MCP server using the Postman API to create, update, and organize collections, environments, and monitors.

Quick Install
npx -y @postmanlabs/postman-api-mcp

Overview

The Postman API Resource Management MCP server is a lightweight proxy and orchestration layer that lets developer tools, agents, or local workflows manage Postman resources (collections, environments, and monitors) through a consistent Model Context Protocol (MCP) interface. It mediates requests between clients and the official Postman API, handling authentication, basic validation, and resource organization so clients don’t need to call the Postman API directly.

This server is useful when you want a single, controlled surface for programmatic access to Postman assets — for example, integrating collection provisioning into CI/CD, enabling an LLM agent to inspect and update test collections, or exposing curated endpoints to developer tooling without sharing the raw Postman API key. The project source and issues are available on GitHub (https://github.com/postmanlabs/postman-api-mcp).

Features

  • Proxy-based access to Postman API resources: collections, environments, and monitors
  • CRUD operations: create, read, update, delete, import/export for supported resources
  • Authentication handling using a single Postman API key configured on the server
  • Simple REST endpoints that can be consumed by automation scripts, CI pipelines, or agents
  • Input validation and basic error mapping to make client integration straightforward
  • Configurable server settings through environment variables

Installation / Configuration

Clone the repository, install dependencies, and configure environment variables. The examples assume a Node.js-based server.

  1. Clone and install:
git clone https://github.com/postmanlabs/postman-api-mcp.git
cd postman-api-mcp
npm install
  1. Create a .env file or set environment variables:
# .env
PORT=3000
POSTMAN_API_KEY=your_postman_api_key_here
POSTMAN_BASE_URL=https://api.getpostman.com
LOG_LEVEL=info
  1. Start the server (development):
npm run start
# or, if available:
node index.js
  1. Verify the server is running:
curl http://localhost:3000/health
# Expected: JSON status response

Note: The server forwards requests to the Postman API and uses the configured POSTMAN_API_KEY for authentication. Keep that key secure and do not embed it in client-side code.

Available Resources

The MCP server focuses on three primary Postman resource types. Each resource generally supports list, get, create, update, delete operations and additional actions such as import/export where applicable.

ResourceTypical endpoints / actions
Collectionslist, get, create, update, delete, import, export
Environmentslist, get, create, update, delete, import, export
Monitorslist, get, create, update, delete

Example endpoint patterns (implementation-specific):

  • GET /mcp/collections
  • POST /mcp/collections
  • PUT /mcp/collections/:id
  • GET /mcp/environments
  • POST /mcp/environments
  • POST /mcp/monitors

Always consult the server’s OpenAPI or README in the repository for exact routes.

Example requests

Create a collection (curl):

curl -X POST http://localhost:3000/mcp/collections \
  -H "Content-Type: application/json" \
  -d '{
    "name": "My API Tests",
    "description": "Generated by automation",
    "items": []
  }'

Update an environment:

curl -X PUT http://localhost:3000/mcp/environments/{{envId}} \
  -H "Content-Type: application/json" \
  -d '{
    "name": "staging",
    "values": [
      {"key":"api_base", "value":"https://staging.example.com", "enabled":true}
    ]
  }'

Create a monitor:

curl -X POST http://localhost:3000/mcp/monitors \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Daily smoke tests",
    "collection_id": "your-collection-id",
    "environment_id": "your-environment-id",
    "frequency": 1440
  }'

The MCP server will attach the configured Postman API key when forwarding these actions to the actual Postman API.

Use Cases

  • CI/CD test provisioning: Automatically create or update a Postman collection and environment before running pipeline tests, ensuring the execution environment reflects the latest config.
  • Agent-driven resource management: Allow an LLM-based agent or automated workflow to list collections and environments, then create monitors for scheduled checks without embedding raw Postman API details in the agent.
  • Centralized tooling surface: Provide a single internal API for teams to manage Postman assets with consistent validation and access control, instead of granting many users direct Postman API keys.
  • Import/export automation: Sync collections between a git-hosted repository and Postman by importing collection JSON into Postman through MCP endpoints as part of deployment or backup workflows.

Best Practices & Notes

  • Secure the POSTMAN_API_KEY: Restrict access to the MCP server and do not expose the API key in client-side code.
  • Rate limiting & retries: The Postman API enforces rate limits — implement exponential backoff and sensible retry logic in clients.
  • Validate payloads: While the server does basic validation, clients should ensure payloads conform to Postman resource schemas to avoid upstream errors.
  • Review the repository README and API spec for exact routes, authentication headers, and any environment-specific configuration before integrating.

For full implementation details, example clients, and issue tracking, see the project repository: https://github.com/postmanlabs/postman-api-mcp.