C

Claude MCP Bridge

by hampsterx · io.github.hampsterx/claude-mcp-bridge

MCP server bridging Claude CLI to Gemini CLI, Codex, Cursor - queries, and search with hardened subprocess management

npm Local · stdio GlamaOfficial MCP Registry High confidence

Install

Add to ~/Library/Application Support/Claude/claude_desktop_config.json

Windows / Linux path
Windows: %APPDATA%\Claude\claude_desktop_config.json
Linux: ~/.config/Claude/claude_desktop_config.json
{
  "mcpServers": {
    "io-github-hampsterx-claude-mcp-bridge": {
      "command": "npx",
      "args": [
        "-y",
        "claude-mcp-bridge"
      ],
      "env": {
        "CLAUDE_CLI_PATH": "claude",
        "CLAUDE_DEFAULT_MODEL": "",
        "CLAUDE_QUERY_MODEL": "sonnet",
        "CLAUDE_STRUCTURED_MODEL": "sonnet",
        "CLAUDE_SEARCH_MODEL": "sonnet",
        "CLAUDE_FALLBACK_MODEL": "haiku",
        "CLAUDE_MAX_CONCURRENT": "3",
        "CLAUDE_BRIDGE_USE_API_KEY": "0",
        "CLAUDE_MAX_BUDGET_USD": "<VALUE>",
        "CLAUDE_QUERY_TOOLS": "Read Glob Grep",
        "CLAUDE_STRUCTURED_TOOLS": "Read Glob Grep",
        "CLAUDE_SEARCH_TOOLS": "WebSearch WebFetch",
        "CLAUDE_QUERY_EFFORT": "<VALUE>",
        "CLAUDE_SEARCH_EFFORT": "medium",
        "ANTHROPIC_API_KEY": "<VALUE>"
      }
    }
  }
}

Restart Claude Desktop to activate the new server.

Add to .cursor/mcp.json (project) or ~/.cursor/mcp.json (global)

Windows / Linux path
Windows: .cursor\mcp.json (project) or %USERPROFILE%\.cursor\mcp.json (global)
Linux: .cursor/mcp.json (project) or ~/.cursor/mcp.json (global)
{
  "mcpServers": {
    "io-github-hampsterx-claude-mcp-bridge": {
      "command": "npx",
      "args": [
        "-y",
        "claude-mcp-bridge"
      ],
      "env": {
        "CLAUDE_CLI_PATH": "claude",
        "CLAUDE_DEFAULT_MODEL": "",
        "CLAUDE_QUERY_MODEL": "sonnet",
        "CLAUDE_STRUCTURED_MODEL": "sonnet",
        "CLAUDE_SEARCH_MODEL": "sonnet",
        "CLAUDE_FALLBACK_MODEL": "haiku",
        "CLAUDE_MAX_CONCURRENT": "3",
        "CLAUDE_BRIDGE_USE_API_KEY": "0",
        "CLAUDE_MAX_BUDGET_USD": "<VALUE>",
        "CLAUDE_QUERY_TOOLS": "Read Glob Grep",
        "CLAUDE_STRUCTURED_TOOLS": "Read Glob Grep",
        "CLAUDE_SEARCH_TOOLS": "WebSearch WebFetch",
        "CLAUDE_QUERY_EFFORT": "<VALUE>",
        "CLAUDE_SEARCH_EFFORT": "medium",
        "ANTHROPIC_API_KEY": "<VALUE>"
      }
    }
  }
}

Cursor usually picks up config changes automatically; if the server does not appear, reload the window.

Add to .mcp.json (project) or ~/.claude.json (global)

