swag2mcp
swag2mcp is an MCP server that bridges OpenAPI/Swagger/Postman API specifications to LLM agents, enabling discovery, inspection, invocation, and analysis of REST APIs without modifying server code.
API Discovery & Navigation — List and retrieve specs, collections, tags, and endpoints. Use search to find endpoints by natural language or structured queries.
Inspect Endpoints — Retrieve full OpenAPI operation details (parameters, request body, responses) via inspect before invoking.
Invoke APIs — Execute real HTTP calls with invoke, automatic authentication, and handling of large responses (saved to disk).
Large Response Processing — Explore saved responses using response_outline, response_slice, response_filter, and response_compress to navigate, filter, sample, and compress data.
System Info — Check runtime configuration, active specs, rate limits, mock mode via info.
swag2mcp is a local-first bridge between OpenAPI/Swagger/Postman API specifications and LLM agents via the Model Context Protocol (MCP).
Not every API speaks MCP — private endpoints, internal services, legacy systems, and third-party APIs rarely do. swag2mcp wraps any REST API in an MCP interface, giving LLM agents instant access to your entire API surface without modifying a single line of server code. Through live API calls, the LLM gains real-world knowledge to make informed decisions, automate workflows, and act on your data — not just guess.
16 MCP tools for discovering, inspecting, and invoking APIs
Interactive TUI explorer with full-text search
Zero integration code — just point to your specs and go
Installation
Quickstart
Documentation
Quick Start
Install
macOS (Homebrew):
brew install mmadfox/tap/swag2mcpmacOS / Linux (one-liner):
curl -fsSL https://swag2mcp.io/install.sh | bashWindows (Scoop):
scoop bucket add mmadfox https://github.com/mmadfox/scoop-bucket
scoop install mmadfox/swag2mcpAll platforms (go install):
go install github.com/mmadfox/swag2mcp/cmd/swag2mcp@latestAll platforms (Docker):
docker pull ghcr.io/mmadfox/swag2mcp:latest
docker run --rm -i -v ~/.swag2mcp:/home/nonroot/.swag2mcp ghcr.io/mmadfox/swag2mcp:latest mcpFor detailed installation instructions, see Installation.
Available Tools
19 toolscollection_by_idARead-onlyIdempotent
collection_by_id
Retrieves detailed information about a specific collection including its tags, spec metadata, and method statistics.
When to use
Use this tool when:
You have a collection ID and want to see its tags before drilling into endpoints
The user asks for details about a specific collection like "show me what's in the pets collection"
You need to see the spec that owns this collection
To list all collections in a spec first, use collection_by_spec instead.
Parameters
id(required): The 32-character MD5 hash ID of the collection
Returns
The collection's spec (ID, domain), collection details (ID, title, method count), and a list of tags with their IDs, titles, and method counts.
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Unique identifier for the collection,required |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already indicate `readOnlyHint: true` and `idempotentHint: true`, correctly marking it as a safe read. The description adds useful context by detailing the return payload and noting that the ID is a 32-character MD5 hash, which helps set expectations without repeating the annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-organized with clear headers and succinct bullets. Every sentence adds value: it explains the purpose, provides use cases, defines the parameter, and summarizes the return value without fluff.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple single-parameter tool with no output schema, the description fully covers what it does, when to use it, what the parameter means, and what the response contains. No critical information is missing for an agent to correctly invoke it.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Although the schema covers 100% of the parameter with a description, the tool description enriches it further by specifying the exact format ('32-character MD5 hash ID') and reinforcing its purpose. This goes beyond the schema's generic 'Unique identifier' text.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a specific verb ('Retrieves detailed information') and resource ('specific collection'), and lists the exact contents (tags, spec metadata, method statistics). It also distinguishes from the sibling tool `collection_by_spec` by specifying that this tool is for a single collection ID, not listing all collections.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The 'When to use' section provides three concrete scenarios and explicitly points to `collection_by_spec` as the alternative for listing all collections. This gives the agent clear decision guidance and prevents confusion among siblings.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
collection_by_specARead-onlyIdempotent
collection_by_spec
Lists all collections (logical groups of endpoints) within a specific API specification.
When to use
Use this tool when:
You have a
specIdfromspec_listorspec_by_idand want to see how endpoints are organizedThe user says "show me collections in the meteo API" or "what groups exist in spec X?"
You need to navigate from spec → collection → tag → endpoint
After finding a collection of interest, use collection_by_id for its tags or endpoint_by_collection for its endpoints.
Parameters
specId(required): The 32-character MD5 hash ID of the specification
Returns
A list of collections with their IDs, titles, and statistics (tag count, method count).
| Name | Required | Description | Default |
|---|---|---|---|
| specId | Yes | required, |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint and idempotentHint, so the safety profile is covered. The description adds useful behavioral context beyond annotations, such as the scope ('within a specific API specification') and the return shape (list of collections with IDs, titles, and statistics). This is consistent with annotations and enriches the agent's understanding.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-structured with clear sections: a one-sentence purpose, a 'When to use' list, a parameter definition, and a returns summary. Every sentence serves a purpose, and the most important information is front-loaded. No wasted words.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity (one parameter, no output schema), the description covers all necessary aspects: what it does, when to use it, parameter format, and return content. It also fits into the broader navigation flow with sibling tools, making it complete for an agent to select and invoke it correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema only says 'specId' with description 'required,' which is bare. The description compensates by specifying it is a 32-character MD5 hash ID, adding crucial semantic detail. Since there is only one parameter and it is fully explained, the description adds significant meaning beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description states a specific verb ('Lists') and resource ('all collections within a specific API specification'), clearly distinguishing it from siblings like collection_by_id (single collection) and tag_by_collection (tags). It also defines 'collections' as 'logical groups of endpoints.'
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The 'When to use' section explicitly states when to use this tool, including having a `specId` from `spec_list` or `spec_by_id`, user intent examples, and navigation flow. It also names alternatives (`collection_by_id`, `endpoint_by_collection`) for next steps, providing clear context and exclusions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
endpoint_by_collectionARead-onlyIdempotent
endpoint_by_collection
Lists all endpoints within a specific collection, regardless of their tag.
When to use
Use this tool when:
You have a collection ID and want to see every endpoint it contains
The user asks "show me all endpoints in collection X"
You need a complete inventory of a collection's API surface
For a filtered view by tag within a collection, use endpoint_by_tag instead.
Parameters
collectionId(required): The 32-character MD5 hash ID of the collection
Returns
A list of endpoints with their IDs, HTTP methods, paths, summaries, and deprecation status.
| Name | Required | Description | Default |
|---|---|---|---|
| collectionId | Yes | required, |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true and idempotentHint=true. The description adds useful context about the 'regardless of their tag' behavior and details the return fields (IDs, HTTP methods, paths, summaries, deprecation status). It does not contradict annotations and provides additional insight, though it does not cover potential edge cases like pagination or missing IDs.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-structured with clear sections (overview, when to use, parameters, returns). It is concise, wastes no words, and front-loads the primary purpose. Every sentence adds value.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's simplicity (one required parameter, no output schema), the description is complete. It explains what the tool does, when to use it, alternative tools, parameter format, and return contents. No further context seems necessary.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema only describes collectionId as 'required,' while the description specifies it is 'The 32-character MD5 hash ID of the collection,' adding format/type context beyond the schema. This adds meaningful value for correct parameter usage.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description explicitly states 'Lists all endpoints within a specific collection, regardless of their tag.' This is a specific verb+resource pair with a clarifying qualifier, clearly distinguishing it from the sibling tool endpoint_by_tag which filters by tag.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
A dedicated 'When to use' section lists concrete scenarios, and it explicitly directs to the alternative: 'For a filtered view by tag within a collection, use `endpoint_by_tag` instead.' This is explicit when/when-not guidance with a named alternative.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
endpoint_by_idARead-onlyIdempotent
endpoint_by_id
Returns a quick summary of a single endpoint: method, path, summary, and deprecation status.
Use inspect instead when you need the full OpenAPI operation object with parameters, request body, and response schemas.
When to use
Use this tool when:
You already have an endpoint ID and want a quick overview
The user asks "what is this endpoint?" at a high level
You need the method, path, or summary to present to the user
Do NOT use this tool when you need technical details (schemas, parameters, request body) — use inspect instead.
Parameters
id(required): The 32-character MD5 hash ID of the endpoint
Returns
The endpoint's method (GET/POST/etc.), path, summary, and whether it's deprecated.
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | required,Unique identifier for the endpoint |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnly and idempotent hints. The description adds that it returns a summary and lists the exact fields, clarifying the limited scope. No contradictions with annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-organized with headings and bullet points, making it easy to scan. While somewhat long, each section adds practical value and there is no redundant fluff.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a single-parameter tool with no output schema, the description fully covers the return value, usage context, and parameter format. It is complete for an agent to decide when to invoke and what to expect.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema covers the parameter but only with 'Unique identifier'. The description adds a valuable detail: the ID is a 32-character MD5 hash, which helps the agent understand what value to provide. This goes beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states it returns a quick summary of a single endpoint with specific fields (method, path, summary, deprecation status). It distinguishes itself from the `inspect` sibling tool by contrasting the summary level vs. full OpenAPI operation object.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicit 'When to use' and 'Do NOT use' sections provide clear guidance, including using `inspect` for technical details. This gives the agent concrete criteria for selection versus alternatives.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
endpoint_by_specARead-onlyIdempotent
endpoint_by_spec
Lists all endpoints across an entire API specification, spanning all collections and tags.
When to use
Use this tool when:
You want a comprehensive view of every endpoint in a spec
The user asks "show me all endpoints in API X" or "what does spec Y expose?"
You need to search across all collections within a single spec
For a narrower scope, use endpoint_by_collection (single collection) or endpoint_by_tag (single tag).
Parameters
specId(required): The 32-character MD5 hash ID of the specification
Returns
A list of endpoints with their IDs, HTTP methods, paths, summaries, and deprecation status.
| Name | Required | Description | Default |
|---|---|---|---|
| specId | Yes | required, |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint and idempotentHint, so safety is covered. The description adds value by detailing the return payload (IDs, methods, paths, summaries, deprecation status) and the comprehensive nature of the result. It doesn't mention potential pagination or error cases, but for a list-all tool this is reasonably transparent.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-structured with clear sections (Purpose, When to use, Parameters, Returns). Every sentence adds useful information, and it is front-loaded with a concise summary. No filler content.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given that this is a simple one-parameter tool with annotations and no output schema, the description covers all necessary context: purpose, usage criteria, parameter format, and return value. It is fully complete for an agent to select and invoke it correctly.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, but the schema's description is terse ('required,'). The tool description adds important semantic detail by specifying that specId is a 32-character MD5 hash ID, which helps the agent understand the expected format. This goes beyond the schema baseline.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb ('Lists') with a clear resource ('all endpoints across an entire API specification') and explicitly distinguishes itself from sibling tools by noting its comprehensive scope. The phrase 'spanning all collections and tags' plus the contrast with `endpoint_by_collection` and `endpoint_by_tag` makes the purpose unmistakable.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description has a dedicated 'When to use' section that lists concrete scenarios (e.g., 'show me all endpoints in API X') and explicitly names alternative tools for narrower scopes. This provides clear guidance on when to choose this tool over siblings.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
endpoint_by_tagARead-onlyIdempotent
endpoint_by_tag
Lists all endpoints grouped under a specific tag within a collection.
When to use
Use this tool when:
You have a tag ID and want to see all endpoints in that category
The user asks "show me all pets endpoints" or "what's in the orders tag?"
You've identified a tag via
tag_by_idortag_by_collectionand want its endpoints
To see the tag's metadata (title, method count) without listing endpoints, use tag_by_id instead.
Parameters
tagId(required): The 32-character MD5 hash ID of the tag
Returns
A list of endpoints with their IDs, HTTP methods, paths, summaries, and deprecation status.
| Name | Required | Description | Default |
|---|---|---|---|
| tagId | Yes | required, |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint and idempotentHint, and the description complements this by specifying the return payload: 'A list of endpoints with their IDs, HTTP methods, paths, summaries, and deprecation status.' No side effects are claimed. It doesn't discuss error cases, but that's not expected for a read-only lookup.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Structured with headings, no filler. Every section adds practical information—summary, use cases, parameter format, and return values.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a single-parameter read-only tool, the description covers purpose, usage timing, alternatives, parameter format, and return shape. No output schema exists, but the return list description compensates.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema only states tagId is required, but the description enriches it: 'The 32-character MD5 hash ID of the tag.' This gives the agent the exact format needed, exceeding schema baseline.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with a precise statement: 'Lists all endpoints grouped under a specific tag within a collection.' It also contrasts with tag_by_id, clarifying the tool's unique role among siblings.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The 'When to use' section explicitly lists scenarios (having a tag ID, user queries) and gives an alternative: 'To see the tag's metadata (title, method count) without listing endpoints, use tag_by_id instead.' This is model behavior.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
infoARead-onlyIdempotent
info
Returns a comprehensive summary of the swag2mcp runtime: version, configuration, active specs, HTTP client settings, MCP transport, auth methods, and mock mode status.
When to use
Use this tool when:
The user asks "what's the current configuration?" or "show me the system status"
You need to understand how the HTTP client is configured (timeout, proxy, headers, cookies, rate_limiting)
You need to know which specs are active, disabled, and their endpoint counts
You want to check the MCP transport type and whether auth is enabled
You need to see which auth methods are configured across all specs
You want to check if mock mode is enabled
Before calling
invokein a loop — checkrate_limiting.per_endpoint_intervalandrate_limiting.global_limitto avoid throttling
This tool takes no arguments — it returns the full runtime summary.
Parameters
This tool has no parameters.
Returns
A JSON object with version, latest_version (from GitHub), workspace path, uptime, specs summary, HTTP client configuration (including rate_limiting with per_endpoint_interval and global_limit), MCP configuration, auth methods, and mock mode status.
Presentation
When presenting results to the user, format numeric values in human-readable form:
max_response_size: convert bytes to a human-friendly string (e.g.,"1 KB"instead of1048)uptimeis already human-readableCounts (total, active, endpoints, etc.) are small numbers — show as-is
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnly and idempotent hints. The description adds valuable context beyond those: it notes the tool fetches 'latest_version (from GitHub)', exposes rate_limiting fields, and details the exact categories of returned data. It also gives presentation guidance for humans, showing the agent understands the output format. No contradictions with annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-structured with clear headers (# info, When to use, Parameters, Returns, Presentation). It front-loads the core purpose and uses bullet points for readability. Every section earns its place; the presentation guidance is practical and not redundant.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given that there is no output schema, the description compensates by listing all returned categories and providing formatting advice for human-readable output. It also covers the critical note about rate limiting for agents running loops. This makes the tool fully self-contained for an agent to understand and use effectively.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema has no parameters (0 params), so baseline is 4 as per rubric. The description explicitly states 'This tool has no parameters' and 'takes no arguments', reinforcing the schema. There is no extra parameter semantics to add since there are none.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The first line clearly states the tool returns 'a comprehensive summary of the swag2mcp runtime' and enumerates specific content (version, configuration, active specs, HTTP client settings, MCP transport, auth methods, mock mode). This is a specific, resource-defined purpose that distinguishes it from sibling tools focused on specs or endpoints.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
A dedicated 'When to use' section provides explicit triggers ('user asks what's the current configuration?', 'before calling invoke in a loop', etc.). It gives clear context but does not mention exclusions or alternatives to this tool, which would warrant a 5.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
inspectARead-onlyIdempotent
inspect
Retrieves the full OpenAPI operation object for an endpoint — parameters, request body, response schemas, and all definitions.
Use this when you need complete technical details before invoking an endpoint or explaining its contract to the user.
For a quick summary (method, path, summary only), use endpoint_by_id instead.
When to use
Use this tool when:
The user asks "show me the full spec for this endpoint"
You need to understand the exact schema for request/response bodies
You need to know which parameters (path, query, header) an endpoint accepts
You are preparing to call an endpoint via
invokeand need to build the correct requestThe user asks for examples, response codes, or technical contract details
Parameters
endpointId(required): The 32-character MD5 hash ID of the endpoint to inspect
Returns
The full OpenAPI operation object including parameters (with schemas), request body, responses, and all referenced schema definitions.
Note on auth-injected parameters
Some required parameters shown by inspect may be auth credentials (e.g. api_key, timestamp, signature, recvWindow). These are injected automatically by swag2mcp during invoke — do NOT pass them in parameters. Only pass genuine business parameters.
| Name | Required | Description | Default |
|---|---|---|---|
| endpointId | Yes | required,The 32-character MD5 hash ID of the endpoint to inspect |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already mark this as read-only and idempotent, and the description adds valuable context: the note about auth-injected parameters being automatically handled and not to be passed. This explains critical behavior beyond the annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Well-structured with clear headings, bullet lists, and a concise note. Each section adds essential information without redundancy or unnecessary filler.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Despite lacking an output schema, the description fully explains the return value (full OpenAPI operation object) and includes the critical auth-injection warning. For a simple single-parameter tool with good annotations, this is complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema already covers the single parameter with 100% coverage, but the description reinforces that `endpointId` is a 32-character MD5 hash and adds usage nuance about auth parameters. The baseline is 3; the extra clarification warrants a 4.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's purpose: 'Retrieves the full OpenAPI operation object for an endpoint' — a specific verb and resource. It distinguishes from sibling tool `endpoint_by_id` by noting the difference between full spec and quick summary.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Explicit 'When to use' section lists concrete scenarios, and directly names the alternative `endpoint_by_id` for quick summaries. This gives clear guidance on choosing this tool over others.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
invokeA
invoke
Executes a real API call to an endpoint using the provided parameters and returns the response data, status code, and headers.
When to use
Use this tool only when the user explicitly asks to perform an action, such as:
"Get all pets" or "Create a user"
"Call the API" or "Make a request"
"Test the endpoint" or "Try it out"
Always use inspect first to understand the required parameters, headers, and request body before invoking.
Never invoke a destructive operation (POST/PUT/PATCH/DELETE) without explicit user confirmation.
Parameters
endpointId(required): The 32-character MD5 hash ID of the endpoint to invokeparameters(optional): Object containing path, query, and header parameters as key-value pairsrequestBody(optional): The request body for POST/PUT/PATCH requests. Provide as a JSON object matching the schema frominspect
Returns
The API response data, HTTP status code, and response headers.
Large responses (over ~50 KB) are automatically saved to disk. You will receive a file path — use it to reference the result rather than displaying the full content inline.
Important
Auth is automatic:
invokehandles authentication automatically. Do NOT passheadersorcookies— swag2mcp applies auth under the hood.Auth-injected parameters are automatic: If
inspectshows a required parameter that is an auth credential (e.g.api_key,timestamp,signature,recvWindow), do NOT pass it inparameters— swag2mcp injects it automatically. Only pass genuine business parameters.One at a time, bounded retries: Make at most one outstanding invoke at a time — never launch a batch. If a call is
rate_limit-ed, do not retry immediately or in a batch; back off (~15s, then ~30s) and retry that endpoint at most twice more, then mark it as "rate limited" and move on. Non-rate-limit errors are final — do not retry.Rate limits: Before calling
invokein a loop, callinfoto checkrate_limiting(per_endpoint_interval, global_limit). Respect these limits to avoid throttling.
| Name | Required | Description | Default |
|---|---|---|---|
| endpointId | Yes | required,The 32-character MD5 hash ID of the endpoint to invoke | |
| parameters | No | optional,Path, query, and header parameters as key-value pairs | |
| requestBody | No | optional,Request body for POST/PUT/PATCH requests |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description fully discloses behavioral traits: automatic auth, auth-injected parameters, large-response disk saving, one-at-a-time invocation, bounded retries, and rate-limit handling. This is extensive and far exceeds the minimum burden.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-structured with clear headers, bullets, and front-loaded purpose. Every sentence serves a concrete purpose, with no redundancy or repetition of schema definitions.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool's complexity (dynamic endpoint invocation, auth, rate limits, large responses), the description covers all necessary aspects: when to use, prerequisites, parameter roles, auth, error handling, and rate limits. Without an output schema, it still explains return values and disk-saved responses adequately.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, but the description adds critical semantics: clarifies `parameters` includes path/query/header only, `requestBody` for POST/PUT/PATCH, and explicitly warns against passing auth-related params. This prevents common misuse and goes well beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The first sentence clearly states the tool executes a real API call and returns response data, status code, and headers. This distinguishes it from sibling tools like `inspect` and `info`, which are read/analysis tools, while `invoke` performs the actual action.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The 'When to use' section explicitly limits usage to explicit user action requests, provides example phrases, and mandates `inspect` first. It also excludes destructive operations without confirmation and points to `info` for rate-limit checks, offering clear alternatives.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
response_compressARead-onlyIdempotent
response_compress
Reduces a JSON value inside a saved response file so it fits within the response size limit and can be returned to the LLM inline.
When to use
Use this tool after response_outline when you want to see a representative sample of a large array or reduce verbose string/object content before reading specific items.
When NOT to use
Do NOT use
bash,cat,head,tail,file,open,less,more, or any external command to readfileRef.path.Do NOT read the file manually. Always use
response_compressorresponse_sliceto access data inside saved response files.
Parameters
path(required): The absolute file path fromfileRef.pathreturned byinvoke.jsonPath(optional): Path to the value to compress. Default is the root of the file.mode(required): Compression strategy.first_of_array: keep only the first element of an array.sample_array: keep a head and tail sample of an array.truncate_strings: shorten every string tostringLencharacters.keys_only: replace object values with type names.select_keys: keep only the keys listed inselectKeysfor every object in an array.
arrayHead(optional): Number of leading array items forsample_array. Default is 3.arrayTail(optional): Number of trailing array items forsample_array. Default is 2.stringLen(optional): Maximum string length fortruncate_strings. Default is 80.selectKeys(optional): Keys to keep forselect_keysmode.
Returns
Either:
body: the compressed JSON value inline, orfileRef: if the compressed result is still too large, a new saved file path and metadata.hint: a short explanation of what was compressed and how to continue exploring.
Recommended workflow
After response_outline shows a large array such as pets with 5000 items:
response_compress({
"path": "/.../responses/...json",
"jsonPath": "pets",
"mode": "first_of_array"
})Then use response_slice with jsonPath like pets.0, pets.1, etc.
| Name | Required | Description | Default |
|---|---|---|---|
| mode | Yes | required,Compression mode: first_of_array, sample_array, truncate_strings, keys_only, select_keys | |
| path | Yes | required,Absolute path returned in fileRef.path | |
| jsonPath | No | optional,Path to the value to compress (e.g. data or data.0) | |
| arrayHead | No | optional,Number of leading array items for sample_array mode | |
| arrayTail | No | optional,Number of trailing array items for sample_array mode | |
| stringLen | No | optional,Maximum string length for truncate_strings mode | |
| selectKeys | No | optional,Keys to keep for select_keys mode |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond the annotations (readOnlyHint, idempotentHint), the description discloses that the tool may return either an inline body or a new fileRef if the result is still too large, and provides a hint. It also explains compression modes and default behavior, adding significant context.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-structured with headers, bullet points, and a workflow example. It is slightly verbose with duplicate parameter details, but every section serves a purpose and the front-loaded summary is clear.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Without an output schema, the description fully explains return values (body, fileRef, hint) and provides a concrete workflow example. It covers all parameter semantics and mode nuances, making it self-contained for effective use.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The parameter section goes far beyond the schema by explaining each mode's effect, providing defaults for arrayHead (3), arrayTail (2), stringLen (80), and jsonPath (root), and detailing how selectKeys works. This is critical meaning not present in the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with a clear verb and resource: 'Reduces a JSON value inside a saved response file so it fits within the response size limit and can be returned to the LLM inline.' This distinguishes it from sibling tools like response_slice and response_filter by focusing on size reduction and inline return.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Contains explicit 'When to use' and 'When NOT to use' sections. It names the predecessor (response_outline) and successor (response_slice), and explicitly forbids manual file reading with external commands, directing users to this tool or response_slice instead.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
response_filterARead-onlyIdempotent
response_filter
Filters, searches, and paginates through arrays in saved JSON response files.
When to use
Use this tool when:
You need to find specific items in a large array (e.g. "find bitcoin in 18090 items")
You want to filter an array by a condition (e.g. "status = active", "price > 100")
You need to paginate through a large array page by page
The response is too large to inspect manually with
response_slice
When NOT to use
Do NOT use
bash,cat,head,tail,file,open,less,more, or any external command to readfileRef.path.Do NOT read the file manually. This tool is the only allowed way to filter and paginate saved response files.
Parameters
path(required): The absolute file path fromfileRef.pathreturned byinvoke.jsonPath(required): Path to the array to filter (e.g.pets,data.items,results). Leave empty for root-level arrays. Uses gjson syntax — recursive descent (..) is not supported; use exact paths likesymbols.0.symbolor usesearch/filterinstead.search(optional): Full-text search across all fields of each item. Case-insensitive substring match (e.g."bitcoin").filter(optional): Structured filter condition. Format:field operator value. Supported operators:=,!=,contains,>,<,>=,<=. Examples:status = active,price > 100,name contains bitcoin.page(optional): Page number starting from 1. Default is 1.pageSize(optional): Items per page (max 50). Default is 10.
Returns
page: Current page number.pageSize: Items per page.total: Total number of matching items.totalPages: Total number of pages.items: Array of matching items for the current page.strategy: Whether the file was processed in memory (memory) or streamed (streaming).
Examples
response_filter({
"path": "/.../responses/...json",
"jsonPath": "pets",
"search": "fluffy",
"page": 1,
"pageSize": 5
})response_filter({
"path": "/.../responses/...json",
"jsonPath": "data.items",
"filter": "price > 50",
"page": 2,
"pageSize": 20
})| Name | Required | Description | Default |
|---|---|---|---|
| page | No | optional,Page number starting from 1 (default 1) | |
| path | Yes | required,Absolute path returned in fileRef.path | |
| filter | No | optional,Structured filter condition (e.g. status = active, price > 100) | |
| search | No | optional,Full-text search across all fields of each item | |
| jsonPath | No | optional,Path to the array to filter (e.g. pets, data.items). Leave empty for root arrays. | |
| pageSize | No | optional,Items per page (max 50, default 10) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already mark readOnlyHint and idempotentHint, and the description adds substantial behavioral context: processing strategy (memory vs streaming), return fields, filter operator syntax, gjson path limitations (recursive descent not supported), and case-insensitive substring search. No contradictions with annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-structured with clear headers (When to use, When NOT to use, Parameters, Returns, Examples) and a front-loaded one-sentence summary. The length is justified by the tool's complexity, and every sentence adds value—no fluff or redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Despite no output schema, the description includes a full 'Returns' section explaining each field (page, pageSize, total, totalPages, items, strategy). It also covers gjson syntax caveats, filter operators, and warnings about not reading files manually, making the description complete for a tool of this complexity.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Although schema coverage is 100%, the description enriches every parameter: it documents defaults (page=1, pageSize=10), max pageSize (50), gjson syntax examples, supported filter operators, and clarifies that jsonPath can be empty for root arrays. This goes well beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with a specific verb+resource: 'Filters, searches, and paginates through arrays in saved JSON response files.' This clearly distinguishes it from siblings like response_slice, response_outline, and response_compress by covering three distinct operations on saved response arrays.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Provides an explicit 'When to use' list (find specific items, filter by condition, paginate, response too large for response_slice) and a 'When NOT to use' section that forbids alternative tools like bash/cat/head. It even names response_slice as the alternative for manual inspection, giving clear usage context.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
response_outlineARead-onlyIdempotent
response_outline
Returns a high-level structural summary of a large JSON response file that was saved to disk by invoke. It does not return the actual data — only the shape, keys, array lengths, and hints that help decide how to explore the file next.
When to use
Use this tool immediately after invoke returns a fileRef because the response body was too large. It is the first and mandatory step in exploring a saved response file.
When NOT to use
Do NOT use
bash,cat,head,tail,file,open,less,more, or any external command to readfileRef.path.Do NOT ask the user to open the file manually.
Do NOT try to guess the file contents. Only the
response_*tools may read saved response files.
Parameters
path(required): The absolute file path fromfileRef.pathreturned byinvoke.maxDepth(optional): Maximum recursion depth when inspecting nested objects and arrays. Default is 3.maxArrayItems(optional): How many array items to inspect for detailed key/type information. Default is 5.
Returns
A structural outline containing:
type: root JSON type (object,array, etc.).size: file size in bytes.lineCount: number of lines in the file.depth: maximum nesting depth inspected.structure: recursive map of keys, types, array lengths, and sample items.schemaHint: one-line summary of the top-level shape.compressionHints: suggestedresponse_compresscalls to shrink the file.navigationHints: top-level paths and arrays with lengths, useful forresponse_slice.
Example workflow
invoke returns fileRef.path = /.../responses/example-get-pets-abc123.json
↓
response_outline({"path": "/.../responses/example-get-pets-abc123.json"})
↓
response_compress({"path": "...", "jsonPath": "pets", "mode": "first_of_array"})
↓
response_slice({"path": "...", "jsonPath": "pets.0"})| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | required,Absolute path returned in fileRef.path | |
| maxDepth | No | optional,Max recursion depth (default 3) | |
| maxArrayItems | No | optional,How many array items to inspect (default 5) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond the readOnlyHint and idempotentHint annotations, the description reveals key behavioral traits: it does not return the actual data, it serves as a gatekeeper for subsequent exploration, and it enforces a policy that only response_* tools may read saved files. These insights are not present in the annotations and add significant context for the agent.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is longer than minimal, but it is well-structured with clear headers (When to use, When NOT to use, Parameters, Returns, Example workflow). Each section serves a distinct purpose, especially the explicit forbidden commands list. While verbose, it front-loads the core purpose and remains organized, earning a 4 rather than a 5.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
With no output schema, the description compensates by providing a detailed 'Returns' section listing the outline fields (type, size, lineCount, depth, structure, schemaHint, compressionHints, navigationHints). It also includes an example workflow showing how it chains with response_compress and response_slice, making the tool's role fully understandable.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100% with each parameter described inline. The description's Parameters section restates the same information (path from fileRef.path, maxDepth default 3, maxArrayItems default 5) without adding new semantics. Since the schema already carries the meaning, the baseline of 3 is appropriate; the description adds no extra clarity beyond the structured data.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with a clear, specific statement: 'Returns a high-level structural summary of a large JSON response file... It does not return the actual data — only the shape, keys, array lengths, and hints...' This identifies the exact verb ('Returns'), resource ('JSON response file'), and distinguishes the tool from siblings like response_compress and response_slice, which manipulate data.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The 'When to use' section explicitly instructs to use this tool 'immediately after invoke returns a fileRef' and labels it the 'first and mandatory step.' The 'When NOT to use' section names specific forbidden alternatives (bash, cat, head, tail, etc.) and states that only response_* tools may read saved files. This provides clear direction on when to use versus alternatives.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
response_sliceARead-onlyIdempotent
response_slice
Extracts a specific fragment of a saved JSON response file by logical jsonPath or by line range.
When to use
Use this tool when you know which object, array, or field you want to inspect inside a large response. Prefer jsonPath over line numbers because it is stable and descriptive.
When NOT to use
Do NOT use
bash,cat,head,tail,file,open,less,more, or any external command to readfileRef.path.Do NOT read the file manually. This tool is the only allowed way to extract fragments from saved response files.
Parameters
path(required): The absolute file path fromfileRef.pathreturned byinvoke.jsonPath(optional): Logical path such asdata.0,users.3.name, orcompany.departments.engineering.employees.0. Use gjson dotted syntax. Leave empty (or use@this) to target the root value — for a root array this returns its first element.line(optional): 1-based line number to center the fragment on. The tool returnsaroundlines above and below.range(optional): Exact line range asstart-end(for example120-240).around(optional): Number of lines to include aroundline. Default is 20.
Returns
slice.lines: 1-based line range of the returned fragment.slice.value: the extracted JSON value parsed into a structured object.slice.fragment: raw JSON text when the fragment is small enough to include.slice.context:object,array, orvaluedescribing what was extracted.slice.isComplete: true whenvalueis a valid JSON fragment.slice.nextPath/slice.prevPath: suggested adjacent paths for array navigation.slice.nextLine/slice.prevLine: suggested line numbers for line-based navigation.fileRef: only present when the extracted fragment exceeded the size limit and was saved to disk.
Example
response_slice({
"path": "/.../responses/...json",
"jsonPath": "pets.0"
})Then continue with pets.1, pets.2, etc. using slice.nextPath.
| Name | Required | Description | Default |
|---|---|---|---|
| line | No | optional,1-based line number to center the fragment on | |
| path | Yes | required,Absolute path returned in fileRef.path | |
| range | No | optional,Line range as start-end (e.g. 120-240) | |
| around | No | optional,Lines to include around line (default 20) | |
| jsonPath | No | optional,Logical path to the value (e.g. data.3.name) |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Beyond the readOnly/idempotent annotations, it documents return fields (slice.lines, slice.value, slice.fragment, slice.context, slice.isComplete, slice.nextPath/prevPath) and edge behaviors such as root array returning first element, default around=20, and fileRef only when size limit is exceeded.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-structured with a clear purpose, usage criteria, parameter explanations, return values, and a concrete example. It front-loads the main purpose and keeps every section purposeful.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with no output schema, the description fully explains inputs, defaults, return fields, and navigation. It also covers when not to use the tool and provides a working example, making it complete for an agent.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, yet the description adds gjson dotted syntax, @this sentinel, root-array behavior, line/range/around defaults, and example path expressions. This significantly exceeds the schema's brief property descriptions.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with 'Extracts a specific fragment of a saved JSON response file by logical jsonPath or by line range,' providing a specific verb, resource, and method. It clearly distinguishes itself from response_outline/response_filter by focusing on direct extraction of a known fragment.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
Contains explicit 'When to use' and 'When NOT to use' sections. It instructs agents to use it when a specific object/array/field is already identified, prefer jsonPath over line numbers, and prohibits using shell commands to read the file.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
searchARead-onlyIdempotent
search
The ONLY tool for finding endpoints when you don't have the endpoint ID.
Searches endpoints across all specifications using full-text and structured queries.
When to use
Use this tool when:
The user asks to find a method/endpoint by description, name, path, tag, or functionality
The user describes functionality without knowing specific paths or tags
You need to find relevant endpoints based on natural language descriptions
You want to filter by HTTP method (
method:GET), tag (tag:auth), or path (path:user)
DO NOT
❌ Do NOT manually traverse spec → collection → tag → endpoint to find something. Use
search.❌ Do NOT guess endpoint IDs. Use
search.❌ Do NOT use
endpoint_by_tag/endpoint_by_collection/endpoint_by_specfor discovery — those are for navigation after you already know what you're looking for.❌ Do NOT skip
searchand try to brute-force your way through collections. Onesearchcall replaces dozens of manual navigation steps.
User Intent → Search Query Examples
User says | What to search |
"Find the create user endpoint" |
|
"Show all GET endpoints" |
|
"What relates to orders?" |
|
"Find endpoint by path /api/v1/users" |
|
"How do I delete a pet?" |
|
"Show all auth endpoints" |
|
"Find something about inventory" |
|
"Give me all POST requests in the store section" |
|
Parameters
query(required): Natural language or structured search query. Supports field filters (method:POST,tag:pet,path:/api/v1/*), boolean operators (+must,-exclude), fuzzy (term~), wildcards (*,?), and phrases ("exact phrase").path:filters match the full path prefix — e.g.path:/api/v3/*returns only endpoints whose path starts with/api/v3/;path:/api/v3/usersmatches that exact path. Queries containing/use AND between tokens — e.g./v1/seasonalmatches only endpoints with bothv1ANDseasonal, not all/v1/*endpoints.limit(required): Maximum number of results to return (min: 1, max: 50)
Returns
A list of endpoints matching the query with their IDs, methods, paths, and summaries.
| Name | Required | Description | Default |
|---|---|---|---|
| limit | Yes | required,Maximum number of results to return | |
| query | Yes | required,Search query. Supports field filters (method:GET tag:pets path:/v1/...). Queries containing '/' use AND between tokens for precise path matching. |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Even with readOnlyHint and idempotentHint annotations, the description adds rich behavioral context: query syntax (field filters, boolean operators, fuzzy, wildcards, phrases), path prefix matching nuance (e.g., 'path:/api/v3/*' matches only prefixes), the AND behavior for queries with '/', and the return format (list with IDs, methods, paths, summaries).
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is long but impeccably structured with headers, bullet lists, a table of examples, and clear sections. Every sentence contributes to understanding the tool, and the formatting makes it scannable without redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple 2-parameter tool with no output schema, the description fully covers what the tool does, how to use it, what parameters mean, and what it returns (list of endpoints with IDs, methods, paths, summaries). No critical information is missing.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Although schema coverage is 100%, the description vastly expands parameter semantics. It details query syntax (method:, tag:, path:, boolean +/-, fuzzy ~, wildcards *, phrases), provides explicit examples for each filter, and adds min/max constraints for the limit parameter not present in the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with a definitive statement: 'The ONLY tool for finding endpoints when you don't have the endpoint ID.' It clearly specifies the action (searches endpoints) and resource (across all specifications), and distinguishes itself from sibling tools like endpoint_by_tag and endpoint_by_collection by stating those are for navigation after you already know what you're looking for.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The 'When to use' section provides explicit triggers, and the 'DO NOT' section lists alternatives and warns against manual traversal. The user intent-to-search-query examples further clarify when and how to apply the tool in practical scenarios.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
spec_by_idARead-onlyIdempotent
spec_by_id
Retrieves detailed information about a specific API specification by its ID, including its domain and all associated collections.
When to use
Use this tool when:
You need to explore a specific API's structure after discovering it via
spec_listThe user asks "show me details about API X" or "what collections are in spec Y?"
You have a
specIdand need to get its collections before drilling into tags
Parameters
id(required): The 32-character MD5 hash ID of the specification
Returns
The specification's ID and domain, plus a list of collections with their IDs, titles, tag counts, and method counts.
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | required,A unique 32-character MD5 hash identifier for the spec,pattern=^[0-9a-f]{32}$ |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true and idempotentHint=true, covering safety. The description adds value by specifying exactly what is returned (domain, collections with IDs, titles, tag counts, method counts) and clarifying scope ('all associated collections'). It also implicitly states it does not drill into tags. This goes beyond the annotated safety profile.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-structured with clear sections (overview, when to use, parameters, returns). Every sentence serves a purpose, and the use of bullets and headers enhances readability. It is appropriately sized for the tool's simplicity.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
There is no output schema, so the description carries the full responsibility for explaining return values, and it does so thoroughly (domain and collections with specific fields). It also covers parameters and usage context. For a tool with one parameter and clear annotations, this is complete.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The input schema already provides full coverage (100%) for the sole parameter 'id', including its MD5 format and pattern. The description's parameter section restates this information without adding new semantic meaning. Since schema coverage is high, baseline 3 is appropriate.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with a specific verb and resource: 'Retrieves detailed information about a specific API specification by its ID, including its domain and all associated collections.' This distinguishes it from siblings like spec_list (which lists specs) and collection_by_spec (which likely focuses on collections only). The mention of 'after discovering it via spec_list' further clarifies its role.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
A dedicated 'When to use' section provides explicit scenarios and contrasts with spec_list and drilling into tags. It clearly states when this tool is appropriate and implies alternatives by pointing to spec_list and tag-related tools. This is model-tier usage guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
spec_listARead-onlyIdempotent
spec_list
Lists all available API specifications (OpenAPI/Swagger) in the workspace.
Always start here to discover which APIs are registered.
When to use
Use this tool when:
You need to discover what APIs are available
The user asks "What APIs do you support?" or "Show me all APIs"
You need to see the scope of available APIs before exploring further
This tool takes no arguments — it simply returns all registered specifications.
Parameters
This tool has no parameters.
Returns
A list of specifications with their IDs and domains.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint=true and idempotentHint=true, so safety is covered. The description adds that the tool takes no arguments and returns 'a list of specifications with their IDs and domains,' providing return-format context beyond the annotations. It doesn't contradict annotations.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-structured with sections (When to use, Parameters, Returns) and front-loaded purpose. It is slightly repetitive (no arguments stated twice) but every sentence contributes to understanding, so minor redundancy prevents a 5.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple 0-parameter list tool with annotations present, the description is complete: it explains what the tool does, when to use it, and what it returns. No output schema exists, but the Returns section provides sufficient information about the response contents.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
With zero parameters, the baseline is 4. The description explicitly reinforces 'This tool takes no arguments' and 'This tool has no parameters,' making the parameter semantics clear even though the schema already shows an empty object.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states 'Lists all available API specifications (OpenAPI/Swagger) in the workspace' with a specific verb and resource. It distinguishes itself from siblings like spec_by_id by positioning itself as the starting point for discovery, making its purpose unambiguous.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The 'When to use' section explicitly lists scenarios (e.g., discovering APIs, answering 'What APIs do you support?', seeing scope before exploring). It doesn't name alternatives but implies them with 'before exploring further,' providing clear context without explicit exclusions.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
tag_by_collectionARead-onlyIdempotent
tag_by_collection
Lists all tags within a specific collection.
When to use
Use this tool when:
You have a collection ID and want to see how its endpoints are categorized
The user asks "what tags are in collection X?" or "show me the categories"
You are navigating hierarchically: spec → collection → tag → endpoint
Use tag_by_spec instead if you want all tags across an entire specification (not just one collection).
Parameters
collectionId(required): The 32-character MD5 hash ID of the collection
Returns
A list of tags with their IDs, titles, and method counts.
| Name | Required | Description | Default |
|---|---|---|---|
| collectionId | Yes | required, |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already declare readOnlyHint and idempotentHint, covering safety. The description adds context about the hierarchical navigation pattern and discloses the return format (list of tags with IDs, titles, method counts), providing value beyond structured data.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-organized with clear headings (overview, when to use, parameters, returns), is appropriately sized for a simple tool, and contains no redundant or filler language.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with one parameter and no output schema, this description fully covers purpose, usage, parameter semantics, and return shape. The sibling-tool context and annotations further round out the operational picture, leaving no critical gaps.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
While schema coverage is 100%, the schema's description is merely 'required,' which provides no real meaning. The tool description compensates by explaining that collectionId is a '32-character MD5 hash ID of the collection,' offering actionable semantic detail beyond the schema.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description opens with 'Lists all tags within a specific collection,' which is a specific verb+resource+scope statement. It explicitly distinguishes from the sibling tool tag_by_spec by noting the collection-level scope versus spec-wide scope.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description includes a dedicated 'When to use' section with concrete scenarios (having a collection ID, hierarchical navigation, user queries) and explicitly directs users to tag_by_spec for the alternative case, satisfying both when and when-not guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
tag_by_idARead-onlyIdempotent
tag_by_id
Returns information about a single tag: its ID, title, and how many methods it contains.
This tool tells you about the tag itself. To get the actual list of endpoints inside a tag, use endpoint_by_tag instead.
When to use
Use this tool when:
You have a tag ID and want to verify it exists or see its metadata
The user asks "what is this tag?" — title and method count
You need tag statistics before deciding to explore its endpoints
Do NOT use this tool to get the list of endpoints — use endpoint_by_tag for that.
Parameters
id(required): The 32-character MD5 hash ID of the tag
Returns
The tag's ID, human-readable title, and the number of API methods grouped under it.
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | required,Unique identifier for the tag |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
Annotations already mark this as readOnly and idempotent. The description adds useful behavioral context by specifying exactly what is returned (ID, title, method count) and clarifying that it does not return the list of endpoints, which exceeds the annotation-only information.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is well-structured with headings, a summary up front, and bullet points for usage guidance. It is slightly longer than necessary, but each section adds value and it remains highly scannable.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Since there is no output schema, the description compensates by explaining the return fields (ID, title, method count). It also provides clear usage context and sibling differentiation, making it complete for a simple read-only lookup tool.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 100%, so the baseline is 3. The description adds valuable detail by specifying the id format as a '32-character MD5 hash ID', which is not present in the schema description, and reinforces that it is required.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool 'returns information about a single tag: its ID, title, and how many methods it contains.' It explicitly distinguishes itself from the sibling tool endpoint_by_tag, which lists endpoints within a tag.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description includes a dedicated 'When to use' section with specific scenarios and a 'Do NOT use' instruction that names the alternative (endpoint_by_tag). This directly guides the agent on tool selection.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
tag_by_specARead-onlyIdempotent
tag_by_spec
Lists all tags across an entire API specification, spanning all collections.
When to use
Use this tool when:
You want to see every tag available in an API spec
The user asks "what categories exist in spec Y?"
You need a global view of all endpoint categories without drilling into each collection
Use tag_by_collection instead if you only need tags within a single, specific collection.
Parameters
specId(required): The 32-character MD5 hash ID of the specification
Returns
A list of tags with their IDs, titles, and method counts.
| Name | Required | Description | Default |
|---|---|---|---|
| specId | Yes | required, |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
The annotations already declare readOnlyHint=true and idempotentHint=true, so the description only needs to add context beyond that. It adds a clear 'Returns' section describing the output structure (tags with IDs, titles, and method counts), which goes beyond what annotations provide. It doesn't cover pagination or errors, but for a simple read-only listing tool this is sufficient.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description uses a clean structure with a short summary, 'When to use' bullets, a parameter list, and a returns section. Every section earns its place, with no fluff or repetition. It is concise yet complete, using clear headings and bullets for scannability.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a tool with a single parameter, no output schema, and read-only/idempotent annotations, the description provides everything an agent needs: what it does, when to use it, the parameter format, and the return value shape. There are no significant gaps. The complexity is low, and the description fully covers the context.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The schema description for specId is minimal ('required,'), but the description enriches it by specifying 'The 32-character MD5 hash ID of the specification.' This gives concrete format details beyond the schema, adding real value. Schema coverage is 100%, and the description supplements it well, warranting a score above the baseline.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool 'Lists all tags across an entire API specification, spanning all collections.' This specifies a concrete verb (lists), a resource (tags), and a scope (entire API spec), and it distinguishes itself from the sibling tool tag_by_collection by emphasizing the global scope.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description provides an explicit 'When to use' section with bullet points, including situations like wanting every tag or needing a global view. It also explicitly directs users to use tag_by_collection instead for single-collection queries, giving clear when-to-use and when-not-to-use guidance.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
19 tool updates
v1.0.0- First observed
collection_by_id - First observed
collection_by_spec - First observed
endpoint_by_collection - First observed
endpoint_by_id - First observed
endpoint_by_spec - First observed
endpoint_by_tag - First observed
info - First observed
inspect - First observed
invoke - First observed
response_compress - First observed
response_filter - First observed
response_outline - First observed
response_slice - First observed
search - First observed
spec_by_id - First observed
spec_list - First observed
tag_by_collection - First observed
tag_by_id - First observed
tag_by_spec
TDQS
Each tool targets a distinct entity (spec, collection, tag, endpoint) and scope (list, get, by_spec, by_tag, etc.) or a distinct action (search, inspect, invoke, info, response_*). The response_* tools are clearly differentiated: outline for structure, slice for extraction, filter for search/pagination, and compress for size reduction. Even the similar endpoint_by_id vs inspect are explicitly separated by 'quick summary' vs 'full technical details'.
The naming follows a strong `resource_by_scope` pattern (e.g., endpoint_by_tag, collection_by_spec, tag_by_id) and consistent action verbs (search, invoke, info). The response_* prefix is uniform. Minor deviations: `spec_list` doesn't follow the `*_by_*` pattern, and `inspect` is an exception to the endpoint detail retrieval naming compared to `endpoint_by_id`.
With 19 tools, this is slightly above the 'well-scoped' range (3–15) and in the 'heavy' band, but the count is justified by the domain: the spec-collection-tag-endpoint hierarchy yields 11 navigation tools, plus essential action tools (search, inspect, invoke, info) and 4 dedicated response-handling tools for large payloads. Each tool earns its place, though scope-combining could reduce redundancy.
The hierarchical navigation is complete: list and get for spec, collection, tag, and endpoint; search for discovery; inspect for full schemas; invoke for execution; and a full response post-processing pipeline (outline → slice/filter/compress). The only notable gap is the absence of a tool to export the raw OpenAPI specification document, but that is not essential for the stated purpose of discovering, inspecting, and invoking endpoints.
Maintenance
Related MCP Connectors
Self-hosted MCP gateway: turn any API, database or MCP server into AI connectors — no code.
MCP server for AI access to Swagger by SmartBear.
- UnifAPIOAuthcom.unifapi
Hosted MCP server for live public-data APIs and Skills for AI agents.
MCP server that lets AI assistants use all OneSchema features exposed via the public API.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceAutomatically converts Swagger/OpenAPI specifications into MCP servers, enabling AI agents to interact with any REST API through natural language by exposing endpoints as AI-friendly tools.3-
- AlicenseNot gradedqualityCmaintenanceTurns any OpenAPI specification into a fully working MCP server with a single command, enabling AI agents to call APIs without writing any glue code.13MIT
- AlicenseNot gradedqualityBmaintenanceConverts any OpenAPI specification into an MCP server, allowing AI assistants to interact with REST APIs through natural language.161MIT
- AlicenseNot gradedqualityCmaintenanceEnables LLMs to interact with any REST API that has an OpenAPI specification by providing a lightweight MCP server that translates between natural language and API calls.MIT
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/mmadfox/swag2mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server