run-collection

A command that runs Postman collection tests through the command line. A Postman collection is a saved group of API requests and checks.

In plain words
What is it for?
Use it to find a collection, run it with options such as an environment or request timeout, and report or investigate failed requests.
Why use it?
It verifies API endpoints together and makes failures easier to locate through pass counts, error messages, and status codes.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/postman-devrel/postman-claude-code-plugin/run-collection
Clone the repo
git clone --depth 1 https://github.com/Postman-Devrel/postman-claude-code-plugin
Per session 8 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 313 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00008 $0.00313
Opus 5 $0.00004 $0.00156
Sonnet 5 $0.00002 $0.00063
Haiku 4.5 $0.00001 $0.00031

Measured 2d ago against content hash 3615c0b72e9e, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

run-collection scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

commands/run-collection.md · 56 lines

What it actually says

Run Postman collection tests to verify your API endpoints.

Step 1: Find Collections and IDs

List collection folders and look up their cloud IDs:

ls postman/collections/
cat .postman/resources.yaml

The cloudResources.collections section maps local collection paths to cloud IDs.

If no collections found, tell the user and stop. If one collection, use it directly. If multiple, list them and ask which to run.

Step 2: Run the Collection

Run by collection ID (from .postman/resources.yaml):

postman collection run <collection-id>

Common options:

# Stop on first failure
postman collection run <collection-id> --bail

# With request timeout
postman collection run <collection-id> --timeout-request 10000

# With environment
postman collection run <collection-id> -e ./postman/environments/<env-file>.json

# Override environment variable
postman collection run <collection-id> --env-var "base_url=http://localhost:3000"

Step 3: Parse and Report Results

Parse the CLI output for pass/fail counts, failed test names, error messages, and status codes.

Step 4: Handle Failures

If tests fail:

  1. Analyze error messages
  2. Read relevant source code
  3. Suggest fixes
  4. After fixes, re-run to verify
Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 56 lines · 8 tokens per session scan A 3615c0b72e9e

Subscribe to this mod's changes

run-collection is a command published in the GitHub repository Postman-Devrel/postman-claude-code-plugin (38 stars, last pushed 27d ago), licensed Apache-2.0. It adds 8 tokens to every session and 313 once invoked, about $0.0000 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.