Skip to main content
Glama

scan_api_collection_secrets

Read-onlyIdempotent

Audit Postman Collection/Environment JSON, HAR captures, or Bruno files for leaked tokens, API keys, and credentials before git commit, with line numbers and redacted previews.

Instructions

Audit Postman Collection/Environment JSON, HTTP .har captures, or Bruno .bru text for live Bearer tokens, JWTs, Basic auth credentials, session Cookies, AWS/Stripe/OpenAI/GitHub keys, and x-api-key headers before git commit. Returns exact 1-based line numbers, redacted previews, and suggested vars:secret identifiers without exposing raw secrets.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "content": "<content>"
    },
    "name": "scan_api_collection_secrets"
  }
}

Input Schema

NameRequiredDescriptionDefault
contentYesRaw Postman Collection/Environment JSON, HTTP .har JSON, or Bruno .bru text to scan for live credentials.
fileNameNoOptional source filename (e.g. "checkout.postman_collection.json", "traffic.har", or "login.bru") for format detection and line annotations.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.1/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare readOnly, idempotent, non-destructive, closed-world, so the safety profile is covered. The description still adds genuine value the annotations do not: it promises exact 1-based line numbers, redacted previews, suggested vars:secret identifiers, and explicitly that raw secrets are never exposed — a meaningful disclosure for a security tool with no output schema. It omits practical traits like size limits or truncation behavior, keeping it at 4.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two sentences, front-loaded with the verb and the audit intent, with the long credential enumeration doing real work rather than padding. Dense but every clause carries information; only the lengthy key-provider list borders on over-stuffing.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a two-parameter read-only scanner with no output schema, the description covers purpose, input formats, returned fields, and the no-raw-secrets guarantee — enough for an agent to call it correctly. Minor gaps remain around input size limits and how redaction affects the returned previews.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so both `content` and `fileName` are already documented, including that fileName drives format detection and line annotations. The description reinforces the accepted formats but adds no syntax, encoding, or size guidance beyond the schema — the baseline 3 for fully described parameters.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

Opens with a specific verb ("Audit") and names the exact resources it accepts (Postman Collection/Environment JSON, .har captures, Bruno .bru text) plus the credential classes it detects. That is far more specific than the sibling converter/audit tools, so an agent can tell this is the secret-scanning member of the family without opening the schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The phrase "before git commit" supplies a clear triggering context for when to reach for this tool, and the enumerated formats imply what input to feed it. It stops short of stating exclusions or naming an alternative when content is not one of those formats, so it lands just shy of a 5.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.