Linear MCP for OpenCode: per-workspace integration
Workspace-scoped Linear MCP setup
To add Linear MCP to OpenCode for one repository, create a workspace opencode.jsonc, run opencode mcp auth linear-project, then confirm the server appears in opencode mcp list.
The MCP config lives in the repository, so it affects only that directory.
Repeat the same opencode.jsonc pattern in any repository that needs Linear tools.
1. Create a workspace config file
From your workspace root, create opencode.jsonc with a workspace-local MCP block:
{
"$schema": "https://opencode.ai/config.json",
"mcp": {
"linear-project": {
"type": "remote",
"url": "https://mcp.linear.app/mcp",
"enabled": true
}
}
}We use "linear-project" instead of "linear" to avoid naming collisions with other tools or global configs, but you can choose any key and keep the same URL.
2. Authenticate the server
Open a terminal at that workspace and run:
opencode mcp auth linear-projectIf the command is not available in your OpenCode version, open the OpenCode app settings and start auth from the MCP section.
3. Confirm it is active in that workspace
opencode mcp listRun one read-only Linear query through the agent.
Show me the first five open issues assigned to me in Linear.If the command returns fresh workspace data, your setup is working.
4. If opencode mcp auth is missing
Some OpenCode builds expose MCP auth in the app UI instead of the CLI. If opencode mcp auth linear-project is unavailable, open OpenCode settings, find the MCP section, select the same Linear server entry, and complete auth there.
After that, run:
opencode mcp listIf linear-project appears in the workspace output, the setup is still valid.
5. How to confirm it is workspace-only
The workspace file above is local to the repo path. Your other directories keep their own MCP state, so Linear MCP can be enabled per repository.
Run opencode mcp list inside this repository and in another directory without the same opencode.jsonc. The Linear entry should appear only in the configured workspace.
Related links
Frequently asked questions
- How do I add Linear MCP to OpenCode?
- Define a workspace-level `opencode.jsonc` with a remote Linear MCP entry and run `opencode mcp auth linear-project` to complete auth.
- Is there an OpenCode Linear integration?
- Yes. Linear ships a remote MCP server. Point OpenCode at `https://mcp.linear.app/mcp` in a workspace `opencode.jsonc`, authenticate, then confirm with `opencode mcp list`.
- What is Linear MCP for OpenCode used for?
- It lets the OpenCode agent read and act on Linear issues from that workspace (list issues, check assignees, and similar MCP tools) without wiring Linear into every project.
- Can I keep Linear MCP scoped to one workspace in OpenCode?
- Yes. Add the MCP configuration in the workspace `opencode.jsonc` file so that workspace gets the tools without changing your global profile.
- What if `opencode mcp auth` is not available?
- Open the OpenCode app settings, go to the MCP section, and start auth for the same Linear server entry there.