2026-02-20 11:58:33 -08:00
<p align="center">
<img src="https://voyager.postman.com/logo/postman-logo-orange.svg" alt="Postman" width="320">
</p>
2026-02-02 11:05:54 -08:00
# Postman Plugin for Claude Code
2026-02-19 13:16:42 -08:00
The Postman Plugin provides a single, simple install for Claude Code. It provides full API lifecycle management, and best practices when working with Postman APIs.
2026-02-20 11:58:33 -08:00
<p align="center">
2026-02-20 12:04:47 -08:00
<img src="assets/postman-plugin-sync.gif" alt="Postman plugin syncing code -> collection" width="800">
2026-02-20 11:58:33 -08:00
</p>
## What's included:
2026-02-19 13:16:42 -08:00
- Commands for setting up the Postman MCP Server (no more manual installs!), working with Collections, Tests, Mock Servers, and generating code and documentation from Collections
- Skills for Postman Routing, API best practices, and API OWASP security reviews
2026-03-09 15:48:55 -07:00
- Agent for reviewing API production readiness and providing recommendations based on the <a href="https://www.postman.com/ai/90-day-ai-readiness-playbook/">Postman API Readiness Guide</a>.
2026-02-02 11:05:54 -08:00
## Installation
2026-02-12 18:06:48 -08:00
Clone the repo and load it as a local plugin:
```bash
git clone https://github.com/Postman-Devrel/postman-claude-code-plugin.git
```
Then start Claude Code with the plugin loaded:
2026-02-12 17:55:41 -08:00
```bash
2026-02-12 18:06:48 -08:00
cd your-api-project/
claude --plugin-dir /path/to/postman-claude-code-plugin
2026-02-02 11:05:54 -08:00
```
2026-02-12 17:55:41 -08:00
## Quick Start
1. Set your API key:
```bash
export POSTMAN_API_KEY=PMAK-your-key-here
2026-02-02 11:05:54 -08:00
```
2026-02-12 18:06:48 -08:00
Add it to your shell profile (`~/.zshrc` or `~/.bashrc` ) to persist across sessions.
2. Start Claude Code with the plugin:
```bash
claude --plugin-dir /path/to/postman-claude-code-plugin
```
2026-02-02 11:05:54 -08:00
2026-02-12 18:06:48 -08:00
3. Run setup:
2026-02-12 17:55:41 -08:00
```
/postman:setup
```
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
That's it. The plugin auto-configures the Postman MCP Server, verifies your connection, and lists your workspaces. You're ready to go.
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
Get your API key at [postman.postman.co/settings/me/api-keys ](https://postman.postman.co/settings/me/api-keys ).
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
## Commands
2026-02-02 11:05:54 -08:00
2026-02-20 11:58:33 -08:00
<p align="center">
2026-02-20 12:04:47 -08:00
<img src="assets/postman-plugin-codegen.gif" alt="Postman Plugin generating code from a collection" width="800">
2026-02-20 11:58:33 -08:00
</p>
2026-02-12 17:55:41 -08:00
| Command | What It Does |
|---------|-------------|
| `/postman:setup` | Configure API key, verify connection, select workspace |
| `/postman:sync` | Create or update Postman collections from OpenAPI specs |
| `/postman:codegen` | Generate typed client code from any Postman collection |
2026-03-26 11:50:02 +05:30
| `/postman:search` | Find APIs across your org's private network, your workspaces and the public Postman network |
2026-02-12 17:55:41 -08:00
| `/postman:test` | Run collection tests, diagnose failures, suggest fixes |
| `/postman:mock` | Create mock servers for frontend development |
| `/postman:docs` | Generate, improve, and publish API documentation |
| `/postman:security` | Security audit against OWASP API Top 10 |
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
## What You Can Do
2026-02-20 11:58:33 -08:00
<p align="center">
2026-02-20 12:04:47 -08:00
<img src="assets/postman-plugin-mock-server.gif" alt="Postman Plugin creating a mock server to be used in code to mock an API" width="800">
2026-02-20 11:58:33 -08:00
</p>
2026-02-12 17:55:41 -08:00
### Sync your API to Postman
2026-02-02 11:05:54 -08:00
```
2026-02-12 17:55:41 -08:00
"Sync my OpenAPI spec with Postman"
→ Detects local spec, creates/updates collection, sets up environment
2026-02-02 11:05:54 -08:00
```
2026-02-12 17:55:41 -08:00
### Generate client code from private APIs
2026-02-02 11:05:54 -08:00
```
2026-02-12 17:55:41 -08:00
"Generate a TypeScript client for the payments API"
→ Reads your Postman collection, detects project language, writes typed code
2026-02-02 11:05:54 -08:00
```
2026-02-12 17:55:41 -08:00
### Search across your workspace
2026-02-02 11:05:54 -08:00
```
2026-02-12 17:55:41 -08:00
"Is there an endpoint that returns user emails?"
→ Searches private collections, drills into endpoint details, shows response shapes
2026-02-02 11:05:54 -08:00
```
2026-02-12 17:55:41 -08:00
### Run API tests
```
"Run the tests for my User API collection"
→ Executes collection, parses results, diagnoses failures, suggests code fixes
```
### Create mock servers
```
"Create a mock for frontend development"
→ Generates missing examples, creates mock, provides integration config
```
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
### Audit API security
```
"Run a security audit on my API"
→ 20+ checks including OWASP Top 10, severity scoring, remediation guidance
```
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
### Check if your API is agent-ready
```
"Is my API ready for AI agents?"
→ 48 checks across 8 pillars, scored 0-100, prioritized fix recommendations
```
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
## Auto-Routing
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
You don't need to remember command names. The plugin's routing skill detects your intent and runs the right command:
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
- "Sync my collection" routes to `/postman:sync`
- "Generate a client" routes to `/postman:codegen`
- "Check for vulnerabilities" routes to `/postman:security`
- "Is my API agent-ready?" triggers the readiness analyzer
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
## API Readiness Analyzer
2026-02-02 11:05:54 -08:00
2026-02-20 11:58:33 -08:00
<p align="center">
2026-02-20 12:04:47 -08:00
<img src="assets/postman-plugin-api-ai-check.gif" alt="Postman Plugin analyzing your API for AI Readiness" width="800">
2026-02-20 11:58:33 -08:00
</p>
2026-02-12 17:55:41 -08:00
The built-in readiness analyzer evaluates APIs for AI agent compatibility across 8 pillars:
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
| Pillar | What It Checks |
|--------|---------------|
| Metadata | operationIds, summaries, descriptions, tags |
| Errors | Error schemas, codes, retry guidance |
| Introspection | Parameter types, required fields, examples |
| Naming | Consistent casing, RESTful paths |
| Predictability | Response schemas, pagination, date formats |
| Documentation | Auth docs, rate limits |
| Performance | Rate limit headers, caching, bulk endpoints |
| Discoverability | OpenAPI version, server URLs |
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
**70%+ with no critical failures = Agent-Ready.**
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
## Requirements
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
- Claude Code v1.0.33+
- Postman API key (`POSTMAN_API_KEY` environment variable)
- No Python, Node, or other runtime dependencies
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
## How It Works
2026-02-02 11:40:23 -08:00
2026-02-12 17:55:41 -08:00
The plugin bundles a `.mcp.json` file that auto-configures the [Postman MCP Server ](https://github.com/postmanlabs/postman-mcp-server ) when installed. All commands communicate with Postman through 111 MCP tools. No scripts, no dependencies, pure MCP.
2026-02-02 11:40:23 -08:00
2026-02-02 11:05:54 -08:00
## License
2026-02-12 17:55:41 -08:00
Apache-2.0
2026-02-02 11:05:54 -08:00
2026-03-09 15:48:55 -07:00
## See Also
- [Postman Plugin for Cursor ](https://github.com/Postman-Devrel/cursor-postman-plugin ) - Same capabilities, adapted for Cursor IDE
- [Postman Agent Skills ](https://github.com/Postman-Devrel/agent-skills ) - Portable skills for any skills.sh-compatible agent
- [Postman Cursor Rules ](https://github.com/Postman-Devrel/postman-cursor-rules ) - Lightweight MCP config + rules for Cursor
2026-02-12 17:55:41 -08:00
## Links
2026-02-02 11:05:54 -08:00
2026-02-12 17:55:41 -08:00
- [Postman MCP Server Docs ](https://learning.postman.com/docs/developer/postman-mcp-server/ )
- [Get a Postman API Key ](https://postman.postman.co/settings/me/api-keys )
- [Postman Status ](https://status.postman.com )