Windows / Linux path
Windows: .mcp.json (project) or %USERPROFILE%\.claude.json (global)
Linux: .mcp.json (project) or ~/.claude.json (global)
{
  "mcpServers": {
    "io-github-hampsterx-claude-mcp-bridge": {
      "command": "npx",
      "args": [
        "-y",
        "claude-mcp-bridge"
      ],
      "env": {
        "CLAUDE_CLI_PATH": "claude",
        "CLAUDE_DEFAULT_MODEL": "",
        "CLAUDE_QUERY_MODEL": "sonnet",
        "CLAUDE_STRUCTURED_MODEL": "sonnet",
        "CLAUDE_SEARCH_MODEL": "sonnet",
        "CLAUDE_FALLBACK_MODEL": "haiku",
        "CLAUDE_MAX_CONCURRENT": "3",
        "CLAUDE_BRIDGE_USE_API_KEY": "0",
        "CLAUDE_MAX_BUDGET_USD": "<VALUE>",
        "CLAUDE_QUERY_TOOLS": "Read Glob Grep",
        "CLAUDE_STRUCTURED_TOOLS": "Read Glob Grep",
        "CLAUDE_SEARCH_TOOLS": "WebSearch WebFetch",
        "CLAUDE_QUERY_EFFORT": "<VALUE>",
        "CLAUDE_SEARCH_EFFORT": "medium",
        "ANTHROPIC_API_KEY": "<VALUE>"
      }
    }
  }
}

The server will be available in the next Claude Code session.

Add to .vscode/mcp.json

Windows / Linux path
Windows: .vscode\mcp.json
Linux: .vscode/mcp.json
{
  "servers": {
    "io-github-hampsterx-claude-mcp-bridge": {
      "command": "npx",
      "args": [
        "-y",
        "claude-mcp-bridge"
      ],
      "env": {
        "CLAUDE_CLI_PATH": "claude",
        "CLAUDE_DEFAULT_MODEL": "",
        "CLAUDE_QUERY_MODEL": "sonnet",
        "CLAUDE_STRUCTURED_MODEL": "sonnet",
        "CLAUDE_SEARCH_MODEL": "sonnet",
        "CLAUDE_FALLBACK_MODEL": "haiku",
        "CLAUDE_MAX_CONCURRENT": "3",
        "CLAUDE_BRIDGE_USE_API_KEY": "0",
        "CLAUDE_MAX_BUDGET_USD": "<VALUE>",
        "CLAUDE_QUERY_TOOLS": "Read Glob Grep",
        "CLAUDE_STRUCTURED_TOOLS": "Read Glob Grep",
        "CLAUDE_SEARCH_TOOLS": "WebSearch WebFetch",
        "CLAUDE_QUERY_EFFORT": "<VALUE>",
        "CLAUDE_SEARCH_EFFORT": "medium",
        "ANTHROPIC_API_KEY": "<VALUE>"
      }
    }
  }
}

Reload the VS Code window to activate.

Add to ~/.codeium/windsurf/mcp_config.json

Windows / Linux path
Windows: %USERPROFILE%\.codeium\windsurf\mcp_config.json
Linux: ~/.codeium/windsurf/mcp_config.json
{
  "mcpServers": {
    "io-github-hampsterx-claude-mcp-bridge": {
      "command": "npx",
      "args": [
        "-y",
        "claude-mcp-bridge"
      ],
      "env": {
        "CLAUDE_CLI_PATH": "claude",
        "CLAUDE_DEFAULT_MODEL": "",
        "CLAUDE_QUERY_MODEL": "sonnet",
        "CLAUDE_STRUCTURED_MODEL": "sonnet",
        "CLAUDE_SEARCH_MODEL": "sonnet",
        "CLAUDE_FALLBACK_MODEL": "haiku",
        "CLAUDE_MAX_CONCURRENT": "3",
        "CLAUDE_BRIDGE_USE_API_KEY": "0",
        "CLAUDE_MAX_BUDGET_USD": "<VALUE>",
        "CLAUDE_QUERY_TOOLS": "Read Glob Grep",
        "CLAUDE_STRUCTURED_TOOLS": "Read Glob Grep",
        "CLAUDE_SEARCH_TOOLS": "WebSearch WebFetch",
        "CLAUDE_QUERY_EFFORT": "<VALUE>",
        "CLAUDE_SEARCH_EFFORT": "medium",
        "ANTHROPIC_API_KEY": "<VALUE>"
      }
    }
  }
}

