OpenAPI to MCP Generator
@LostInBrittany
关于 OpenAPI to MCP Generator
A Java program that generates a Quarkus MCP server form an Open API Swagger file
基本信息
配置
工具
未检测到工具
工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。
概览
What is OpenAPI to MCP Generator?
It automatically converts OpenAPI/Swagger specifications into fully functional Model Context Protocol (MCP) servers, allowing LLMs to interact with any REST API through standardized tools. Designed for developers who want to expose REST APIs as MCP-compatible tools.
How to use OpenAPI to MCP Generator?
Use jbang SwaggerToMcpGenerator.java path/to/swagger.json GeneratedMcpServer to generate a server, then jbang GeneratedMcpServer.java to run it. Authentication is configured via environment variables such as API_KEY, BEARER_TOKEN, or API_USERNAME/API_PASSWORD.
Key features of OpenAPI to MCP Generator
- Parses OpenAPI specification files and converts endpoints to MCP tools.
- Supports GET, POST, PUT, DELETE, and PATCH methods.
- Handles path parameters, query parameters, and request bodies.
- Provides API Key, Bearer Token, and Basic authentication support.
- Formats JSON responses and includes robust error handling.
- Allows runtime server selection when multiple servers are defined.
Use cases of OpenAPI to MCP Generator
- Turn any public REST API (e.g., weather data) into LLM-accessible tools.
- Expose internal REST APIs to AI assistants like Claude Desktop.
- Quickly create MCP servers for cloud management APIs (e.g., Clever Cloud).
- Generate standardized tool interfaces without writing manual MCP code.
FAQ from OpenAPI to MCP Generator
What is the Model Context Protocol (MCP)?
MCP is a standardized way for tools and LLMs to communicate, allowing tools to expose functionality to any MCP-compatible LLM and enabling LLMs to discover and use tools consistently.
How do I select a specific server when multiple are defined?
Use the --server-index <index> or --server-url <url> option during generation, or set the SERVER_INDEX or SERVER_URL environment variable at runtime.
How do I authenticate the generated MCP server?
Set environment variables: API_KEY and API_KEY_HEADER for API key auth, BEARER_TOKEN for bearer token, or API_USERNAME and API_PASSWORD for Basic auth.
What HTTP methods are supported?
GET, POST, PUT, DELETE, and PATCH are supported for converting endpoints to MCP tools.
Are there any known limitations or planned improvements?
The README lists planned features including form data/multipart support, OAuth 2.0 authentication, a web UI for spec uploads, and WebSocket endpoint support, indicating these are not yet implemented.
开发工具 分类下的更多 MCP 服务器
FastAPI-MCP
tadata-orgExpose your FastAPI endpoints as Model Context Protocol (MCP) tools, with Auth!
mcp-excalidraw
yctimlinMCP server and Claude Code skill for Excalidraw — programmatic canvas toolkit to create, edit, and export diagrams via AI agents with real-time canvas sync.
nuxt-mcp / vite-plugin-mcp
antfuMCP server helping models to understand your Vite/Nuxt app better.
test
prysmaticlabsGo implementation of Ethereum proof of stake
DevDocs by CyberAGI 🚀
cyberagiincCompletely free, private, UI based Tech Documentation MCP server. Designed for coders and software developers in mind. Easily integrate into Cursor, Windsurf, Cline, Roo Code, Claude Desktop App
评论