AI Skill Hub 强烈推荐:FastAPI-MCP工具集 是一款优质的MCP工具。在 GitHub 上收获超过 11.9k 颗 Star,AI 综合评分 8.5 分,在同类工具中表现稳健。如果你正在寻找可靠的MCP工具解决方案,这是一个值得深入了解的选择。
将FastAPI端点暴露为模型上下文协议(MCP)工具的开源框架,支持完整的身份验证和授权机制。适合AI应用开发者快速集成API接口到Claude、Cursor等AI工具中,简化智能体与后端服务的交互。
FastAPI-MCP工具集 是一款遵循 MCP(Model Context Protocol)标准协议的 AI 工具扩展。通过 MCP 协议,它可以让 Claude、Cursor 等主流 AI 客户端直接访问和操作外部工具、数据源和服务,实现 AI 能力的无缝扩展。无论是文件操作、数据库查询还是 API 调用,都可以通过自然语言在 AI 对话中直接触发,极大提升生产效率。
将FastAPI端点暴露为模型上下文协议(MCP)工具的开源框架,支持完整的身份验证和授权机制。适合AI应用开发者快速集成API接口到Claude、Cursor等AI工具中,简化智能体与后端服务的交互。
FastAPI-MCP工具集 是一款遵循 MCP(Model Context Protocol)标准协议的 AI 工具扩展。通过 MCP 协议,它可以让 Claude、Cursor 等主流 AI 客户端直接访问和操作外部工具、数据源和服务,实现 AI 能力的无缝扩展。无论是文件操作、数据库查询还是 API 调用,都可以通过自然语言在 AI 对话中直接触发,极大提升生产效率。
# 方式一:通过 Claude Code CLI 一键安装
claude skill install https://github.com/tadata-org/fastapi_mcp
# 方式二:手动配置 claude_desktop_config.json
{
"mcpServers": {
"fastapi-mcp---": {
"command": "npx",
"args": ["-y", "fastapi_mcp"]
}
}
}
# 配置文件位置
# macOS: ~/Library/Application Support/Claude/claude_desktop_config.json
# Windows: %APPDATA%/Claude/claude_desktop_config.json
# 安装后在 Claude 对话中直接使用 # 示例: 用户: 请帮我用 FastAPI-MCP工具集 执行以下任务... Claude: [自动调用 FastAPI-MCP工具集 MCP 工具处理请求] # 查看可用工具列表 # 在 Claude 中输入:"列出所有可用的 MCP 工具"
// claude_desktop_config.json 配置示例
{
"mcpServers": {
"fastapi-mcp___": {
"command": "npx",
"args": ["-y", "fastapi_mcp"],
"env": {
// "API_KEY": "your-api-key-here"
}
}
}
}
// 保存后重启 Claude Desktop 生效
<p align="center">Expose your FastAPI endpoints as Model Context Protocol (MCP) tools, with Auth!</p> <div align="center">
</div>
<p align="center"><a href="https://github.com/tadata-org/fastapi_mcp"><img src="https://github.com/user-attachments/assets/b205adc6-28c0-4e3c-a68b-9c1a80eb7d0c" alt="fastapi-mcp-usage" height="400"/></a></p>
We recommend using uv, a fast Python package installer:
uv add fastapi-mcp
Alternatively, you can install with pip:
pip install fastapi-mcp
The simplest way to use FastAPI-MCP is to add an MCP server directly to your FastAPI application:
```python from fastapi import FastAPI from fastapi_mcp import FastApiMCP
app = FastAPI()
mcp = FastApiMCP(app)
FastAPI-MCP provides comprehensive documentation. Additionaly, check out the examples directory for code samples demonstrating these features in action.
mcp.mount() ```
That's it! Your auto-generated MCP server is now available at https://app.base.url/mcp.
FastAPI-MCP is designed as a native extension of FastAPI, not just a converter that generates MCP tools from your API. This approach offers several key advantages:
Depends() for authentication and authorizationThis design philosophy ensures minimum friction when adding MCP capabilities to your existing FastAPI services.
高星开源项目,MCP与FastAPI的完美结合,认证授权设计完善。社区活跃度高,代码质量稳定,是AI工具开发的优选方案。
AI Skill Hub 为第三方内容聚合平台,本页面信息基于公开数据整理,不对工具功能和质量作任何法律背书。
建议在沙箱或测试环境中充分验证后,再部署至生产环境,并做好必要的安全评估。
✅ MIT 协议 — 最宽松的开源协议之一,可自由商用、修改、分发,仅需保留版权声明。
总体来看,FastAPI-MCP工具集 是一款质量优秀的MCP工具,在同类工具中具备一定竞争力。AI Skill Hub 将持续追踪其更新动态,建议收藏备用,结合自身场景选择合适时机引入使用。
| 原始名称 | fastapi_mcp |
| 原始描述 | 开源MCP工具:Expose your FastAPI endpoints as Model Context Protocol (MCP) tools, with Auth!。⭐11.9k · Python |
| Topics | MCP协议FastAPIAI工具认证授权Claude集成 |
| GitHub | https://github.com/tadata-org/fastapi_mcp |
| License | MIT |
| 语言 | Python |
收录时间:2026-05-13 · 更新时间:2026-05-16 · License:MIT · AI Skill Hub 不对第三方内容的准确性作法律背书。
选择 Agent 类型,复制安装指令后粘贴到对应客户端