mcp线
mcp-wire是一个Go CLI,它通过一个界面跨多个AI编码工具安装和配置mcp(模型上下文协议)服务器。
运作原理
无需手动编辑配置。跑 mcp-wire 使用指导安装和卸载向导打开全屏TUI。
选择来源
从捆绑的策划服务或社区MCP注册表中选择:
mcp-wire — Install
Install › Source
Where should mcp-wire look for services?
› Curated services recommended, maintained by mcp-wire
Registry services community-published MCP servers
Both curated + registry combined
↑↓ move Enter select Esc back搜索并选择服务
在数百个注册表项中进行实时筛选搜索:
mcp-wire — Install
Install › community ✓ › Service › Targets › Review › Apply
Search: sentry 2 matches
› ai.sentry/sentry-mcp
Sentry error tracking and performance monitoring MCP server
ai.example/sentry-alerts
Forward Sentry alerts to your AI coding assistant
— end of results —
↑↓ move Enter select type to filter Esc back安装前检查
注册表服务显示元数据并需要明确确认:
mcp-wire — Install
Install › community ✓ › Service › Targets › Review › Apply
△ Registry Service — not curated by mcp-wire
ai.sentry/sentry-mcp
Sentry error tracking and performance monitoring MCP server
Source: community registry
Transport: http
URL: https://mcp.sentry.io/sse
Registry services are community-published. Review before proceeding.
› Yes, proceed No, go back
←→ move Enter confirm Esc back显式CLI模式
对于脚本和CI,显式命令在没有TUI的情况下工作:
mcp-wire install jira --target claude --no-prompt
mcp-wire uninstall sentry --target opencode范围感知安装(Claude代码)
对于支持作用域的目标(目前是Claude Code),您可以选择编写MCP配置的位置:
user(默认):跨项目可用project:仅适用于当前项目
mcp-wire install jira --target claude --scope user
mcp-wire install jira --target claude --scope project
mcp-wire uninstall jira --target claude --scope project支持的目标
claude-克劳德代码codex-Codex CLIgemini-Gemini CLIopencode-OpenCode
支持服务列表
捆绑(策划)
这些附带二进制文件,开箱即用:
context7-Context7文档查找MCP(OAuth)jira-Atlassian Rovo MCP服务器(OAuth)sentry-哨兵MCP服务器(OAuth)playwright-Playwright浏览器自动化MCP(npx @playwright/mcp@latest)
MCP注册中心(社区)
mcp线也可以从以下位置安装 MCP官方登记处,允许访问数百个社区发布的MCP服务器。启用:
mcp-wire feature enable registry启用后,安装向导将提供一个源选择步骤(Curated/Registry/Both),对所有注册表项进行实时搜索。
安装
自制(macOS/Linux)
brew tap andreagrandi/tap
brew install mcp-wire从源代码构建
git clone https://github.com/andreagrandi/mcp-wire
cd mcp-wire
make build
./bin/mcp-wire贡献
欢迎提供意见,特别是新的服务定义。
- 通过YAML添加新服务:在中创建文件
services/(无需Go代码)。 - 服务架构:
name,description,transport,或者url(为sse/http)或command/args(为stdio). - 运输价值:
http(可流式传输的HTTP端点),sse(服务器发送事件端点),stdio(基于本地命令的MCP服务器)。 - OAuth服务:添加
auth: oauth在适用的情况下,安装流可以驱动身份验证提示/自动化。 - 在PR之前运行检查:
make test,make test-integration,make build.
示例服务文件:
name: example
description: "Example MCP"
transport: http
auth: oauth
url: "https://mcp.example.com/mcp"
env: []示例 stdio 服务:
name: example-stdio
description: "Example local MCP"
transport: stdio
command: npx
args: ["-y", "@example/mcp-server"]
env: []