Best for
- Developers who want to use OpenCode's headless API from an MCP client.
- Users who need to delegate coding work in a project and observe its progress.
This developer tool server connects MCP clients to the OpenCode headless API. The README provides an npx client configuration example, instructions for starting the OpenCode server, and task workflows. The server manifest was not cached, so the listed tool identifiers come from README workflows and do not represent the complete tool inventory.
Strongest · Setup experience 13/20 Weakest · Reliability 9/20
Static review · not runReviewed 2026-11-29
Read the FMRS scoring method →Runtime:Node.js 22+
OPENCODE_SERVER_PASSWORD
HTTP authentication password for the OpenCode server, if enabled.
OPENCODE_SERVER_TOKEN
Optional bearer token for the OpenCode server, such as an OpenChamber client token.
OPENCODE_OPENCHAMBER_PASSWORD
Password used to sign in to an OpenChamber-fronted server.
OPENCODE_BASE_URL
OpenCode server endpoint; defaults to http://127.0.0.1:4096.
OPENCODE_SERVER_USERNAME
HTTP authentication username for the OpenCode server, if enabled.
OPENCODE_OPENCHAMBER_URL
URL of the OpenChamber-fronted server.
OPENCODE_OPENCHAMBER_CLIENT_ID
Overrides the per-process OpenChamber client identifier.
OPENCODE_AUTO_SERVE
Set to true to opt in to launching a local server.
OPENCODE_DEFAULT_PROVIDER
Default provider for prompts; set together with OPENCODE_DEFAULT_MODEL.
OPENCODE_DEFAULT_MODEL
Default model for prompts; set together with OPENCODE_DEFAULT_PROVIDER.
OPENCODE_TOOL_PROFILE
Tool profile: full (default) or essential.
OPENCODE_TASK_STORE
Overrides the local directory used for persisted job records.
Install OpenCode and start its server from your project, for example with opencode serve --hostname 127.0.0.1 --port 4096. Configure the MCP client to run npx with arguments -y and opencode-mcp; Claude Code can use claude mcp add opencode -- npx -y opencode-mcp. Restart the client and call opencode_setup, choose a provider, then select a model with opencode_provider_models.
{"mcpServers":{"opencode":{"command":"npx","args":["-y","opencode-mcp"]}}}
Shown for Claude Code. Other clients may use a different file or key (VS Code uses "servers") — the configurator below converts it.
{
"servers": {
"opencode": {
"command": "npx",
"args": [
"-y",
"opencode-mcp"
]
}
}
}
Goes in your project's .vscode/mcp.json (VS Code uses a "servers" key).
[mcp_servers.opencode] command = "npx" args = ["-y", "opencode-mcp"]
Append to ~/.codex/config.toml (OpenAI Codex CLI uses TOML).
claude mcp add opencode -- npx -y opencode-mcp
Run it in a terminal; replace any <…> placeholders with your own values first.
Restart the MCP client, confirm opencode_setup appears in its tool list, and call it to verify the connection to the OpenCode server.
Once connected, you can ask your AI assistant things like:
No matching tools
Listed from the project's documentation, not tested by this site.
OpenCode MCP Server connects MCP clients such as Claude, Cursor, and VS Code to OpenCode's headless API. It supports asking questions, implementing features, monitoring background work, responding to questions and permission requests, and reviewing project changes. Version 3.x requires Node.js 22 or newer and works with OpenCode 1.x. The README describes 70 tools, 10 resources, and 5 prompts; the tool profile can be full or the smaller essential set.
Connect code, docs, and infrastructure in a local knowledge graph.
Docker's official MCP gateway CLI plugin for managing and running MCP servers.
Fast, low-cost structured judgments for agents.
Local call graphs and structural analysis for Go repositories.
Source revision 609560d4e08b Data synced 2026-12-05 Read the FMRS scoring method Markdown