Mode: Cognitive/Prompt-Driven — No standalone utility script; use via agent context.
Linear PM Skill
Overview
This skill provides comprehensive Linear project management capabilities with progressive disclosure for optimal context usage.
Context Savings: ~92% reduction
- Direct API Mode: ~15,000 tokens for full API documentation
- Skill Mode: ~300 tokens metadata + on-demand loading
Requirements
LINEAR_API_KEY environment variable set
- Internet connectivity for Linear API access
Toolsets
The skill provides 18+ tools across 5 toolsets:
| Toolset |
Description |
issues |
Issue creation, updates, comments, state changes |
projects |
Project management and issue association |
cycles |
Sprint/cycle management and planning |
teams |
Team structure and member management |
labels |
Label and workflow state management |
Quick Reference
# List issues
linear-pm list-issues --team-id "TEAM-123" --state "In Progress"
# Get issue details
linear-pm get-issue --issue-id "ISSUE-456"
# Create new issue
linear-pm create-issue --title "Bug fix" --description "Details" --team-id "TEAM-123"
# Update issue
linear-pm update-issue --issue-id "ISSUE-456" --state "Done"
# Add comment
linear-pm add-comment --issue-id "ISSUE-456" --comment "Fixed in PR #123"
# List projects
linear-pm list-projects --team-id "TEAM-123"
# Get current cycle
linear-pm current-cycle --team-id "TEAM-123"
# List cycle issues
linear-pm cycle-issues --cycle-id "CYCLE-789"
Tools by Category
Issue Operations (Confirmation Required for Mutations)
| Tool |
Description |
Confirmation |
list-issues |
List issues with filters (state, assignee, label) |
No |
get-issue |
Get detailed issue information |
No |
create-issue |
Create new issue with title, description, team |
Yes |
update-issue |
Update issue fields (state, assignee, priority) |
Yes |
add-comment |
Add comment to an issue |
Yes |
search-issues |
Search issues by text query |
No |
assign-issue |
Assign issue to team member |
Yes |
set-priority |
Set issue priority (urgent, high, medium, low) |
Yes |
add-label |
Add label to issue |
Yes |
Project Operations
| Tool |
Description |
Confirmation |
list-projects |
List all projects for a team |
No |
get-project |
Get project details and metadata |
No |
project-issues |
Get all issues in a project |
No |
create-project |
Create new project |
Yes |
update-project |
Update project details |
Yes |
Cycle Operations (Sprints)
| Tool |
Description |
Confirmation |
list-cycles |
List cycles for a team |
No |
current-cycle |
Get current active cycle |
No |
cycle-issues |
Get issues in a specific cycle |
No |
cycle-progress |
Get cycle completion metrics |
No |
Team Operations
| Tool |
Description |
Confirmation |
list-teams |
List all teams in workspace |
No |
get-team |
Get team details |
No |
team-members |
List team members |
No |
Label & State Operations
| Tool |
Description |
Confirmation |
list-labels |
List all labels for a team |
No |
list-states |
List workflow states (backlog, todo, in progress, done) |
No |
create-label |
Create new label |
Yes |
Implementation
Tool Execution Pattern
All tools use the Linear GraphQL API with progressive disclosure:
#!/usr/bin/env bash
# Example: list-issues tool
LINEAR_API_KEY="${LINEAR_API_KEY}"
if [[ -z "$LINEAR_API_KEY" ]]; then
echo "Error: LINEAR_API_KEY environment variable not set"
exit 1
fi
QUERY='query {
issues(filter: { state: { name: { eq: "In Progress" } } }) {
nodes {
id
title
state { name }
assignee { name }
priority
createdAt
}
}
}'
curl -X POST https://api.linear.app/graphql \
-H "Authorization: $LINEAR_API_KEY" \
-H "Content-Type: application/json" \
-d "{\"query\": \"$QUERY\"}"
Common Filters
Issue Filters:
state: Filter by workflow state (e.g., "In Progress", "Done")
assignee: Filter by assigned user ID
priority: Filter by priority (0=none, 1=urgent, 2=high, 3=medium, 4=low)
label: Filter by label name
team: Filter by team ID
Project Filters:
state: Filter by project state (planned, started, paused, completed)
lead: Filter by project lead user ID
Cycle Filters:
isActive: Get only active cycles
team: Filter by team ID
Security
API Key Protection:
- Never expose
LINEAR_API_KEY in logs or output
- API key should have minimal required permissions
- Use read-only API key when possible for queries
Mutation Confirmation:
All tools that modify data require confirmation:
- Issue creation/updates
- Comment additions
- Project modifications
- Label creation
Read-Only Operations (No Confirmation):
- Listing issues, projects, cycles
- Getting details
- Searching
Error Handling
If tool execution fails:
Verify API Key: Check LINEAR_API_KEY is set correctly
echo $LINEAR_API_KEY
Check API Rate Limits: Linear enforces rate limits
- GraphQL: 1500 requests per hour per API key
- REST: 500 requests per hour per API key
Validate Query Syntax: Ensure GraphQL queries are well-formed
Check Team/Issue IDs: Verify IDs exist and are accessible
Agent Integration
Primary Agents:
pm - Product management and backlog prioritization
analyst - Issue analysis and sprint planning
Secondary Agents:
developer - Issue implementation and status updates
architect - Technical issue decomposition
qa - Issue testing and validation
Common Workflows
Sprint Planning
current-cycle - Get current sprint
list-issues --state "Backlog" - Get backlog items
update-issue --cycle-id "..." - Assign issues to sprint
Issue Triage
list-issues --state "Backlog" - Get unplanned issues
set-priority --issue-id "..." --priority 2 - Set priority
add-label --issue-id "..." --label "bug" - Categorize
Project Tracking
list-projects --team-id "..." - Get all projects
project-issues --project-id "..." - Get project issues
cycle-progress --cycle-id "..." - Check sprint progress
Related
Memory Protocol (MANDATORY)
Before starting:
Read .claude/context/memory/learnings.md
After completing:
- New pattern ->
.claude/context/memory/learnings.md
- Issue found ->
.claude/context/memory/issues.md
- Decision made ->
.claude/context/memory/decisions.md
ASSUME INTERRUPTION: If it's not in memory, it didn't happen.
1---2name: linear-pm3description: Linear project management - issues, projects, cycles, and roadmaps. Use for Linear-related tasks like managing issues, tracking sprints, and organizing projects.4---5
6**Mode: Cognitive/Prompt-Driven** — No standalone utility script; use via agent context.
7
8# Linear PM Skill
9
10## Overview
11
12This skill provides comprehensive Linear project management capabilities with progressive disclosure for optimal context usage.
13
14**Context Savings**: ~92% reduction
15
16- **Direct API Mode**: ~15,000 tokens for full API documentation
17- **Skill Mode**: ~300 tokens metadata + on-demand loading
18
19## Requirements
20
21- `LINEAR_API_KEY` environment variable set
22- Internet connectivity for Linear API access
23
24## Toolsets
25
26The skill provides 18+ tools across 5 toolsets:
27
28| Toolset | Description |
29| ---------- | ------------------------------------------------ |
30| `issues` | Issue creation, updates, comments, state changes |
31| `projects` | Project management and issue association |
32| `cycles` | Sprint/cycle management and planning |
33| `teams` | Team structure and member management |
34| `labels` | Label and workflow state management |
35
36## Quick Reference
37
38```bash
39# List issues
40linear-pm list-issues --team-id "TEAM-123" --state "In Progress"
41
42# Get issue details
43linear-pm get-issue --issue-id "ISSUE-456"
44
45# Create new issue
46linear-pm create-issue --title "Bug fix" --description "Details" --team-id "TEAM-123"
47
48# Update issue
49linear-pm update-issue --issue-id "ISSUE-456" --state "Done"
50
51# Add comment
52linear-pm add-comment --issue-id "ISSUE-456" --comment "Fixed in PR #123"
53
54# List projects
55linear-pm list-projects --team-id "TEAM-123"
56
57# Get current cycle
58linear-pm current-cycle --team-id "TEAM-123"
59
60# List cycle issues
61linear-pm cycle-issues --cycle-id "CYCLE-789"
62```
63
64## Tools by Category
65
66### Issue Operations (Confirmation Required for Mutations)
67
68| Tool | Description | Confirmation |
69| --------------- | ------------------------------------------------- | ------------ |
70| `list-issues` | List issues with filters (state, assignee, label) | No |
71| `get-issue` | Get detailed issue information | No |
72| `create-issue` | Create new issue with title, description, team | Yes |
73| `update-issue` | Update issue fields (state, assignee, priority) | Yes |
74| `add-comment` | Add comment to an issue | Yes |
75| `search-issues` | Search issues by text query | No |
76| `assign-issue` | Assign issue to team member | Yes |
77| `set-priority` | Set issue priority (urgent, high, medium, low) | Yes |
78| `add-label` | Add label to issue | Yes |
79
80### Project Operations
81
82| Tool | Description | Confirmation |
83| ---------------- | -------------------------------- | ------------ |
84| `list-projects` | List all projects for a team | No |
85| `get-project` | Get project details and metadata | No |
86| `project-issues` | Get all issues in a project | No |
87| `create-project` | Create new project | Yes |
88| `update-project` | Update project details | Yes |
89
90### Cycle Operations (Sprints)
91
92| Tool | Description | Confirmation |
93| ---------------- | ------------------------------ | ------------ |
94| `list-cycles` | List cycles for a team | No |
95| `current-cycle` | Get current active cycle | No |
96| `cycle-issues` | Get issues in a specific cycle | No |
97| `cycle-progress` | Get cycle completion metrics | No |
98
99### Team Operations
100
101| Tool | Description | Confirmation |
102| -------------- | --------------------------- | ------------ |
103| `list-teams` | List all teams in workspace | No |
104| `get-team` | Get team details | No |
105| `team-members` | List team members | No |
106
107### Label & State Operations
108
109| Tool | Description | Confirmation |
110| -------------- | ------------------------------------------------------- | ------------ |
111| `list-labels` | List all labels for a team | No |
112| `list-states` | List workflow states (backlog, todo, in progress, done) | No |
113| `create-label` | Create new label | Yes |
114
115## Implementation
116
117### Tool Execution Pattern
118
119All tools use the Linear GraphQL API with progressive disclosure:
120
121```bash
122#!/usr/bin/env bash
123# Example: list-issues tool
124
125LINEAR_API_KEY="${LINEAR_API_KEY}"
126if [[ -z "$LINEAR_API_KEY" ]]; then
127 echo "Error: LINEAR_API_KEY environment variable not set"
128 exit 1
129fi
130
131QUERY='query {
132 issues(filter: { state: { name: { eq: "In Progress" } } }) {
133 nodes {
134 id
135 title
136 state { name }
137 assignee { name }
138 priority
139 createdAt
140 }
141 }
142}'
143
144curl -X POST https://api.linear.app/graphql \
145 -H "Authorization: $LINEAR_API_KEY" \
146 -H "Content-Type: application/json" \
147 -d "{\"query\": \"$QUERY\"}"
148```
149
150### Common Filters
151
152**Issue Filters**:
153
154- `state`: Filter by workflow state (e.g., "In Progress", "Done")
155- `assignee`: Filter by assigned user ID
156- `priority`: Filter by priority (0=none, 1=urgent, 2=high, 3=medium, 4=low)
157- `label`: Filter by label name
158- `team`: Filter by team ID
159
160**Project Filters**:
161
162- `state`: Filter by project state (planned, started, paused, completed)
163- `lead`: Filter by project lead user ID
164
165**Cycle Filters**:
166
167- `isActive`: Get only active cycles
168- `team`: Filter by team ID
169
170## Security
171
172**API Key Protection**:
173
174- Never expose `LINEAR_API_KEY` in logs or output
175- API key should have minimal required permissions
176- Use read-only API key when possible for queries
177
178**Mutation Confirmation**:
179All tools that modify data require confirmation:
180
181- Issue creation/updates
182- Comment additions
183- Project modifications
184- Label creation
185
186**Read-Only Operations** (No Confirmation):
187
188- Listing issues, projects, cycles
189- Getting details
190- Searching
191
192## Error Handling
193
194If tool execution fails:
195
1961. **Verify API Key**: Check `LINEAR_API_KEY` is set correctly
197
198 ```bash
199 echo $LINEAR_API_KEY
200 ```
201
2022. **Check API Rate Limits**: Linear enforces rate limits
203 - GraphQL: 1500 requests per hour per API key
204 - REST: 500 requests per hour per API key
205
2063. **Validate Query Syntax**: Ensure GraphQL queries are well-formed
207
2084. **Check Team/Issue IDs**: Verify IDs exist and are accessible
209
210## Agent Integration
211
212**Primary Agents**:
213
214- `pm` - Product management and backlog prioritization
215- `analyst` - Issue analysis and sprint planning
216
217**Secondary Agents**:
218
219- `developer` - Issue implementation and status updates
220- `architect` - Technical issue decomposition
221- `qa` - Issue testing and validation
222
223## Common Workflows
224
225### Sprint Planning
226
2271. `current-cycle` - Get current sprint
2282. `list-issues --state "Backlog"` - Get backlog items
2293. `update-issue --cycle-id "..."` - Assign issues to sprint
230
231### Issue Triage
232
2331. `list-issues --state "Backlog"` - Get unplanned issues
2342. `set-priority --issue-id "..." --priority 2` - Set priority
2353. `add-label --issue-id "..." --label "bug"` - Categorize
236
237### Project Tracking
238
2391. `list-projects --team-id "..."` - Get all projects
2402. `project-issues --project-id "..."` - Get project issues
2413. `cycle-progress --cycle-id "..."` - Check sprint progress
242
243## Related
244
245- Official Linear API Documentation: https://developers.linear.app/docs/graphql/working-with-the-graphql-api
246- Linear GraphQL Explorer: https://studio.apollographql.com/public/Linear-API/home
247- Linear Webhook Documentation: https://developers.linear.app/docs/graphql/webhooks
248
249## Memory Protocol (MANDATORY)
250
251**Before starting:**
252Read `.claude/context/memory/learnings.md`
253
254**After completing:**
255
256- New pattern -> `.claude/context/memory/learnings.md`
257- Issue found -> `.claude/context/memory/issues.md`
258- Decision made -> `.claude/context/memory/decisions.md`
259
260> ASSUME INTERRUPTION: If it's not in memory, it didn't happen.