mcp-swagger-reader
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| SWAGGER_PROJECTS | No | JSON string of an array of project objects, each with name and swaggerUrl. Example: '[{"name":"my-api","swaggerUrl":"http://example.com/swagger.json"}]' |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
This server publishes no instructions, or was last inspected before Glama recorded them.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": true
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| add_swagger_projectC | 添加一个项目的Swagger/OpenAPI配置 |
| list_swagger_projectsA | 列出所有已配置的Swagger项目 |
| get_api_endpointsA | 获取指定项目的所有API接口列表 |
| get_api_detailC | 获取指定接口的详细信息 |
| get_schemasB | 获取指定项目的所有数据模型/Schemas |
| search_apisB | 根据关键词搜索API接口 |
| reload_swaggerB | 重新加载项目的Swagger规范,同时清除类型缓存 |
| clear_type_cacheA | 清除指定项目的类型缓存,强制重新生成 |
| generate_ts_by_endpointC | 根据 API 接口路径和方法生成 TypeScript 类型(请求参数、Body、响应),作为模型输入,可以进一步调整并输出 |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 9 tools
Most tools target distinct resources and actions: endpoints, schemas, projects, and type generation are clearly separated. The only potential confusion is between reload_swagger and clear_type_cache, as reload also clears the type cache, but the descriptions clarify that reload additionally re-fetches the spec.
Tool names consistently follow a snake_case verb_noun pattern (get_, list_, add_, search_, clear_, generate_). Minor inconsistencies exist, such as 'get_schemas' missing an 'api' prefix and 'list_swagger_projects' plural versus 'add_swagger_project' singular, but the overall pattern is predictable.
With 9 tools, the server is well-scoped for its purpose. Each tool serves a distinct function within the Swagger/OpenAPI management and code generation workflow, without unnecessary redundancy or bloat.
Core workflows are well covered: project setup, listing, reloading, endpoint discovery, schema inspection, and TypeScript generation. The main gap is that projects can be added but not deleted or updated, which may be a minor limitation for full project lifecycle management.