Provides comprehensive tools for managing Postman workspaces, collections, requests, responses, and monitors. Enables creating and updating API collections, adding requests with sample responses, and executing monitor runs programmatically through the Postman API.
Postman MCP Server
Expose the Postman API as a set of [Model‑Context Protocol (MCP)] tools. This project wraps core Postman API endpoints into well‑typed tools that can be invoked by your favourite MCP host (Codex, Claude Desktop, etc.). Use it to list workspaces, manage collections, edit requests and responses (examples) and even run monitors directly from chat.
Features
Tool | Description |
| List every workspace the authenticated API key can access. Uses
【260284429113736†screenshot】. |
| Fetch details of a single workspace by ID. Includes arrays of collections, environments, mocks and monitors【260284429113736†screenshot】. |
| Given a workspace ID, return the collection references contained in that workspace (UID, name, owner). Internally calls
and extracts the
array. |
| Create a new collection from a Postman Collection v2 object. Accepts an optional
query parameter to save the collection into a specific workspace【516251068010627†screenshot】. |
| Retrieve a complete collection definition by its UID using
【260252579404281†screenshot】. |
| Replace an existing collection with a new Collection v2 payload via
【671023381355334†screenshot】. |
| Add a new request to a collection. Sends
with a
object, allowing you to append or insert requests into a collection. |
| Fetch a single request item from a collection with
(path variables:
,
)【996776406622354†screenshot】. |
| Replace an existing request definition using
. |
| Create a sample response (example) for a request. Uses
and sends a
body. |
| Get a response example by ID via
. |
| Update an existing example using
. |
| Execute a monitor synchronously. Invokes
, waits for completion and returns run results【322691760681237†screenshot】. |
API constraints
All endpoints require a valid API key. Set
POSTMAN_API_KEY
in your environment or.env
file.The base URL defaults to
https://api.getpostman.com
but can be overridden withPOSTMAN_BASE_URL
(useful for EU or India data regions).When creating or updating collections, the body must conform to the Postman Collection v2 specification. At a minimum include an
info
object with aname
and anitem
array.
Getting started
Local development
Clone this repository and install dependencies:
cd postman-mcp npm installCopy
.env.example
to.env
and add your Postman API key and (optionally) a default workspace:POSTMAN_API_KEY=pmak-xxxxxxxxxxxxxxxxxxxx POSTMAN_BASE_URL=https://api.getpostman.com DEFAULT_WORKSPACE_ID=Run the server in development mode:
npm run dev
The server listens on stdin/stdout for JSON‑RPC messages from your MCP host.
Docker
Build and run using the provided Dockerfile:
Integrating with Codex (VS Code)
Add an entry to your ~/.codex/config.toml
:
Reload the Codex extension; new tools prefixed with postman
will appear in the command palette or chat UI.
Example usage
To list workspaces:
Create a new collection in a workspace:
Add a request to an existing collection:
Create a sample response for the above request:
Run a monitor synchronously and view its results:
Extending
This MCP server intentionally focuses on core Postman entities. You can extend it further by adding tools for:
Environments – list, create and update environment variables.
Mocks – manage mock servers and their associated examples.
Monitors – create, update and delete monitors as well as retrieve run results.
User information – read API usage and team membership data.
Feel free to fork and add more endpoints to suit your workflow!
This server cannot be installed
remote-capable server
The server can be hosted and run remotely because it primarily relies on remote services or has no dependency on the local environment.
Enables interaction with Postman workspaces, collections, requests, responses, and monitors through the Postman API. Allows users to manage API collections, create and update requests/responses, and execute monitors directly from chat.