linear-core-workflow-a
Issue lifecycle management with Linear: create, update, transition, relate, comment, and organize issues through the SDK and GraphQL API. Trigger: "linear issue workflow", "linear issue lifecycle", "create linear issues", "update linear issue", "linear state transition", "linear sub-issues", "linear comments".
What this skill does
# Linear Core Workflow A: Issue Lifecycle
## Overview
Master issue lifecycle management: creating, updating, transitioning states, building parent/sub-issue hierarchies, managing labels, and commenting. Linear issues flow through typed workflow states (`triage` -> `backlog` -> `unstarted` -> `started` -> `completed` | `canceled`), belong to a team, and support priorities 0-4, estimates, due dates, labels, and cycle/project assignment.
## Prerequisites
- `@linear/sdk` installed with API key or OAuth token configured
- Access to target team(s)
- Understanding of your team's workflow states
## Instructions
### Step 1: Create Issues
```typescript
import { LinearClient } from "@linear/sdk";
const client = new LinearClient({ apiKey: process.env.LINEAR_API_KEY! });
// Get team
const teams = await client.teams();
const team = teams.nodes.find(t => t.key === "ENG") ?? teams.nodes[0];
// Basic issue
const result = await client.createIssue({
teamId: team.id,
title: "Implement user authentication",
description: "Add OAuth 2.0 login flow with Google and GitHub providers.",
priority: 2, // 0=None, 1=Urgent, 2=High, 3=Medium, 4=Low
});
if (result.success) {
const issue = await result.issue;
console.log(`Created: ${issue?.identifier} — ${issue?.title}`);
console.log(`URL: ${issue?.url}`);
}
// Issue with full metadata
const labelResult = await client.issueLabels({ filter: { name: { eq: "Bug" } } });
const bugLabel = labelResult.nodes[0];
const states = await team.states();
const todoState = states.nodes.find(s => s.type === "unstarted")!;
await client.createIssue({
teamId: team.id,
title: "Fix login redirect loop on Safari",
description: "Users get stuck in infinite redirect after SSO callback.",
priority: 1,
stateId: todoState.id,
assigneeId: "user-uuid",
labelIds: bugLabel ? [bugLabel.id] : [],
estimate: 3,
dueDate: "2026-04-15",
});
```
### Step 2: Update Issues
```typescript
// Update by issue ID
await client.updateIssue("issue-uuid", {
title: "Updated title",
priority: 1,
estimate: 5,
dueDate: "2026-04-30",
});
// Find issue by team key + number, then update
const issues = await client.issues({
filter: { number: { eq: 123 }, team: { key: { eq: "ENG" } } },
});
const issue = issues.nodes[0];
if (issue) {
await issue.update({
priority: 2,
description: "Updated description with more details.",
});
}
// Add/remove labels
const featureLabel = (await client.issueLabels({
filter: { name: { eq: "Feature" } },
})).nodes[0];
if (featureLabel) {
await client.updateIssue(issue.id, {
labelIds: [...(issue.labelIds ?? []), featureLabel.id],
});
}
```
### Step 3: State Transitions
```typescript
// List all workflow states for a team
const teamStates = await team.states();
for (const state of teamStates.nodes) {
console.log(`${state.name} (type: ${state.type}, position: ${state.position})`);
}
// Output example:
// Triage (type: triage, position: 0)
// Backlog (type: backlog, position: 1)
// Todo (type: unstarted, position: 2)
// In Progress (type: started, position: 3)
// In Review (type: started, position: 4)
// Done (type: completed, position: 5)
// Canceled (type: canceled, position: 6)
// Move to "In Progress"
const inProgress = teamStates.nodes.find(s => s.name === "In Progress");
if (inProgress) {
await client.updateIssue(issue.id, { stateId: inProgress.id });
}
// Complete an issue
const done = teamStates.nodes.find(s => s.type === "completed");
if (done) {
await issue.update({ stateId: done.id });
}
```
### Step 4: Parent/Sub-Issue Hierarchy
```typescript
// Create parent issue
const parentResult = await client.createIssue({
teamId: team.id,
title: "Auth system overhaul",
description: "Epic: modernize authentication infrastructure.",
});
const parent = await parentResult.issue;
// Create sub-issues under parent
await client.createIssue({
teamId: team.id,
title: "Implement JWT token refresh",
parentId: parent!.id,
priority: 2,
});
await client.createIssue({
teamId: team.id,
title: "Add MFA support",
parentId: parent!.id,
priority: 3,
});
// List sub-issues
const children = await parent!.children();
for (const child of children.nodes) {
console.log(` Sub: ${child.identifier} — ${child.title}`);
}
```
### Step 5: Issue Relations
```typescript
// Relation types: "blocks", "duplicate", "related"
await client.createIssueRelation({
issueId: "blocked-issue-id",
relatedIssueId: "blocking-issue-id",
type: "blocks",
});
// Mark as duplicate
await client.createIssueRelation({
issueId: "duplicate-issue-id",
relatedIssueId: "original-issue-id",
type: "duplicate",
});
// List relations on an issue
const relations = await issue.relations();
for (const rel of relations.nodes) {
const related = await rel.relatedIssue;
console.log(`${rel.type}: ${related?.identifier}`);
}
```
### Step 6: Comments
```typescript
// Add a comment (supports Markdown)
await client.createComment({
issueId: issue.id,
body: "Deployed fix to staging.\n\n```bash\nnpm run test:e2e -- --filter auth\n```\n\nAll 47 tests passing.",
});
// List comments on an issue
const comments = await issue.comments();
for (const comment of comments.nodes) {
const user = await comment.user;
console.log(`${user?.name}: ${comment.body.substring(0, 80)}...`);
}
```
### Step 7: Attachments
```typescript
// Create a link attachment on an issue
await client.createAttachment({
issueId: issue.id,
title: "Figma Design",
url: "https://figma.com/file/xxx",
subtitle: "Login page redesign",
});
```
## Error Handling
| Error | Cause | Solution |
|-------|-------|----------|
| `Entity not found` | Invalid issue ID or deleted | Verify with `client.issue(id)` first |
| `State not found` | Wrong team's state ID | List states for correct team: `team.states()` |
| `Validation error` on create | Missing required field | `teamId` + `title` required; priority must be 0-4 |
| `Circular dependency` | Issue blocks itself transitively | Validate relation graph before creating |
| `Forbidden` | No write access to team | Check team membership and API key scope |
## Examples
### Bulk Create from CSV
```typescript
import { parse } from "csv-parse/sync";
import fs from "fs";
const rows = parse(fs.readFileSync("issues.csv"), { columns: true });
for (const row of rows) {
const result = await client.createIssue({
teamId: team.id,
title: row.title,
description: row.description,
priority: parseInt(row.priority) || 3,
});
const issue = await result.issue;
console.log(`Created: ${issue?.identifier}`);
}
```
### Close Stale Issues
```typescript
const stale = await client.issues({
filter: {
state: { type: { in: ["unstarted", "started"] } },
updatedAt: { lt: new Date(Date.now() - 90 * 24 * 60 * 60 * 1000).toISOString() },
},
first: 50,
});
const canceled = (await team.states()).nodes.find(s => s.type === "canceled")!;
for (const issue of stale.nodes) {
await issue.update({ stateId: canceled.id });
await client.createComment({
issueId: issue.id,
body: "Auto-closed: no activity for 90 days.",
});
console.log(`Closed: ${issue.identifier} (last updated ${issue.updatedAt})`);
}
```
## Resources
- [SDK Data Fetching](https://linear.app/developers/sdk-fetching-and-modifying-data)
- [GraphQL Filtering](https://linear.app/developers/filtering)
- [Issue Model Schema](https://studio.apollographql.com/public/Linear-API/variant/current/schema/reference/objects/Issue)
Related in Backend & APIs
jfrog
IncludedInteract with the JFrog Platform via the JFrog CLI and REST/GraphQL APIs. Use this skill when the user wants to manage Artifactory repositories, upload or download artifacts, manage builds, configure permissions, manage users and groups, work with access tokens, configure JFrog CLI servers, search artifacts, manage properties, set up replication, manage JFrog Projects, run security audits or scans, look up CVE details, query exposures scan results from JFrog Advanced Security, manage release bundles and lifecycle operations, aggregate or export platform data, or perform any JFrog Platform administration task. Also use when the user mentions jf, jfrog, artifactory, xray, distribution, evidence, apptrust, onemodel, graphql, workers, mission control, curation, advanced security, exposures, or any JFrog product name.
cupynumeric-migration-readiness
IncludedPre-migration readiness assessor for porting NumPy to cuPyNumeric. Use BEFORE substantial porting work begins when the user asks whether code will scale on GPU, whether they should migrate to cuPyNumeric, which NumPy patterns transfer cleanly, what must be refactored before porting, or mentions pre-port assessment, scaling analysis, or refactor planning. Inspect the user's source code, look up NumPy usage, cross-reference the cuPyNumeric API support manifest, and distinguish distributed-scaling-friendly patterns from blockers such as unsupported APIs, scalar synchronization, host round-trips, Python/object-heavy control flow, shape/data-dependent branching, and in-place mutation hazards. Produce a verdict of READY, LIGHT REFACTOR, SIGNIFICANT REFACTOR, or NOT RECOMMENDED, with concrete refactor pointers.
alibabacloud-data-agent-skill
IncludedInvoke Alibaba Cloud Apsara Data Agent for Analytics via CLI to perform natural language-driven data analysis on enterprise databases. Data Agent for Analytics is an intelligent data analysis agent developed by Alibaba Cloud Database team for enterprise users. It automatically completes requirement analysis, data understanding, analysis insights, and report generation based on natural language descriptions. This tool supports: discovering data resources (instances/databases/tables) managed in DMS, initiating query or deep analysis sessions, real-time progress tracking, and retrieving analysis conclusions and generated reports. Use this Skill when users need to query databases, analyze data trends, generate data reports, ask questions in natural language, or mention "Data Agent", "data analysis", "database query", "SQL analysis", "data insights".
token-optimizer
IncludedReduce OpenClaw token usage and API costs through smart model routing, heartbeat optimization, budget tracking, and native 2026.2.15 features (session pruning, bootstrap size limits, cache TTL alignment). Use when token costs are high, API rate limits are being hit, or hosting multiple agents at scale. The 4 executable scripts (context_optimizer, model_router, heartbeat_optimizer, token_tracker) are local-only — no network requests, no subprocess calls, no system modifications. Reference files (PROVIDERS.md, config-patches.json) document optional multi-provider strategies that require external API keys and network access if you choose to use them. See SECURITY.md for full breakdown.
resend-cli
IncludedUse this skill when the task is specifically about operating Resend from an AI agent, terminal session, or CI job via the official resend CLI: installing/authenticating the CLI, sending/listing/updating/cancelling emails, batch sends, domains and DNS, webhooks and local listeners, inbound receiving, contacts, topics, segments, broadcasts, templates, API keys, profiles, or debugging Resend CLI/API failures. Trigger on mentions of Resend CLI, `resend`, `resend doctor`, `resend emails send`, `resend domains`, `resend webhooks listen`, `resend emails receiving`, or agent-friendly terminal automation.
alibabacloud-odps-maxframe-coding
IncludedUse this skill for MaxFrame SDK development and documentation navigation on Alibaba Cloud MaxCompute (ODPS). Helps answer MaxFrame API, concept, official example, and supported pandas API questions; create data processing programs; read/write MaxCompute tables; debug jobs (remote or local); and build custom DPE runtime images. Trigger when users mention MaxFrame, MaxCompute with MaxFrame, ODPS table processing, DPE runtime, MaxFrame docs/examples, DataFrame/Tensor operations, or GPU runtime setup. Works for both English and Chinese queries about Alibaba Cloud data processing with MaxFrame.