Mcp Broker
@NavinAgrawal
关于 Mcp Broker
mcp-broker is a local Model Context Protocol process broker for MCP clients.
配置
使用下面的配置,将此服务器添加到你的 MCP 客户端。
{
"mcpServers": {
"mcp-broker": {
"command": "uvx",
"args": [
"mcp-broker",
"stdio",
"--profile",
"docker",
"--init-if-missing"
],
"env": {}
}
}
}工具
未检测到工具
工具是从 README 中自动提取的。维护者可以在 ## Tools 标题下列出工具,即可填充这部分内容。
概览
What is Mcp Broker?
Mcp Broker is a local Model Context Protocol process broker that sits as a facade in front of many upstream MCP servers. It manages upstream startup, reuse, cleanup, profile exposure, status, and safe tool routing — analogous to PgBouncer for MCP. It is designed for developers using MCP clients (Codex, Claude Code, Gemini CLI) who have more tools than they want in every session and need a single stable local endpoint.
How to use Mcp Broker?
Install via pipx install mcp-broker, uv tool install mcp-broker, or brew install mcp-broker. After installation, run make setup to create a local venv, then make config-init to create a private config from the public template. Edit config/broker.private.yaml for local upstreams, then make config-validate to validate the YAML contract. Start the broker with make broker-start and check status with make broker-status. Wire MCP clients using make config-render CLIENT=<client> (e.g., codex, claude, gemini) after reviewing rendered files.
Key features of Mcp Broker
- Runs one local broker daemon over a Unix socket.
- Starts upstream MCP servers on demand and reuses shared upstreams across sessions.
- Maps upstream tools into stable namespaces exposed via compact broker facade tools.
- Enforces profile-level tool budgets and exposure gates.
- Blocks mutating upstream exposure unless a profile allowlist grants it.
- Provides cross-platform daemon management: LaunchAgent, systemd, and Windows Scheduled Task.
- Includes dry‑run, backup, and rollback for client config rendering.
Use cases of Mcp Broker
- Reduce context window bloat by replacing many raw tool definitions with a single broker facade (measured 93% reduction in tool definitions, 84% in tokens).
- Share upstream MCP servers (OAuth, browser state, databases) across different client sessions without duplicate processes.
- Apply per‑client profiles so each session sees only the tools relevant to the task.
- Centralize lifecycle cleanup to avoid orphaned MCP processes after client sessions exit.
FAQ from Mcp Broker
What problem does Mcp Broker solve?
It solves the problems of duplicated MCP server configurations, duplicate upstream processes across sessions, scattered state, large raw tool lists consuming context, and orphaned processes — by placing a small broker facade in front of upstream servers.
How does Mcp Broker reduce context usage?
It replaces many raw upstream tool definitions with four broker facade tools (broker_search_tools, broker_describe_tool, broker_call_tool, broker_status). Measured with a Codex setup: tool definitions dropped from 609 to 43 (92.94% reduction), and serialized tool tokens from 276,989 to 45,281 (83.65% reduction).
What are the compact broker facade tools?
The broker exposes four tools to clients: broker_search_tools (search upstream tools by query), broker_describe_tool (return schema and metadata), broker_call_tool (call an upstream tool), and broker_status (show profile-visible upstream state and errors).
Which platforms does Mcp Broker support?
macOS (LaunchAgent install/uninstall), Linux (systemd user‑service render, install, unload, removal), and Windows (PowerShell Scheduled Task render, install, removal). Docker image support is also available for container-friendly configs.
How do I install Mcp Broker?
Via pipx install mcp-broker, uv tool install mcp-broker, or brew install mcp-broker (tap: NavinAgrawal/tap). Docker build is also possible. Package installs do not write client config; wiring is a separate Makefile action.
常见问题
What problem does Mcp Broker solve?
It solves the problems of duplicated MCP server configurations, duplicate upstream processes across sessions, scattered state, large raw tool lists consuming context, and orphaned processes — by placing a small broker facade in front of upstream servers.
How does Mcp Broker reduce context usage?
It replaces many raw upstream tool definitions with four broker facade tools (`broker_search_tools`, `broker_describe_tool`, `broker_call_tool`, `broker_status`). Measured with a Codex setup: tool definitions dropped from 609 to 43 (92.94% reduction), and serialized tool tokens from 276,989 to 45,281 (83.65% reduction).
What are the compact broker facade tools?
The broker exposes four tools to clients: `broker_search_tools` (search upstream tools by query), `broker_describe_tool` (return schema and metadata), `broker_call_tool` (call an upstream tool), and `broker_status` (show profile-visible upstream state and errors).
Which platforms does Mcp Broker support?
macOS (LaunchAgent install/uninstall), Linux (systemd user‑service render, install, unload, removal), and Windows (PowerShell Scheduled Task render, install, removal). Docker image support is also available for container-friendly configs.
How do I install Mcp Broker?
Via `pipx install mcp-broker`, `uv tool install mcp-broker`, or `brew install mcp-broker` (tap: `NavinAgrawal/tap`). Docker build is also possible. Package installs do not write client config; wiring is a separate Makefile action.
基本信息
其他 分类下的更多 MCP 服务器
MCP Registry
modelcontextprotocolA community driven registry service for Model Context Protocol (MCP) servers.
Unity MCP ✨
justinpbarnettUnity MCP acts as a bridge between AI assistants and your Unity Editor. Give your LLM tools to manage assets, control scenes, edit scripts, and automate tasks within Unity.
MCP Go 🚀
mark3labsA Go implementation of the Model Context Protocol (MCP), enabling seamless integration between LLM applications and external data sources and tools.
Nginx UI
0xJackyYet another WebUI for Nginx
FastMCP v2 🚀
jlowin🚀 The fast, Pythonic way to build MCP servers and clients.
评论