Restart Windsurf (or refresh its MCP servers panel) to activate the new server.

Windsurf Next uses ~/.codeium/windsurf-next/mcp_config.json. Devin Desktop (the Windsurf rebrand) uses ~/.config/devin/mcp_config.json and imports the Windsurf file.

Add to ~/Library/Application Support/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json

Windows / Linux path
Windows: %APPDATA%\Code\User\globalStorage\saoudrizwan.claude-dev\settings\cline_mcp_settings.json
Linux: ~/.config/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json
{
  "mcpServers": {
    "io-github-hampsterx-claude-mcp-bridge": {
      "command": "npx",
      "args": [
        "-y",
        "claude-mcp-bridge"
      ],
      "env": {
        "CLAUDE_CLI_PATH": "claude",
        "CLAUDE_DEFAULT_MODEL": "",
        "CLAUDE_QUERY_MODEL": "sonnet",
        "CLAUDE_STRUCTURED_MODEL": "sonnet",
        "CLAUDE_SEARCH_MODEL": "sonnet",
        "CLAUDE_FALLBACK_MODEL": "haiku",
        "CLAUDE_MAX_CONCURRENT": "3",
        "CLAUDE_BRIDGE_USE_API_KEY": "0",
        "CLAUDE_MAX_BUDGET_USD": "<VALUE>",
        "CLAUDE_QUERY_TOOLS": "Read Glob Grep",
        "CLAUDE_STRUCTURED_TOOLS": "Read Glob Grep",
        "CLAUDE_SEARCH_TOOLS": "WebSearch WebFetch",
        "CLAUDE_QUERY_EFFORT": "<VALUE>",
        "CLAUDE_SEARCH_EFFORT": "medium",
        "ANTHROPIC_API_KEY": "<VALUE>"
      }
    }
  }
}

Cline reloads cline_mcp_settings.json automatically; if the server does not appear, reload the VS Code window.

Open it from Cline's MCP Servers panel → Configure. Roo Code uses a different file and format.

Configuration

Environment variables this server reads. Secrets stay on your machine.

NameRequiredDescription
CLAUDE_CLI_PATH No Path to CLI binary. Default: claude
CLAUDE_DEFAULT_MODEL No Shared default model for all tools. If not set, each tool uses its own default.
CLAUDE_QUERY_MODEL No Default model for query tool. Default: sonnet
CLAUDE_STRUCTURED_MODEL No Default model for structured tool. Default: sonnet
CLAUDE_SEARCH_MODEL No Default model for search tool. Default: sonnet
CLAUDE_FALLBACK_MODEL No Fallback model on quota exhaustion. Set to 'none' to disable. Default: haiku
CLAUDE_MAX_CONCURRENT No Max concurrent subprocess spawns. Default: 3
CLAUDE_BRIDGE_USE_API_KEY No Set to '1' to forward ANTHROPIC_API_KEY to the subprocess. Default uses subscription auth. Default: 0
CLAUDE_MAX_BUDGET_USD No Global cost cap in USD per call.
CLAUDE_QUERY_TOOLS No Built-in tools the query subprocess may use. Comma or space separated list, 'default' for the CLI's full built-in set, or empty for no tools. The default withholds Bash, Write and Edit; widening it grants real capability in the caller-supplied working directory. Default: Read Glob Grep
CLAUDE_STRUCTURED_TOOLS No Built-in tools the structured subprocess may use. Same format and caveats as CLAUDE_QUERY_TOOLS. Default: Read Glob Grep
CLAUDE_SEARCH_TOOLS No Built-in tools the search subprocess may use. Same format and caveats as CLAUDE_QUERY_TOOLS. Default: WebSearch WebFetch
CLAUDE_QUERY_EFFORT No Default effort for query tool.
CLAUDE_SEARCH_EFFORT No Default effort for search tool. Default: medium
ANTHROPIC_API_KEY No Anthropic API key. Required when using API key authentication (set CLAUDE_BRIDGE_USE_API_KEY=1).

Similar servers