api-mcp-server
Fetches and parses Swagger 2.0 and OpenAPI 3.x documentation from given URLs, intelligently cleans and optimizes the document structure to reduce token consumption, and extracts key API information such as endpoints, parameters, and response formats for use in IDE intelligent features.
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@api-mcp-serverfetch OpenAPI spec from https://api.example.com/swagger.json"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
api-mcp-server
English | 简体中文
This is a Swagger/OpenAPI documentation retrieval tool based on MCP (Model Context Protocol). It can fetch and parse Swagger/OpenAPI documentation from specified URLs, intelligently clean and optimize the documentation to reduce token consumption, and provide it to intelligent IDEs (such as Cursor) in a standardized format. The tool supports multiple transport methods, making it easy for IDEs to retrieve and understand API documentation, enabling intelligent features such as interface suggestions, auto-completion, and code generation.
✨ Features
Intelligent Document Processing
Fetch Swagger/OpenAPI documentation from remote URLs
Support for Swagger 2.0 and OpenAPI 3.x formats
Intelligent cleaning and optimization of document structure to reduce token consumption
Extract key API information including endpoints, parameters, response formats, etc.
IDE-Friendly Design
Standardized API description format
Automatic generation of example requests and responses
Intelligent parameter hints and type inference
Support for code auto-completion and generation
Multiple Transport Methods
stdio: Standard input/output mode for command-line tools
http: HTTP server mode with RESTful interface support
sse: Server-Sent Events mode for real-time communication
Related MCP server: Swagger Navigator MCP Server
Getting Started
MacOS / Linux
{
"mcpServers": {
"api-mcp-server": {
"command": "npx",
"args": [
"-y",
"api-mcp-server",
"--transport",
"stdio",
"--doc-url",
"xxx"
]
}
}
}Windows
{
"mcpServers": {
"api-mcp-server": {
"command": "cmd",
"args": [
"/c",
"npx",
"-y",
"api-mcp-server",
"--transport",
"stdio",
"--doc-url",
"xxx"
]
}
}
}Command Line Arguments
--transport <stdio|http|sse>: Choose transport method (default: stdio)--port <number>: HTTP/SSE server port (default: 3000)--doc-url <url>: Swagger/OpenAPI documentation URL (required)
Usage Examples
1. Basic Usage
# Using stdio mode (default)
npx -y api-mcp-server --doc-url https://api.example.com/swagger.json
# Using HTTP mode
npx -y api-mcp-server --transport http --doc-url https://api.example.com/swagger.json
# Using SSE mode with custom port
npx -y api-mcp-server --transport sse --port 3001 --doc-url https://api.example.com/swagger.json💻 Development
# Clone the repository
git clone https://github.com/bluechenchenchen/api-mcp-server.git
# Install dependencies
pnpm install
# Run in development mode
pnpm dev
# Build
pnpm buildDebugging
Use @modelcontextprotocol/inspector
npx @modelcontextprotocol/inspector
Run Example
pnpm example📋 Requirements
Node.js >= 16.0.0
npm >= 6.0.0 or pnpm >= 6.0.0
📄 License
MIT
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- Flicense-qualityDmaintenanceEnables AI assistants to load, parse, and query OpenAPI/Swagger documentation from URLs with intelligent search across endpoints, schemas, and authentication methods. Provides 10 specialized tools for comprehensive API exploration including path details, operation lookups, and multi-criteria search capabilities.Last updated4
- Alicense-qualityBmaintenanceEnables AI assistants to discover, search, and interact with REST APIs by parsing OpenAPI/Swagger specifications with intelligent fuzzy search across endpoints, supporting both local and remote API sources.Last updated42MIT
- Flicense-qualityDmaintenanceEnables Trae IDE to parse and query Swagger/Knife4j API documentation by converting JSON format interface documents into a searchable text format, allowing developers to efficiently retrieve API information through natural language queries.Last updated
- Alicense-qualityDmaintenanceExposes Swagger/OpenAPI API documentation to AI models, enabling exploration, search, and interaction with endpoints, schemas, and execution of API calls.Last updated492MIT
Related MCP Connectors
Scan any URL for AI agent readability — Vercel Spec, llmstxt.org, and agent-protocol manifests.
Provide your AI coding tools with token-efficient access to up-to-date technical documentation for…
Point Gecko at an OpenAPI spec; get first-call-correct, auth-hidden agent tools.
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/bluechenchenchen/api-mcp-server'
If you have feedback or need assistance with the MCP directory API, please join our Discord server