
reapi-com/mcp-openAPI 是从 https://github.com/reapi-com/mcp-openapi. 导入的 MCP 服务器候选
概览
reapi-com/mcp-openAPI 是从 https://github.com/reapi-com/mcp-openapi. 导入的 MCP 服务器候选
概述(AI 翻译)
一台模型上下文协议(MCP)服务器,加载并服务多个 OpenAPI 规范,以实现基于 LLM 的集成开发环境集成。该服务器作为 OpenAPI 规范与基于 LLM 的开发工具(如 Cursor 及其他代码编辑器)之间的桥梁。
特色
- 从目录加载多个 OpenAPI 规范
- 通过MCP协议暴露API操作和模式
- 使LLM能够直接在IDE中理解并操作你的API。
- 支持去引用的模式,以实现完整的 API 上下文
- 维护所有可用API的目录
由ReAPI提供技术支持
这个开源MCP服务器由ReAPI赞助,ReAPI是一个简化API设计和测试的下一代API平台。虽然该服务器为开发提供本地OpenAPI集成,但ReAPI提供了两个强大的模块:
🎨 API CMS
- 使用直观的无代码编辑器设计 API
- 自动生成和发布OpenAPI规范
- 实时与团队成员协作
- 版本控制与变更管理
🧪 API 测试
- 最友好的无代码API测试解决方案
- 创建和管理直观界面的测试用例
本页由 AI 翻译,技术细节请以原文为准。
README
以下为原文 README 节选,完整内容请查看原文。
@reapi/mcp-openapi
A Model Context Protocol (MCP) server that loads and serves multiple OpenAPI specifications to enable LLM-powered IDE integrations. This server acts as a bridge between your OpenAPI specifications and LLM-powered development tools like Cursor and other code editors.
Features
- Loads multiple OpenAPI specifications from a directory
- Exposes API operations and schemas through MCP protocol
- Enables LLMs to understand and work with your APIs directly in your IDE
- Supports dereferenced schemas for complete API context
- Maintains a catalog of all available APIs
Powered by ReAPI
This open-source MCP server is sponsored by ReAPI, a next-generation API platform that simplifies API design and testing. While this server provides local OpenAPI integration for development, ReAPI offers two powerful modules:
🎨 API CMS
- Design APIs using an intuitive no-code editor
- Generate and publish OpenAPI specifications automatically
- Collaborate with team members in real-time
- Version control and change management
🧪 API Testing
- The most developer-friendly no-code API testing solution
- Create and manage test cases with an intuitive interface
- Powerful assertion and validation capabilities
- Serverless cloud test executor
- Perfect for both QA teams and developers
- CI/CD integration ready
Try ReAPI for free at reapi.com and experience the future of API development.
Cursor Configuration
To integrate the MCP OpenAPI server with Cursor IDE, you have two options for configuration locations:
Option 1: Project-specific Configuration (Recommended)
Create a .cursor/mcp.json file in your project directory. This option is recommended as it allows you to maintain different sets of specs for different projects
{
"mcpServers": {
"@reapi/mcp-openapi": {
"command": "npx",
"args": ["-y", "@reapi/mcp-openapi@latest", "--dir", "./specs"],
"env": {}
}
}
}
Tip: Using a relative path like
./specsmakes the configuration portable and easier to share across team members.Note: We recommend using
@latesttag as we frequently update the server with new features and improvements.Important: Project-specific configuration helps manage LLM context limits. When all specifications are placed in a single folder, the combined metadata could exceed the LLM’s context window, leading to errors. Organizing specs by project keeps the context size manageable.
Option 2: Global Configuration
Create or edit ~/.cursor/mcp.json in your home directory to make the server available across all projects:
{
"mcpServers": {
"@reapi/mcp-openapi": {
"command": "npx",
"args": ["-y", "@reapi/mcp-openapi@latest", "--dir", "/path/to/your/specs"],
"env": {}
}
}
}
Enable in Cursor Settings
After adding the configuration:
- Open Cursor IDE
安装
npx -y @reapi/mcp-openapi@latest --dir ./specs配置
{
"mcpServers": {
"@reapi/mcp-openapi": {
"command": "npx",
"args": ["-y", "@reapi/mcp-openapi@latest", "--dir", "./specs"],
"env": {}
}
}
}