linear-mcp
linear-mcp
Multi-workspace Linear MCP server with Personal API Key auth. Drop-in replacement for the official OAuth-only Linear MCP at mcp.linear.app/mcp.
Why this exists. The official Linear MCP is OAuth-only and single-workspace per instance. PAT auth plus persistent token storage plus multi-workspace routing kills three failure modes:
The OAuth flow is brittle across MCP client session boundaries — auth state expires when a session resumes mid-flow.
The localhost callback fails in some setups, forcing fragile paste-back flows.
One MCP instance per workspace doubles config + OAuth dances.
This server replaces both with one entry. One install, N workspaces, never an OAuth dance again.
Install
From PyPI
pipx install adelaidasofia-linear-mcpFrom source
git clone https://github.com/adelaidasofia/linear-mcp ~/.claude/linear-mcp
cd ~/.claude/linear-mcp
pip install -e .Claude Desktop one-click
Download the latest .mcpb from Releases and double-click.
Configure
Generate one Personal API Key per workspace at https://linear.app/settings/account/security. You must be logged into each workspace separately while generating the key for that workspace.
Create
~/.claude/linear-mcp/admin.env(chmod 600):
LINEAR_WORKSPACES=personal,work
LINEAR_PRIMARY_WORKSPACE=personal
LINEAR_PAT_PERSONAL=lin_api_xxxxxxxxxxxxxxxxxxxxxxxxxxxx
LINEAR_PAT_WORK=lin_api_xxxxxxxxxxxxxxxxxxxxxxxxxxxx
LINEAR_LABEL_PERSONAL=Personal
LINEAR_LABEL_WORK=WorkAliases are arbitrary — name them whatever helps you route (acme,beta, team1,team2, home,client).
chmod 600 ~/.claude/linear-mcp/admin.envRegister in Claude Code (user scope, so it loads in every project):
claude mcp add -s user linear-mcp python3 -m linear_mcp.serverOr, with pipx install:
claude mcp add -s user linear-mcp linear-mcpRestart Claude Code.
healthcheckshould returnok: trueper workspace.
Substrate-layer enforcement (v0.3)
Three server-side checks that protect issue quality without depending on any markdown rule file or client-side memory. Apply only to WRITE paths; reads stay unconstrained.
Layer | What it does | Bypass env var |
|
|
|
Idempotency check | Before any CREATE, the server runs |
|
|
| (no bypass — surface the phrase to the operator) |
Canonical-key examples:
[source: 🍄 Mycelium AI/📝 Meeting Notes/2026-05-22 - sync.md][source: ⚙️ Meta/Decisions/2026-05-23-merger-public-comms.md][source: linear-kickoff:sweep-myc-p1][source: ~/.claude/linear-mcp/BUILD_PROMPT_V03.md]
Fast issue execution
linear-exec is the short path for starting real work from a Linear issue.
It resolves the issue, checks blocking relations, scans same-project siblings
for obvious scope overlap, infers the repo when possible, and can create the
standard claude-dev-worktree branch.
Dry-run a specific issue:
linear-exec execute MYC-150 --workspace myceliumStart the work after reviewing the preflight:
linear-exec execute MYC-150 --workspace mycelium --repo memory-runtime-pro --goFind the next unblocked P1 issue in a workspace:
linear-exec sweep mycelium p1
linear-exec sweep mycelium p1 --go --repo memory-runtime-proThe command refuses to proceed when an upstream blocks relation is still
incomplete unless --force is passed. --no-state-update and --no-worktree
let agents use only the parts of the preflight they need.
Tool surface (v0.3 — 57 tools + 3 prompts)
Every tool takes an optional workspace parameter (the alias from LINEAR_WORKSPACES). Omit it to use LINEAR_PRIMARY_WORKSPACE.
Meta
Tool | Purpose |
| Show configured workspaces and primary |
| Verify each PAT + surface remaining rate-limit budget |
Core entities
Tool | Purpose |
| Teams (with inline workflow states) |
| Users ( |
| Projects (v0.3: |
| Initiatives |
| Issues (id or |
| Cycles |
| Project milestones |
| Workflow states |
| Labels |
| Comments |
| Documents |
| Post a project status update |
Webhooks (v0.2)
Tool | Purpose |
| Inspect subscriptions |
| Manage subscriptions |
| Destructive — draft+confirm |
Notifications / inbox (v0.2)
Tool | Purpose |
| Inbox read |
| Top-of-mind counter |
| Triage |
| Sweep |
Attachments (v0.2)
Tool | Purpose |
| Per-issue reads |
| Reverse lookup: which issues link to this URL? |
| Attach any URL to an issue |
| Destructive — draft+confirm |
Issue relations (v0.2)
Tool | Purpose |
| The blocks/duplicate/related graph |
| Manage the graph |
Agent sessions (v0.2)
Tool | Purpose |
| Linear's first-class agent surface |
| Spawn |
Search (v0.2 — replaces v0.1's broken search_documentation)
Tool | Purpose |
| Full-text per entity type |
| Workspace-wide semantic across all entities |
MCP prompts (v0.2)
Available as slash commands in MCP clients that surface prompts:
/triage-issue— full triage pass: classify, label, prioritize, assign, link duplicates/project-status— draft a weekly status update from current Linear state/inbox-sweep— sweep today's notifications, propose actions, archive what's handled
Multi-workspace usage
Switch workspaces inline:
list_teams(workspace="work")
save_issue(workspace="personal", title="Ship", team_id="...")Without workspace, the primary is used.
Auth
Linear PATs use header Authorization: <key> (no Bearer prefix). Each PAT is scoped to one workspace and grants access only to data the owning user can see. There is no shared org token.
Rate limit: 2500 requests/hour per token (verified against live API 2026-05-23). The server passes Linear's Retry-After header through on 429 and surfaces remaining budget via healthcheck.
Safety
Read tools and routine writes (create/update issues, comments, labels, status updates) pass through. Destructive ops (delete_webhook, delete_attachment) use the draft+confirm pattern: the first call stages the change and returns a draft_id + preview of what will happen; the second call (with confirm_draft_id) commits. Drafts expire after 1 hour (override with LINEAR_MCP_DRAFT_TTL_SECONDS).
Every tool call appends one JSONL line to ~/.claude/linear-mcp/audit.log (override with LINEAR_MCP_AUDIT_LOG_PATH, disable with LINEAR_MCP_AUDIT_LOG=false). Tokens are stripped from audit records.
healthcheck surfaces each PAT's remaining rate-limit budget (X-RateLimit-Requests-Remaining + X-Complexity-Remaining) per workspace, so agents can self-throttle without making a separate observability call.
Related MCPs
adelaidasofia/slack-mcp — multi-workspace Slack with draft+confirm
adelaidasofia/whatsapp-mcp — WhatsApp via whatsmeow + vault export
adelaidasofia/imessage-mcp — iMessage chat.db + vault export
adelaidasofia/github-mcp — GitHub PR/issue/release
License
MIT.
Built by Adelaida Diaz-Roa. Full install or team version at diazroa.com.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/adelaidasofia/linear-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server