Claude Code
claude mcp add --transport http context7 https://mcp.context7.com/mcp
claude mcp add --transport stdio context7 -- npx -y @upstash/context7-mcp
# share with the team: writes .mcp.json at the repo root
claude mcp add --transport http context7 --scope project https://mcp.context7.com/mcp{
"mcpServers": {
"context7": { "type": "http", "url": "https://mcp.context7.com/mcp" }
}
}Commands write to local scope unless you pass --scope project or --scope user. In JSON, streamable-http is accepted as an alias for http.
Codex CLI
codex mcp add context7 -- npx -y @upstash/context7-mcp
codex mcp list[mcp_servers.context7]
command = "npx"
args = ["-y", "@upstash/context7-mcp"]
# a remote server uses url instead
# [mcp_servers.docs]
# url = "https://mcp.example.com/mcp"Inside the TUI, /mcp lists active servers; codex mcp login <name> handles OAuth.
OpenCode
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"context7": { "type": "remote", "url": "https://mcp.context7.com/mcp", "enabled": true }
}
}opencode mcp add context7 --url https://mcp.context7.com/mcp
opencode mcp listgoose
extensions:
context7:
name: Context7
type: stdio
cmd: npx
args: [-y, "@upstash/context7-mcp"]
enabled: true
timeout: 300Or run goose configure → Add Extension. Remote servers use type: streamable_http with a uri. The YAML above follows the shape of goose's documented GitHub example.
Gemini CLI
{
"mcpServers": {
"context7": { "httpUrl": "https://mcp.context7.com/mcp" }
}
}Use command + args for stdio, httpUrl for streamable HTTP, or url for SSE. Requests time out after 10 minutes by default (timeout, in milliseconds).
Aider
We found no MCP setup in Aider's docs on Oct 18, 2026. If a job needs MCP tools, pair Aider with one of the harnesses above.
Cheat sheet
| Harness | Config file | Key | CLI |
|---|---|---|---|
| Claude Code | .mcp.json / ~/.claude.json | mcpServers | claude mcp add |
| Codex CLI | config.toml | [mcp_servers.<name>] | codex mcp add |
| OpenCode 1 | opencode.json | mcp.<name> | opencode mcp add |
| OpenCode 2 | opencode.json(c) | mcp.servers.<name> | opencode mcp add |
| goose | ~/.config/goose/config.yaml | extensions | goose configure |
| Gemini CLI | settings.json | mcpServers | — |
FAQ
Can I share one MCP config across harnesses?
Not directly. Each tool uses its own file and key names (mcpServers, mcp_servers, mcp, extensions). Keep a short list of servers in your README and add each one per harness.
Where do project-level MCP servers go in Claude Code?
In .mcp.json at the repo root, created with --scope project. Claude Code asks for approval in interactive sessions before using them, but in claude -p runs it loads them without asking. Use --strict-mcp-config with --mcp-config to control exactly which servers a headless run gets.
Does Aider support MCP?
Not in the docs we checked on Oct 18, 2026.
Get new rigs by email
New job recipes and harness changes, a few times a month. Each one with copy-ready config and dated sources.
Sources
- Claude Code docs: MCP · checked Oct 18, 2026
- Codex docs: MCP · checked Oct 18, 2026
- OpenCode 1 docs: MCP servers · checked Oct 18, 2026
- OpenCode 2 docs: MCP servers · checked Oct 18, 2026
- OpenCode 1 docs: CLI · checked Oct 18, 2026
- goose docs: extensions (MCP) · checked Oct 18, 2026
- Gemini CLI docs: MCP servers · checked Oct 18, 2026
Spotted something out of date? Email sternberg@mail.grokbot.com.