On-demand tool discovery for all your MCPs and per-subagent MCP controls to preserve context window.
uvx agent-mcp-gateway{
"GATEWAY_MCP_CONFIG": "YOUR_VALUE_HERE",
"GATEWAY_RULES": "YOUR_VALUE_HERE",
"GATEWAY_DEFAULT_AGENT": "YOUR_VALUE_HERE",
"GATEWAY_DEBUG": "YOUR_VALUE_HERE"
}Add this server entry to the mcpServers object in your Claude Desktop config, then restart the app.
{
"mcpServers": {
"io-github-roddutra-agent-mcp-gateway": {
"command": "uvx",
"args": [
"agent-mcp-gateway"
],
"env": {
"GATEWAY_MCP_CONFIG": "YOUR_VALUE_HERE",
"GATEWAY_RULES": "YOUR_VALUE_HERE",
"GATEWAY_DEFAULT_AGENT": "YOUR_VALUE_HERE",
"GATEWAY_DEBUG": "YOUR_VALUE_HERE"
}
}
}
}~/Library/Application Support/Claude/claude_desktop_config.json%APPDATA%\Claude\claude_desktop_config.jsonNo remote HTTP endpoint is advertised. Use the package or stdio setup shown in Install.
Agent MCP Gateway is an MCP server for On-demand tool discovery for all your MCPs and per-subagent MCP controls to preserve context window.. It supports STDIO transport.
Use the generated config in Install. This server runs with uvx agent-mcp-gateway; add any required environment variables before starting your client.
Choose the Claude Desktop tab in Install and copy the config for uvx agent-mcp-gateway. Add required environment variables before starting Claude Desktop.
Choose the Claude Code tab in Install and copy the config for uvx agent-mcp-gateway. Add required environment variables before starting Claude Code.
Choose the Codex tab in Install and copy the config for uvx agent-mcp-gateway. Add required environment variables before starting Codex.
Choose the Cursor or VS Code tab in Install and copy the config for uvx agent-mcp-gateway. Add required environment variables before starting Cursor or VS Code.
Agent MCP Gateway uses STDIO transport. Use the package or command config in Install.
Agent MCP Gateway inventory is listed when the MCP endpoint exposes tools, resources, or prompts. Some servers require auth first.
Agent MCP Gateway does not advertise a verified auth requirement. If discovery fails, it may still need provider login, an API key, a bearer token, or a session header.
| Package | Registry | Version | Inputs |
|---|---|---|---|
agent-mcp-gatewaystdio | pypi | 0.2.5 | Env: GATEWAY_MCP_CONFIG Env: GATEWAY_RULES Env: GATEWAY_DEFAULT_AGENT Env: GATEWAY_DEBUG |