Mcp 連結 將任何 Openapi V3 API 轉換為 Mcp 伺服器
概覽
什麼是 MCP-Link?
MCP-Link 是一個創新的工具,旨在將任何 OpenAPI V3 API 轉換為完全功能的 MCP(微服務通信協議)伺服器。這使得開發人員可以輕鬆創建和管理微服務,提高應用程序的可擴展性和效率。通過利用 OpenAPI 規範的力量,MCP-Link 簡化了 API 集成和管理的過程。
MCP-Link 的特點
- OpenAPI V3 兼容性:MCP-Link 支持最新的 OpenAPI V3 規範,確保開發人員可以無縫地使用現代 API。
- 簡單轉換:該工具自動化轉換過程,使用戶能夠以最小的努力將其 OpenAPI 定義轉換為 MCP 伺服器。
- 用戶友好界面:MCP-Link 提供直觀的界面,使開發人員能夠輕鬆導航並有效利用其功能。
- 可擴展性:MCP-Link 以可擴展性為設計理念,允許開發人員在不妥協性能的情況下管理多個微服務。
- 文檔生成:自動生成所創建的 MCP 伺服器的全面文檔,使團隊更容易理解和使用 API。
如何使用 MCP-Link
- 訪問工具:訪問 MCP-Link 網站 以訪問該工具。
- 上傳 OpenAPI 規範:首先上傳您的 OpenAPI V3 規範文件。MCP-Link 將讀取該文件並準備轉換。
- 配置設置:調整任何必要的設置,以根據您的具體需求定制 MCP 伺服器。
- 轉換為 MCP 伺服器:啟動轉換過程。MCP-Link 將根據您的 OpenAPI 定義生成 MCP 伺服器。
- 部署和管理:轉換完成後,部署您的 MCP 伺服器並通過提供的界面進行管理。
常見問題解答
問題 1:什麼是 OpenAPI V3?
回答 1:OpenAPI V3 是一種構建 API 的規範,允許開發人員以標準化的方式描述其 API 的端點、請求/響應格式和身份驗證方法。
問題 2:MCP-Link 能處理複雜的 API 嗎?
回答 2:是的,MCP-Link 設計用於處理複雜的 API,適用於各種應用程序和服務。
問題 3:使用 MCP-Link 是否需要費用?
回答 3:MCP-Link 目前作為公共工具提供,使用者可以免費訪問其功能。
問題 4:MCP-Link 支持哪些編程語言?
回答 4:MCP-Link 是語言無關的,這意味著它可以與任何能夠與 HTTP API 互動的編程語言一起使用。
問題 5:我如何能為 MCP-Link 做出貢獻?
回答 5:歡迎貢獻!您可以訪問 GitHub 上的 MCP-Link 倉庫來報告問題、建議功能或提交拉取請求。
詳細
MCP Link - Convert Any OpenAPI V3 API to MCP Server
🧩 Architecture
🤔 Why MCP Link?
There is a notable gap in the current AI Agent ecosystem:
- Most MCP Servers are simple wrappers around Web APIs
- Functionality interfaces may not be complete, depending on developer implementation
- Manual creation of MCP interfaces is time-consuming and error-prone
- Lack of standardized conversion processes
MCP Link solves these issues through automation and standardization, allowing any API to easily join the AI-driven application ecosystem.
🌟 Key Features
- Automatic Conversion: Generate complete MCP Servers based on OpenAPI Schema
- Seamless Integration: Make existing RESTful APIs immediately compatible with AI Agent calling standards
- Complete Functionality: Ensure all API endpoints and features are correctly mapped
- Zero Code Modification: Obtain MCP compatibility without modifying the original API implementation
- Open Standard: Follow the MCP specification to ensure compatibility with various AI Agent frameworks
🌐 Online Version
Try our hosted version at mcp-link.vercel.app to quickly convert and test your APIs without installation.
🚀 Quick Start
Installation
### Clone repository
git clone https://github.com/automation-ai-labs/mcp-link.git
cd mcp-openapi-to-mcp-adapter
### Install dependencies
go mod download
Running
### Specify port
go run main.go serve --port 8080 --host 0.0.0.0
Parameter Description
s=
- URL of the OpenAPI specification fileu=
- Base URL of the target APIh=
- Authentication header format, in the format ofheader-name:value-prefix
f=
- Path filter expressions to include or exclude API endpoints. Syntax:+/path/**
- Include all endpoints under /path/-/path/**
- Exclude all endpoints under /path/+/users/*:GET
- Include only GET endpoints for /users/{id}- Multiple filters can be separated by semicolons:
+/**:GET;-/internal/**
- Wildcards:
*
matches any single path segment,**
matches zero or more segments
Examples
| _ | API | MCP Link URL | Authentication Method |
||--|-||
| | Brave Search | https://mcp-link.vercel.app/links/brave | API Key |
|
| DuckDuckGo | https://mcp-link.vercel.app/links/duckduckgo | None |
|
| Figma | https://mcp-link.vercel.app/links/figma | API Token |
|
| GitHub | https://mcp-link.vercel.app/links/github | Bearer Token |
|
| Home Assistant | https://mcp-link.vercel.app/links/homeassistant | Bearer Token |
|
| Notion | https://mcp-link.vercel.app/links/notion | Bearer Token |
|
| Slack | https://mcp-link.vercel.app/links/slack | Bearer Token |
|
| Stripe | https://mcp-link.vercel.app/links/stripe | Bearer Token |
|
| TMDB | https://mcp-link.vercel.app/links/tmdb | Bearer Token |
|
| YouTube | https://mcp-link.vercel.app/links/youtube | Bearer Token |
Usage in AI Agents
{
"mcpServers": {
"@service-name": {
"url": "http://localhost:8080/sse?s=[OpenAPI-Spec-URL]&u=[API-Base-URL]&h=[Auth-Header]:[Value-Prefix]"
}
}
}
These URLs allow any API with an OpenAPI specification to be immediately converted into an MCP-compatible interface accessible to AI Agents.
📋 Future Development
- MCP Protocol OAuthflow: Implement OAuth authentication flow support for MCP Protocol
- Resources Support: Add capability to handle resource-based API interactions
- MIME Types: Enhance support for various MIME types in API requests and responses
伺服器配置
{
"mcpServers": {
"mcp-link": {
"command": "docker",
"args": [
"run",
"-i",
"--rm",
"ghcr.io/metorial/mcp-container--automation-ai-labs--mcp-link--mcp-link",
"./out"
],
"env": {}
}
}
}