servers / opencode-mcp

opencode-mcp

communitystdiolocaldestructive capablehealthy

MCP server for OpenCode AI — 70 tools, 10 resources, 5 prompts. Use npx opencode-mcp with Claude Desktop, Claude Code, Cursor, Windsurf, or any MCP client.


01Tools · 80

How to read this: tool names here are observed from a live tools/list handshake. The Risk label is a heuristic inferred from the tool name (write/destructive verbs), not from executing the tool — a conservative guess, not a verified capability. We never escalate risk from a description. Found one that's wrong? Tell us — we fix on report.

ToolRiskSide effectsApproval
opencode_config_update
Update the opencode configuration. Pass a partial config object with fields to update.
writetrueunknown
opencode_project_current
Get the current active project
readfalseunknown
opencode_session_delete
Delete a session and all its data
destructivetruetrue
opencode_health
Check server health and version
readfalseunknown
opencode_project_list
List all projects known to the opencode server
readfalseunknown
opencode_session_create
Create a new session. Optionally provide a parentID to create a child session, and a title.
writetrueunknown
opencode_config_providers
List all configured providers and their default models
readfalseunknown
opencode_session_list
List all sessions
readfalseunknown
opencode_session_update
Update session properties (e.g. title)
writetrueunknown
opencode_config_get
Get the current opencode configuration
readfalseunknown
opencode_project_init
Initialize or open a project directory to host an independent OpenCode session. Use this to create new empty folders, or to explicitly open preexisting projects on the host machine for parallel code generation workloads.
writetrueunknown
opencode_session_get
Get details of a specific session by ID
readfalseunknown
opencode_session_status
Get status for all sessions (running, idle, etc.)
readfalseunknown
opencode_session_children
Get child sessions of a session
readfalseunknown
opencode_session_abort
Abort a running session
unknownunknownunknown
opencode_session_diff
Get the diff for a session, optionally for a specific message
readfalseunknown
opencode_session_todo
Get the todo list for a session
readfalseunknown
opencode_session_share
Share a session publicly
unknownunknownunknown
opencode_session_init
Analyze the app and create AGENTS.md for a session. NOTE: This is a long-running operation that may take 30-60+ seconds depending on project size.
writetrueunknown
opencode_session_unshare
Unshare a previously shared session
unknownunknownunknown
opencode_session_unrevert
Restore all reverted messages in a session
unknownunknownunknown
opencode_message_list
List all messages in a session with formatted output showing roles and content
readfalseunknown
opencode_session_fork
Fork an existing session, optionally at a specific message
unknownunknownunknown
opencode_session_summarize
Summarize a session using a specified model. NOTE: This is a long-running operation that may take 30-60+ seconds.
unknownunknownunknown
opencode_session_permission
Respond to a permission request in a session. Use `opencode_permission_list` to see pending requests. Reply values: 'once' (approve this request only), 'always' (approve this + future matching requests for this session), 'reject' (deny the request).
writetrueunknown
opencode_session_revert
Revert a message in a session
unknownunknownunknown
opencode_session_search
Search sessions by keyword in title. Useful for finding a specific session among many.
readfalseunknown
opencode_message_send_async
Send a prompt message asynchronously (fire-and-forget, does not wait for response). Use opencode_wait to poll for completion.
writetrueunknown
opencode_find_file
Find files and directories by name (fuzzy match)
readfalseunknown
opencode_file_status
Get status for tracked files (VCS changes: modified, added, deleted, etc.)
readfalseunknown
opencode_permission_list
List all pending permission requests across all sessions. When a session is blocked waiting for approval (e.g. to run a shell command or access a file outside the project), it appears here. Respond with `opencode_session_permission`.
writetrueunknown
opencode_message_get
Get details of a specific message in a session
readfalseunknown
opencode_message_send
Send a prompt message to a session and wait for the AI response. Use parts to send text, and optionally specify a model.
writetrueunknown
opencode_command_execute
Execute a slash command in a session (e.g. /init, /undo, /redo)
writetrueunknown
opencode_shell_execute
Run a shell command through the opencode session
writetrueunknown
opencode_find_text
Search for text patterns in project files (regex supported). Returns file paths, line numbers, and matching lines.
readfalseunknown
opencode_file_read
Read the content of a file
readfalseunknown
opencode_find_symbol
Find workspace symbols by name (functions, classes, variables, etc.)
readfalseunknown
opencode_provider_list
List all configured providers with their connection status. Returns a compact summary — use opencode_provider_models to see models for a specific provider.
readfalseunknown
opencode_provider_oauth_callback
Handle OAuth callback for a provider
unknownunknownunknown
opencode_file_list
List files and directories at a path
readfalseunknown
opencode_provider_models
List available models for a specific provider. Call opencode_provider_list first to see provider IDs.
readfalseunknown
opencode_auth_set
Set authentication credentials for a provider (e.g. API key). Credentials are stored globally and shared across all projects.
writetrueunknown
opencode_agent_list
List all available agents with their names, descriptions, and modes (primary/subagent)
readfalseunknown
opencode_provider_auth_methods
Get available authentication methods for all providers
readfalseunknown
opencode_path_get
Get the current working path of the opencode server
readfalseunknown
opencode_provider_oauth_authorize
Start OAuth authorization for a provider
unknownunknownunknown
opencode_vcs_info
Get VCS (version control) info for the current project (branch, remote, status)
readfalseunknown
opencode_lsp_status
Get the status of LSP (Language Server Protocol) servers
readfalseunknown
opencode_tool_ids
List all available tool IDs that the LLM can use (experimental)
readfalseunknown
opencode_ask
Ask OpenCode a question in one step. Creates a new session, sends your prompt, and returns the AI response. This is the easiest way to interact with OpenCode.
unknownunknownunknown
opencode_instance_dispose
Dispose the current opencode instance (shuts it down). WARNING: This is destructive and will terminate the server.
destructivetruetrue
opencode_formatter_status
Get the status of configured formatters
readfalseunknown
opencode_tool_list
List tools with JSON schemas for a given provider and model (experimental)
readfalseunknown
opencode_reply
Send a follow-up message to an existing session. Use this to continue a conversation started with opencode_ask or opencode_session_create.
writetrueunknown
opencode_command_list
List all available commands (built-in and custom slash commands)
readfalseunknown
opencode_mcp_add
Add an MCP server dynamically to opencode
writetrueunknown
opencode_setup
Check OpenCode status, provider configuration, and optionally initialize a project directory. Use this as the first step when starting work — it tells you what is ready and what still needs configuration.
readfalseunknown
opencode_sessions_overview
Get a quick overview of all sessions with their titles and status. Useful to find which session to continue working in.
readfalseunknown
opencode_mcp_status
Get the status of all MCP servers configured in opencode
readfalseunknown
opencode_log
Write a log entry to the opencode server
writetrueunknown
opencode_conversation
Get the full conversation history of a session, formatted for easy reading. Shows all messages with their roles and content.
readfalseunknown
opencode_context
Get full project context in one call: current project, path, VCS info, config, and available agents. Useful to understand the current state before starting work.
readfalseunknown
opencode_run
Send a task to OpenCode and wait for completion. Combines session creation, async prompt, and polling into a single tool call. Use this instead of the manual opencode_message_send_async + opencode_wait pattern.
writetrueunknown
opencode_wait
Poll a session until it finishes processing. Use after opencode_message_send_async to wait for the AI to complete its response. Sends progress notifications while waiting. If timeout is reached, returns a progress report (not an error). For long tasks, consider using opencode_session_todo to check progress instead of blocking.
unknownunknownunknown
opencode_review_changes
Get a formatted summary of all file changes made in a session. Shows diffs in a readable format.
readfalseunknown
opencode_check
Get a compact cached progress report for a session. Much cheaper than opencode_conversation or opencode_wait — returns status, todos, and file counts in a single call. Use this to monitor sessions launched with opencode_fire.
readfalseunknown
opencode_tui_clear_prompt
Clear the current prompt text in the TUI
unknownunknownunknown
opencode_tui_open_sessions
Open the session selector in the TUI
unknownunknownunknown
opencode_provider_test
Quick-test whether a provider is working. Creates a temporary session, sends a trivial prompt, checks the response, and cleans up. Great for debugging auth issues.
unknownunknownunknown
opencode_status
Get a quick status dashboard: server health, provider count, session count, and VCS info. Lighter than opencode_setup — good for at-a-glance checks.
readfalseunknown
opencode_fire
Fire-and-forget: send a task to OpenCode and return immediately. OpenCode works autonomously in the background. Use `opencode_check` to check progress anytime. Best for long-running tasks when you want to do other work in parallel.
writetrueunknown
opencode_tui_submit_prompt
Submit the current prompt in the TUI (equivalent to pressing Enter)
unknownunknownunknown
opencode_tui_append_prompt
Append text to the TUI's prompt input field
unknownunknownunknown
opencode_tui_execute_command
Execute a slash command through the TUI (e.g. '/init', '/undo')
writetrueunknown
opencode_tui_open_models
Open the model selector in the TUI
unknownunknownunknown
opencode_tui_show_toast
Show a toast notification in the TUI
readfalseunknown
opencode_tui_open_help
Open the help dialog in the TUI
unknownunknownunknown
opencode_events_poll
Poll for recent events from the OpenCode server. Collects events for the specified duration and returns them. Useful for monitoring session activity, deployments, and system changes.
unknownunknownunknown
opencode_tui_open_themes
Open the theme selector in the TUI
unknownunknownunknown

02Install & source
npx -y opencode-mcp
npx

03Access granted
Execute code · write

The access this server can exercise, inferred from its verified tools — not a declared OAuth scope.


05Provenance & freshness
sourcesGitHub repo search [p4]
last_checked2026-07-09 08:37Z
next_check2026-07-11 07:58Z
cadenceevery 48h
verifiedtools_list:passed handshake:passed metadata:passed
index_statusindex9 unique facts >= 5

06Badge

Add the “as seen on MCPExplorer” badge to your README. opencode-mcp MCP — as seen on mcpexplorer.com

[![opencode-mcp MCP — as seen on mcpexplorer.com](https://mcpexplorer.com/badge/opencode-mcp.svg)](https://mcpexplorer.com/servers/opencode-mcp)

Next step

This is one server. A loadout combines the right servers, governance, and proven plays for a whole job — assembled deliberately, not tool-dumped.

Explore loadouts →