MCP Linear.app Server
An MCP server that enables interaction with Linear.app's API for issue tracking, project management, and workflow automation. It allows users to create, update, and search issues, manage cycles and labels, and perform team operations through natural language.
README
MCP Linear.app Server
A Model Context Protocol (MCP) server that enables MCP clients to interact with Linear.app's API for issue tracking, project management, and workflow automation.
Features
- Issue Management: Create, update, list, search, and get detailed issue information
- Project Management: Create, update, list, archive, and get detailed project information with full team and member management
- Custom Views: Create, update, list, and delete custom filtered views for organizing issues
- Team & Workflow Operations: List teams and access workflow states
- Cycle Management: Create and manage sprints/cycles
- Label Management: Create and organize labels
- User Operations: List users and assign issues
- Advanced Filtering: Filter issues by status, assignee, project, labels, and more
- Type-Safe: Built with TypeScript and Zod validation for robust error handling
- Production-Ready: Comprehensive error handling, logging, and rate limit awareness
Installation
Prerequisites
- Bun 1.0.0 or higher (or Node.js 18.0.0+)
- A Linear.app account and API key
Setup
- Clone this repository:
git clone <repository-url>
cd mcp-linearapp
- Install dependencies:
bun install
- Create a
.envfile with your Linear API key:
cp .env.example .env
- Edit
.envand add your Linear API key:
LINEAR_API_KEY=lin_api_xxxxxxxxxxxxxxxxxxxxxxxxxxxxx
How to get your Linear API key:
-
Go to https://linear.app/settings/api
-
Click "Create new API key"
-
Give it a name and copy the key
-
Paste it into your
.envfile -
Build the project:
bun run build
Usage
With MCP Clients
Add this server to your MCP client's configuration file. The configuration format may vary slightly depending on your client, but typically follows this pattern:
{
"mcpServers": {
"linear": {
"command": "node",
"args": ["/absolute/path/to/mcp-linearapp/dist/index.js"],
"env": {
"LINEAR_API_KEY": "lin_api_xxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
}
}
}
}
After adding the configuration, restart your MCP client.
With Other MCP Clients
The server uses stdio transport and can be integrated with any MCP-compatible client:
bun run dist/index.js
# or with Node.js:
node dist/index.js
Available Tools
Issue Management
linear_list_issues
List Linear issues with optional filters.
Parameters:
teamId(optional): Filter by team IDprojectId(optional): Filter by project IDassigneeId(optional): Filter by assignee user IDstatus(optional): Filter by status (backlog, unstarted, started, completed, canceled, triage, in_progress, done)priority(optional): Filter by priority (0=None, 1=Urgent, 2=High, 3=Medium, 4=Low)label(optional): Filter by label namelimit(optional): Maximum number of issues (1-100, default: 25)includeArchived(optional): Include archived issues (default: false)
Example:
List all high priority issues assigned to me
linear_create_issue
Create a new Linear issue.
Parameters:
title(required): Issue titleteamId(required): Team ID where the issue will be createddescription(optional): Issue description in markdownprojectId(optional): Project ID to assign the issue toassigneeId(optional): User ID to assign the issue topriority(optional): Priority (0-4)labelIds(optional): Array of label IDsstateId(optional): Workflow state IDestimate(optional): Estimate in pointsdueDate(optional): Due date (YYYY-MM-DD)parentId(optional): Parent issue ID for sub-issuescycleId(optional): Cycle ID to assign the issue to
Example:
Create an issue titled "Fix login bug" in the Engineering team with high priority
linear_update_issue
Update an existing Linear issue.
Parameters:
issueId(required): Issue ID or identifier (e.g., "ENG-123")title,description,assigneeId,priority,stateId,labelIds,estimate,dueDate,projectId,cycleId(all optional)
Example:
Update issue ENG-123 to change priority to urgent and assign to John
linear_get_issue
Get detailed information about a specific issue.
Parameters:
issueId(required): Issue ID or identifier (e.g., "ENG-123")
Example:
Get details for issue ENG-123
linear_search_issues
Search issues by text query.
Parameters:
query(required): Search query textteamId(optional): Limit search to specific teamlimit(optional): Maximum results (1-100, default: 25)includeArchived(optional): Include archived issues
Example:
Search for issues about authentication
linear_assign_issue
Assign an issue to a user.
Parameters:
issueId(required): Issue ID or identifierassigneeId(required): User ID to assign to
Example:
Assign issue ENG-123 to user abc-123
linear_add_comment
Add a comment to an issue.
Parameters:
issueId(required): Issue ID or identifierbody(required): Comment body in markdown
Example:
Add a comment to ENG-123 saying "This is fixed in the latest build"
Team & Workflow
linear_list_teams
List all teams in your workspace.
Parameters:
includeArchived(optional): Include archived teams (default: false)
Example:
List all teams
linear_get_team
Get detailed information about a specific team.
Parameters:
teamId(required): Team ID
Example:
Get details for team abc-123
linear_create_team
Create a new Linear team.
Parameters:
name(required): Team namekey(required): Team key (1-5 uppercase letters, e.g., "ENG")description(optional): Team descriptionicon(optional): Team icon (emoji)color(optional): Team color in hex formattimezone(optional): Team timezoneprivate(optional): Whether the team is private
Example:
Create a team called "Engineering" with key "ENG"
linear_update_team
Update an existing Linear team.
Parameters:
teamId(required): Team IDname,key,description,icon,color,timezone,private(all optional)
Example:
Update team abc-123 to change the description
linear_list_workflow_states
List workflow states for a team.
Parameters:
teamId(required): Team ID
Example:
List workflow states for team abc-123
Projects
linear_list_projects
List all projects.
Parameters:
teamId(optional): Filter by team IDincludeArchived(optional): Include archived projects (default: false)
Example:
List all projects for the Engineering team
linear_create_project
Create a new Linear project.
Parameters:
name(required): Project nameteamIds(required): Array of team IDs this project is associated withdescription(optional): Project descriptionleadId(optional): User ID of the project leadmemberIds(optional): Array of user IDs for project memberscolor(optional): Project color in hex format (e.g., "#FF0000")icon(optional): Project icon (emoji or icon name)priority(optional): Priority (0=None, 1=Urgent, 2=High, 3=Normal, 4=Low)startDate(optional): Planned start date (YYYY-MM-DD)targetDate(optional): Planned target/completion date (YYYY-MM-DD)statusId(optional): Project status IDcontent(optional): Project content in markdown format
Example:
Create a project called "Website Redesign" for the Design and Engineering teams with a target date of end of Q1
linear_update_project
Update an existing Linear project.
Parameters:
projectId(required): Project IDname,description,leadId,memberIds,color,icon,priority,startDate,targetDate,statusId,content,teamIds(all optional)state(optional): Project state (planned, started, paused, completed, canceled)
Example:
Update project abc-123 to mark it as completed and set the target date to today
linear_get_project
Get detailed information about a specific project.
Parameters:
projectId(required): Project ID
Example:
Get details for project abc-123
linear_archive_project
Archive a Linear project.
Parameters:
projectId(required): Project ID to archive
Example:
Archive project abc-123
linear_unarchive_project
Unarchive a previously archived Linear project.
Parameters:
projectId(required): Project ID to unarchive
Example:
Unarchive project abc-123
Cycles (Sprints)
linear_create_cycle
Create a new cycle/sprint.
Parameters:
teamId(required): Team IDname(required): Cycle namedescription(optional): Cycle descriptionstartsAt(required): Start date (YYYY-MM-DD)endsAt(required): End date (YYYY-MM-DD)
Example:
Create a 2-week sprint starting today for the Engineering team
linear_list_cycles
List cycles for a team.
Parameters:
teamId(required): Team IDincludeArchived(optional): Include archived cycles
Example:
List all active cycles for team abc-123
linear_get_cycle
Get detailed information about a specific cycle.
Parameters:
cycleId(required): Cycle ID
Example:
Get details for cycle abc-123
linear_update_cycle
Update an existing cycle.
Parameters:
cycleId(required): Cycle IDname(optional): New cycle namedescription(optional): New cycle descriptionstartsAt(optional): New start date (YYYY-MM-DD)endsAt(optional): New end date (YYYY-MM-DD)
Example:
Update cycle abc-123 to extend the end date by one week
linear_archive_cycle
Archive a cycle.
Parameters:
cycleId(required): Cycle ID to archive
Example:
Archive cycle abc-123
linear_unarchive_cycle
Unarchive a previously archived cycle.
Parameters:
cycleId(required): Cycle ID to unarchive
Example:
Unarchive cycle abc-123
Custom Views
linear_list_custom_views
List all custom views.
Parameters:
includeArchived(optional): Include archived custom views (default: false)
Example:
List all custom views
linear_create_custom_view
Create a new custom view with filters. Filters allow you to save specific issue queries for quick access.
Parameters:
name(required): Custom view namedescription(optional): Custom view descriptionteamId(optional): Team ID to associate the view withprojectId(optional): Project ID to associate the view withicon(optional): View icon (emoji or icon name)color(optional): View icon color in hex format (e.g., "#FF0000")shared(optional): Whether the view is shared with everyone in the organizationfilters(optional): JSON object containing issue filters (see Filters Guide)
Filter Example:
{
"priority": { "eq": 1 },
"state": { "type": { "eq": "started" } },
"assignee": { "id": { "eq": "user-id" } }
}
Example:
Create a custom view called "My High Priority Bugs" that shows only high priority bugs assigned to me
See also: Custom View Filters Guide for comprehensive filter documentation
linear_update_custom_view
Update an existing custom view.
Parameters:
viewId(required): Custom view IDname,description,teamId,projectId,icon,color,shared,filters(all optional)
Example:
Update custom view abc-123 to change the name and make it shared
linear_get_custom_view
Get detailed information about a specific custom view.
Parameters:
viewId(required): Custom view ID
Example:
Get details for custom view abc-123
linear_delete_custom_view
Delete a custom view.
Parameters:
viewId(required): Custom view ID to delete
Example:
Delete custom view abc-123
Labels
linear_create_label
Create a new label.
Parameters:
name(required): Label nameteamId(required): Team IDcolor(optional): Color in hex format (e.g., "#FF0000")description(optional): Label description
Example:
Create a label called "bug" with red color for the Engineering team
linear_list_labels
List all labels.
Parameters:
teamId(optional): Filter by team ID
Example:
List all labels
Users
linear_list_users
List all users in your workspace.
Parameters:
includeDisabled(optional): Include disabled users (default: false)
Example:
List all active users
Workflow Examples
Creating an Issue with Full Context
- First, list teams to get the team ID:
List all teams
- Optionally, list users to assign the issue:
List all users
- Create the issue:
Create an issue titled "Implement OAuth authentication" in team abc-123, assign to user xyz-456, with high priority and description "Need to add OAuth 2.0 support for Google and GitHub"
Managing a Sprint
- Create a new cycle:
Create a 2-week sprint called "Q1 Sprint 3" for team abc-123 starting 2024-02-01
- List issues to find what to include:
List backlog issues for team abc-123
- Update issues to add them to the sprint and assign:
Update issue ENG-45 to add to cycle cycle-123 and assign to user xyz-456
Tracking Progress
- Search for issues in a specific area:
Search for issues about "authentication"
- Get detailed information:
Get details for issue ENG-123
- Add progress updates:
Add comment to ENG-123: "Authentication flow is complete, working on tests"
Development
Scripts
bun run build- Build the TypeScript projectbun run dev- Watch mode for developmentbun start- Start the MCP serverbun run lint- Run ESLintbun run format- Format code with Prettierbun run typecheck- Type check without emitting files
Project Structure
mcp-linearapp/
├── src/
│ ├── index.ts # Main MCP server entry point
│ ├── linear-client.ts # Linear API client wrapper
│ ├── tools/ # MCP tool implementations
│ │ ├── issues.ts # Issue-related tools
│ │ ├── projects.ts # Project tools
│ │ ├── cycles.ts # Cycle/sprint tools
│ │ ├── teams.ts # Team tools
│ │ ├── labels.ts # Label tools
│ │ └── users.ts # User tools
│ └── schemas/ # Zod validation schemas
│ └── index.ts
├── dist/ # Compiled JavaScript (generated)
├── package.json
├── tsconfig.json
└── README.md
Architecture
The server is built with:
- MCP SDK: Handles the Model Context Protocol communication
- Linear SDK: Official Linear API client
- Zod: Runtime type validation and schema enforcement
- TypeScript: Type safety throughout the codebase
Key design decisions:
- Type Safety: All inputs are validated with Zod schemas before reaching the Linear API
- Error Handling: Comprehensive error handling with meaningful error messages
- Modular Design: Tools are organized by domain (issues, projects, cycles, etc.)
- Client Wrapper: LinearAPIClient provides a clean abstraction over the Linear SDK with consistent error handling and data formatting
Error Handling
The server provides clear error messages for common issues:
- Missing API Key: "LINEAR_API_KEY environment variable is required"
- Invalid Parameters: Zod validation errors with specific field information
- API Errors: Linear API errors are caught and formatted with context
- Not Found: Clear messages when issues, teams, or other resources don't exist
Rate Limiting
Linear's API has rate limits. The server doesn't implement client-side rate limiting, but:
- Uses the official Linear SDK which handles some retry logic
- Provides clear error messages when rate limits are hit
- Consider implementing delays between bulk operations
Troubleshooting
Server won't start
- Verify LINEAR_API_KEY is set in your environment
- Check that Bun version is 1.0.0 or higher (or Node.js 18.0.0+)
- Ensure
bun run buildcompleted successfully
"Invalid API key" error
- Verify your API key is correct
- Check that the key hasn't been revoked in Linear settings
- Ensure there are no extra spaces in the .env file
"Team not found" or similar errors
- Use
linear_list_teamsto get valid team IDs - Use
linear_list_usersto get valid user IDs - Use
linear_list_projectsto get valid project IDs - Issue identifiers are case-sensitive (e.g., "ENG-123" not "eng-123")
"Parent labels" or "label group" errors
Linear organizes labels hierarchically - some labels are parent/group labels that cannot be assigned directly to issues.
The server now automatically handles this:
- When creating or updating issues, parent labels are automatically filtered out
- You'll receive a warning message indicating which labels were skipped
- Use
linear_list_labelsto see which labels are parents (marked withisParent: true) - Assign child labels instead of parent labels
Example:
Label "Module" (parent) has children:
- "Module/Auth"
- "Module/API"
- "Module/Frontend"
❌ Don't use: labelIds: ["module-id"] // Parent label - will be filtered
✅ Use instead: labelIds: ["module-auth-id"] // Child label - works!
Changes not appearing in your MCP client
- Restart your MCP client after modifying the configuration
- Check your client's logs for connection errors
- Verify the absolute path in the configuration is correct
Contributing
Contributions are welcome! Please:
- Fork the repository
- Create a feature branch
- Make your changes with proper TypeScript types
- Add/update tests if applicable
- Run
bun run lintandbun run typecheck - Submit a pull request
Additional Documentation
- API Reference - Complete documentation for all 32 MCP tools
- Custom View Filters Guide - Comprehensive guide to creating filtered views
- Quick Start Guide - Get started in 5 minutes
- Deployment Guide - Deploy to production environments
- Development Guide - Contribute to the project
License
MIT
Acknowledgments
- Built with the Model Context Protocol SDK
- Uses the Linear SDK for API access
- Inspired by the Linear community and MCP ecosystem
Support
- Linear API Documentation: https://developers.linear.app/
- MCP Documentation: https://modelcontextprotocol.io/
- Report issues: GitHub Issues
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。