Skip to main content
Glama
internal-swagger-mcp

internal-swagger-mcp

by zhangwanli09

Get Swagger API Detail

swagger_get_api_detail
Read-onlyIdempotent

Retrieve full details for one API interface by service, method, and path, including parameter definitions, nested fields, response examples, and mock response fields.

Instructions

Get full details of a single API interface, including all parameter definitions and response examples.

Parameters:

  • source (required): Service name, from the [service name] returned by swagger_list_sources or swagger_search_api.

  • method (required): HTTP method, e.g. "GET", "POST".

  • path (required): Full interface path, e.g. "/qmAuthorityCenter/systemFun/initPerformanceSolution".

Response includes:

  • Basic interface info (name, description, status, Content-Type).

  • Full definitions for Query / Path / Header / Form / Body parameters (name, type, required, description). Required column: "是" = required, "否" = optional, "?" = platform metadata is ambiguous (checkType=1 with no error message — cross-check with backend code or treat as optional).

  • Sub-fields of nested Object parameters.

  • Response results (Demo JSON + output field table).

  • Mock response field table.

Input Schema

NameRequiredDescriptionDefault
pathYesFull interface path, e.g. /qmAuthorityCenter/systemFun/initPerformanceSolution
methodYesHTTP method.
sourceYesService name, from swagger_list_sources or swagger_search_api results.

Output Schema

