单一入口聚合多台MCP服务器的代理方案

该代理把多个MCP服务器聚合到同一个HTTP入口,统一对外提供工具、提示和资源,并支持SSE与streamable HTTP两种服务方式,以及stdio、sse、streamable-http三类下游客户端配置。

# MCP 代理服务器 一个MCP的代理,将多个MCP服务器集成在一个单一的HTTP入口之后. ## 特征 - 代理多个MCP客户端:集合工具,提示,以及来自许多服务器的资源. - SSE和可流的HTTP:通过Server_Sent Events或可流的HTTP服务. - 弹性配置: 支持 `stdio`, `sse`,以及 `streamable-http` 客户类型。 - OAuth客户端支持:对需要交互OAuth(如Notion)的下游服务器进行一次授权,然后让代理持有并刷新每个呼叫者的令牌. ## 文档 - 配置 : [docs/CONFIGURATION.md](<https://github.com/tbxark/mcp-proxy/blob/master/docs/CONFIGURATION.md>) - 用法 : [docs/USAGE.md](<https://github.com/tbxark/mcp-proxy/blob/master/docs/USAGE.md>) - 部署: [docs/DEPLOYMENT.md](<https://github.com/tbxark/mcp-proxy/blob/master/docs/DEPLOYMENT.md>) - Claude 配置转换器: https://tbxark.github.io/mcp-proxy ## 快速启动 ### 从源头构建 ```bash git clone https://github.com/tbxark/mcp-proxy.git cd mcp-proxy make build ./build/mcp-proxy --config path/to/config.json ``` ### 通过 Go 安装 ```bash go install github.com/tbxark/mcp-proxy@latest ``` ### 嵌入器 图像包括支持通过 MCP 服务器发射 `npx` 财务报告和财务报告 `uvx`. ```bash docker run -d -p 9090:9090 -v /path/to/config.json:/config/config.json ghcr.io/tbxark/mcp-proxy:latest # or provide a remote config docker run -d -p 9090:9090 ghcr.io/tbxark/mcp-proxy:latest --config https://example.com/config.json ``` 更多部署选项(包括 Docker compose) 正在使用 [docs/DEPLOYMENT.md](<https://github.com/tbxark/mcp-proxy/blob/master/docs/DEPLOYMENT.md>). ## 配置 参见完整配置参考文献和示例 [docs/CONFIGURATION.md](<https://github.com/tbxark/mcp-proxy/blob/master/docs/CONFIGURATION.md>). 在线 Claude 配置转换器可用: https://tbxark.github.io/mcp-proxy ## 使用量 命令的旗、端点和认证示例在 [docs/USAGE.md](<https://github.com/tbxark/mcp-proxy/blob/master/docs/USAGE.md>). ## 捐款 不接受个人第三方或商业MCP服务的实例;通用实例存在于 [docs/CONFIGURATION.md](<https://github.com/tbxark/mcp-proxy/blob/master/docs/CONFIGURATION.md>). ## 谢谢 - 这个项目的灵感来自 [adamwattis/mcp-proxy-server](https://github.com/adamwattis/mcp-proxy-server) 项目 - 如果你有任何关于部署的问题,可以指: [《在 Docker 沙箱中运行 MCP Server》](https://miantiao.me/posts/guide-to-running-mcp-server-in-a-sandbox/)([@ccbikai](https://github.com/ccbikai)) ## 许可证 该项目根据MIT许可证获得许可。 [LICENSE](<https://github.com/tbxark/mcp-proxy/blob/master/LICENSE>) 详细文件。

查看原始来源