> ## Documentation Index
> Fetch the complete documentation index at: https://docs.guild.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Linear

> Give agents access to Linear issues, projects, and cycles.

The `@guildai-services/guildai~linear` package gives your agents access to Linear issues, projects, and cycles through Guild's Linear integration.

## Authentication

* **Type:** API key or OAuth 2.0
* **Token management:** API keys do not expire; OAuth tokens refresh automatically

### Setup

<Steps>
  <Step title="Open Credentials">Go to **Credentials** in Guild.</Step>
  <Step title="Connect Linear">Click **Linear** and enter your API key or authorize via OAuth.</Step>
</Steps>

## Usage

```typescript theme={null}
import { linearTools } from "@guildai-services/guildai~linear"
import { llmAgent } from "@guildai/agents-sdk"

export default llmAgent({
  description: "An agent that manages Linear issues",
  tools: { ...linearTools },
})
```

### Selecting specific tools

Tools are named with the `linear_` prefix. Use `pick()` to include only what your agent needs. For advanced queries, use `linear_graphql_query` to run arbitrary GraphQL against the Linear API.

```typescript theme={null}
import { linearTools } from "@guildai-services/guildai~linear"
import { llmAgent, pick } from "@guildai/agents-sdk"

export default llmAgent({
  description: "An agent that triages Linear issues",
  tools: {
    ...pick(linearTools, [
      "linear_issues_list",
      "linear_issues_get",
      "linear_issues_update",
      "linear_graphql_query",
    ]),
  },
})
```