NameRequiredDescriptionDefault
nameYes
pathYes
methodYes
statusYes
responsesYes
mockFieldsYes
moduleNameYes
parametersYes
sourceNameYes
contentTypeNo
descriptionYes
bodyRequestDemoNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed22 schema fields changedv2.1.0
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • addedOutput schema / $defs
      Added value: +{
      +  "__schema0": {
      +    "additionalProperties": false,
      +    "properties": {
      +      "children": {
      +        "items": {
      +          "$ref": "#/$defs/__schema0"
      +        },
      +        "type": "array"
      +      },
      +      "description": {
      +        "type": "string"
      +      },
      +      "name": {
      +        "type": "string"
      +      },
      +      "required": {
      +        "enum": [
      +          "yes",
      +          "no",
      +          "unknown"
      +        ],
      +        "type": "string"
      +      },
      +      "type": {
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "name",
      +      "type",
      +      "required",
      +      "description"
      +    ],
      +    "type": "object"
      +  },
      +  "__schema1": {
      +    "additionalProperties": false,
      +    "properties": {
      +      "children": {
      +        "items": {
      +          "$ref": "#/$defs/__schema1"
      +        },
      +        "type": "array"
      +      },
      +      "description": {
      +        "type": "string"
      +      },
      +      "name": {
      +        "type": "string"
      +      },
      +      "type": {
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "name",
      +      "type",
      +      "description"
      +    ],
      +    "type": "object"
      +  },
      +  "__schema2": {
      +    "additionalProperties": false,
      +    "properties": {
      +      "children": {
      +        "items": {
      +          "$ref": "#/$defs/__schema2"
      +        },
      +        "type": "array"
      +      },
      +      "defaultValue": {
      +        "type": "string"
      +      },
      +      "description": {
      +        "type": "string"
      +      },
      +      "name": {
      +        "type": "string"
      +      },
      +      "type": {
      +        "type": "string"
      +      }
      +    },
      +    "required": [
      +      "name",
      +      "type",
      +      "description"
      +    ],
      +    "type": "object"
      +  }
      +}
    • changedOutput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
    • addedOutput schema / properties / mockFields / items / $ref
      Added value: +"#/$defs/__schema2"
    • removedOutput schema / properties / mockFields / items / additionalProperties
      Removed value: -false
    • removedOutput schema / properties / mockFields / items / properties
      Removed value: -{
      -  "children": {
      -    "items": {
      -      "$ref": "#/properties/mockFields/items"
      -    },
      -    "type": "array"
      -  },
      -  "defaultValue": {
      -    "type": "string"
      -  },
      -  "description": {
      -    "type": "string"
      -  },
      -  "name": {
      -    "type": "string"
      -  },
      -  "type": {
      -    "type": "string"
      -  }
      -}
    • removedOutput schema / properties / mockFields / items / required
      Removed value: -[
      -  "name",
      -  "type",
      -  "description"
      -]
    • removedOutput schema / properties / mockFields / items / type
      Removed value: -"object"
    • changedOutput schema / properties / parameters / properties / body / items / $ref
      Previous value: -"#/properties/parameters/properties/query/items"New value: +"#/$defs/__schema0"
    • changedOutput schema / properties / parameters / properties / form / items / $ref
      Previous value: -"#/properties/parameters/properties/query/items"New value: +"#/$defs/__schema0"
    • changedOutput schema / properties / parameters / properties / header / items / $ref
      Previous value: -"#/properties/parameters/properties/query/items"New value: +"#/$defs/__schema0"
    • changedOutput schema / properties / parameters / properties / path / items / $ref
      Previous value: -"#/properties/parameters/properties/query/items"New value: +"#/$defs/__schema0"
    • addedOutput schema / properties / parameters / properties / query / items / $ref
      Added value: +"#/$defs/__schema0"
    • removedOutput schema / properties / parameters / properties / query / items / additionalProperties
      Removed value: -false
    • removedOutput schema / properties / parameters / properties / query / items / properties
      Removed value: -{
      -  "children": {
      -    "items": {
      -      "$ref": "#/properties/parameters/properties/query/items"
      -    },
      -    "type": "array"
      -  },
      -  "description": {
      -    "type": "string"
      -  },
      -  "name": {
      -    "type": "string"
      -  },
      -  "required": {
      -    "enum": [
      -      "yes",
      -      "no",
      -      "unknown"
      -    ],
      -    "type": "string"
      -  },
      -  "type": {
      -    "type": "string"
      -  }
      -}
    • removedOutput schema / properties / parameters / properties / query / items / required
      Removed value: -[
      -  "name",
      -  "type",
      -  "required",
      -  "description"
      -]
    • removedOutput schema / properties / parameters / properties / query / items / type
      Removed value: -"object"
    • addedOutput schema / properties / responses / items / properties / fields / items / $ref
      Added value: +"#/$defs/__schema1"
    • removedOutput schema / properties / responses / items / properties / fields / items / additionalProperties
      Removed value: -false
    • removedOutput schema / properties / responses / items / properties / fields / items / properties
      Removed value: -{
      -  "children": {
      -    "items": {
      -      "$ref": "#/properties/responses/items/properties/fields/items"
      -    },
      -    "type": "array"
      -  },
      -  "description": {
      -    "type": "string"
      -  },
      -  "name": {
      -    "type": "string"
      -  },
      -  "type": {
      -    "type": "string"
      -  }
      -}
    • removedOutput schema / properties / responses / items / properties / fields / items / required
      Removed value: -[
      -  "name",
      -  "type",
      -  "description"
      -]
    • removedOutput schema / properties / responses / items / properties / fields / items / type
      Removed value: -"object"
  2. First observedv1.0.5

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, openWorldHint, idempotentHint, and destructiveHint=false, so the safety profile is covered. The description adds valuable behavioral context about the response contents, including parameter definitions, nested object sub-fields, response results, mock responses, and the special "?" required-column ambiguity, which helps the agent interpret output correctly.

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?

The description is well-structured with a front-loaded purpose, separate Parameters and Response sections, and concrete examples. It is somewhat long but appropriate for a detail-oriented tool, and the sections help the agent scan for relevant information.

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

Completeness5/5

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

Given the tool has an output schema and rich annotations, the description provides complete context: it explains the purpose, source provenance, parameter examples, response structure, nested object handling, and the ambiguous required-column indicator. Nothing critical for correct invocation or interpretation is missing.

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 the input schema already documents all parameters and examples. The description largely repeats the same parameter meanings without adding significant new syntax or constraints beyond what the schema provides, so baseline 3 is appropriate.

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?

The description states a specific verb and resource: retrieving full details of a single API interface, including parameter definitions and response examples. This clearly distinguishes it from sibling tools like swagger_list_sources and swagger_search_api, which are referenced for obtaining the source name.

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 description implies the tool should be used after swagger_list_sources or swagger_search_api by specifying that the source parameter comes from those tools. It provides clear context for retrieving full details, but does not explicitly state when to use this tool versus search_api or list_sources beyond the implied workflow.

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