Search API Spec
swagger_searchFind API endpoints, schemas, and properties matching a search term across a loaded OpenAPI specification. Locate relevant documentation quickly by querying paths, summaries, operationIds, tags, and schema names.
Instructions
Search across all endpoints and schemas in a loaded OpenAPI spec for a given query string.
Searches through endpoint paths, operation summaries, operationIds, descriptions, tags, schema names, and property names.
Args:
spec_name (string): Name of the previously loaded spec
query (string): Search term to find in endpoint paths, summaries, operationIds, tags, schema names, and property descriptions
Returns: { "total": number, // Total number of matches "results": [ { "type": "endpoint" | "schema" | "property", "path": string, // URL path (for endpoints) "method": string, // HTTP method (for endpoints) "schemaName": string, // Schema name (for schemas/properties) "propertyName": string, // Property name (for properties) "match": string, // Human-readable match description "summary": string // Brief description } ] }
Examples:
Use when: "Search for anything about pets" -> params with spec_name="", query="pet"
Use when: "Find endpoints related to users" -> params with spec_name="", query="user"
Error Handling:
Returns error if the spec name has not been loaded
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": {
"spec_name": "<spec_name>",
"query": "<query>"
},
"name": "swagger_search"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | Search term to find in endpoint paths, summaries, operationIds, tags, schema names, and property descriptions | |
| spec_name | Yes | Name of the previously loaded OpenAPI/Swagger spec (use swagger_list_loaded to see available names) |