Apidog MCP Server 讓 Cursor 等 AI 驅動的 IDE 能夠直接存取並使用你的 API 規格,加速開發並簡化你的工作流程。Apidog MCP Server 目前處於 beta 版階段。本文件將定期更新,加入新功能與改進。
你可以用 Apidog MCP Server 做什麼?#
透過 Apidog MCP Server,AI 助理可以:運作方式#
設定完成後,Apidog MCP Server 會自動讀取所有 API 規格資料並快取到本機。接著,AI 就能順暢地擷取並使用這些資料。"Use MCP to fetch the API specification and generate Java records for the 'Product' schema and related schemas"
"Based on the API specification, add the new fields to the 'Product' DTO"
"Add comments for each field in the 'Product' class based on the API specification"
"Generate all the MVC code related to the endpoint '/users' according to the API specification"
API 規格會快取在本機。如果 Apidog 中的資料發生變更,請要求 AI 重新整理,以確保它讀取最新更新。
先決條件#
在設定 Apidog MCP Server 之前,請確認你具備:Node.js(版本 18 或更新版本,最好是最新的 LTS 版本)
選擇你的資料來源#
Apidog MCP Server 支援三種不同的資料來源。請選擇符合你需求的設定方式:私有化部署設定#
對於私有化部署,無論你選擇哪種資料來源,都請將你的伺服器 API 位址加入設定:{
"mcpServers": {
"API specification": {
"command": "npx",
"args": [
"-y",
"apidog-mcp-server@latest",
"--apidog-api-base-url=<your-server-url>"
]
}
}
}
將 <your-server-url> 替換為你的私有化伺服器 API 位址(以 http:// 或 https:// 開頭)。請確保你的環境可以正常存取 www.npmjs.com。
說明與支援#
Apidog MCP Server 目前處於 beta 版階段。我們很樂意聽取你的回饋與建議!