Linear Setup
This guide walks you through connecting Itervox to your Linear workspace so AI agents can pick up issues and resolve them automatically.
Prerequisites
Section titled “Prerequisites”- A Linear workspace with at least one team and project
- A Linear Personal API key (see below)
- The
itervoxbinary installed and available on your$PATH - The repository you want agents to work in checked out locally
Get a Linear API key
Section titled “Get a Linear API key”- Open Linear and go to Settings → API.
- Under Personal API keys, click Create new API key.
- Give the key a descriptive label (e.g.
itervox-local) and click Create. - Copy the key immediately — it will not be shown again.
Store the key in an environment variable rather than hard-coding it:
export LINEAR_API_KEY="lin_api_xxxxxxxxxxxxxxxxxxxx"Find your project slug
Section titled “Find your project slug”The project slug identifies which Linear project Itervox should poll. You can find it in two ways:
- From Linear URLs — it is the short identifier shown in issue prefixes (e.g. issues prefixed
ENG-belong to theENGproject slug) - From the dashboard — start the daemon without a
project_slugand use the web dashboard’s project dropdown to browse available projects interactively
Scope: project, assignee, labels
Section titled “Scope: project, assignee, labels”What Itervox reads is the AND of three optional filters in the tracker block:
tracker: kind: linear api_key: $LINEAR_API_KEY project_slug: my-project # optional: one project (omit for every project) assignee: me # optional: me (the API key's user), a user id, or an email team: ENG # optional, with assignee: only this team (key or id) labels: ["agent", "bot"] # optional: issues carrying ANY of these labels- Only
project_slug— that project’s issues, exactly as before. Nothing set — every project, as before. - Only
assignee— the issues assigned to that user in any project of any team the key can read;teamnarrows it to one team.meresolves to the API key’s own user (Linear’sviewer): create a dedicated “Itervox” Linear user, generate the key as that user, and assign tickets to it to hand them to the agents; reassign a ticket to take it back. An email resolves through Linear’s user list; anything else is a user id. The user is resolved once at startup and on everyWORKFLOW.mdreload, and cached; a user that does not resolve fails the polls (it never widens to every issue). project_slug+assignee— the intersection: that user’s issues inside the project (or projects).labels— ANDed with the above: an issue must carry at least one of the listed labels.active_states,terminal_states,working_state,completion_stateandbacklog_stateskeep their meaning.- Every read uses the same scope: the poll, the tracker store’s full and incremental pulls, webhook refreshes, the dependency analyzer’s issue set and automation polls.
- Leaving the scope mid-run — an issue reassigned to someone else, whose matching label is removed, or that is moved to another project while an agent works on it: the running worker finishes, no new run (or retry) is dispatched, and the dashboard marks the run “out of scope”. Bring it back into scope and it is picked up again.
- The agent’s own writes — state moves, comments, the branch name, follow-up issues — never set an assignee, so a run cannot push its own issue out of scope. Follow-up issues an agent creates are unassigned until a person routes them.
- At runtime the dashboard’s Settings → Tracker Scope card has three independent controls — projects (or all), assignee (anyone, me, or a user from your workspace; resolved before saving) and labels — and saving writes
project_slug,assigneeandlabelstoWORKFLOW.md(a cleared key is commented out) without a reload. The dashboard header shows the active scope, e.g.ENG · assigned to me · label: agent. itervox doctorchecks that the assignee resolves to a user the key can see (exit 1 if not, or ifteamnames no team the key can read) and that the key can read the issues assigned to that user across its teams.tracker.sync(the local issue sync) acceptsassigneeandlabelswith its requiredproject_slug: they narrow the project it pulls from.
Filter groups: AND, OR and NOT
Section titled “Filter groups: AND, OR and NOT”The keys above are one AND of three filters. For anything else — several required labels, excluded labels, OR across fields, teams, priority, states, cycles or milestones — write tracker.filter instead (#198): a list of groups, every condition in a group must match, and an issue is read when any group matches.
tracker: kind: linear api_key: $LINEAR_API_KEY filter: - projects: [eng-platform] # the agent lane of one project… labels_any: [agent, ai] labels_none: [blocked, needs-human] - assignee: me # …OR anything assigned to the bot - teams: [OPS] # …OR urgent ops work in the current cycle priority: [1] cycle: current- Conditions:
projects,teams(key or id),assignee(me, a user id or an email),labels_any,labels_all,labels_none,priority(0 none, 1 urgent, 2 high, 3 normal, 4 low),states(narrowsactive_states;working_statealways stays in, so a dispatched issue is not lost),cycle(currentor a cycle id) andmilestone(a project milestone name). See the configuration reference. filterreplacesproject_slug,assignee,teamandlabels; setting both is a config error naming the keys. The legacy keys mean exactly the one group{projects, assignee, teams (with the assignee), labels_any}.- Itervox compiles the filter to one Linear
IssueFilter({or: [{and: [...]}, ...]}), so the poll, the store’s pulls, the webhook refresh, the dependency analyzer and automation polls read the same issues.labels_allrequires each label (onelabels.someper label);labels_nonekeeps unlabelled issues. - Settings → Tracker Scope is a group builder: add or remove groups, add conditions with pickers fed by your projects, teams, labels and users, with AND inside a group and OR between groups marked, and a live count of the issues the draft matches (read-only, refreshed as you edit). Saving writes
tracker.filtertoWORKFLOW.mdas one line and comments the legacy keys out, without a reload. The header summarises it, e.g.eng-platform · agent|ai · ¬blocked ¬needs-human OR me. itervox doctorvalidates the filter, resolves its assignees and prints how many issues in the active states it matches.
Initialize WORKFLOW.md
Section titled “Initialize WORKFLOW.md”Run the init command from the root of your repository:
itervox init --tracker linearThis creates a WORKFLOW.md file with YAML front matter and a default Liquid prompt template. Open the file and fill in the required fields.
Configure states
Section titled “Configure states”Linear workflows are fully customisable, so you need to tell Itervox which states mean “work to do”, which mean “finished”, and which states to surface in the dashboard.
A typical configuration looks like this:
---itervox_schema_version: 2
tracker: kind: linear api_key: $LINEAR_API_KEY # resolved from env at runtime project_slug: my-project # the slug from the previous step # assignee: me # optional: also only issues assigned to this user # labels: ["agent"] # optional: also only issues with any of these labels
# States that trigger agent dispatch (issues in these states get picked up) active_states: - Todo
# State to transition the issue to when an agent starts working on it working_state: "In Progress"
# State to transition the issue to when the agent finishes successfully completion_state: "In Review"
# States that permanently stop the issue from being re-dispatched terminal_states: - Done - Cancelled - Duplicate
# States shown as the leftmost column(s) in the dashboard (defaults to ["Backlog"]) backlog_states: - Backlog
# State to move issues to when max retries are exhausted (optional) failed_state: "Blocked"
agent: max_concurrent_agents: 3
polling: interval_ms: 30000 # poll every 30 seconds---
You are an AI agent resolving Linear issue {{ issue.identifier }}: {{ issue.title }}.
{{ issue.description }}
Complete the task, push your changes, and open a pull request.State fields reference
Section titled “State fields reference”| Field | Default | Description |
|---|---|---|
active_states | ["Todo", "In Progress"] | Issues in these states are dispatched to agents |
working_state | "In Progress" | Issue is moved here when an agent starts |
completion_state | (empty) | Issue is moved here on success; leave empty to skip |
terminal_states | ["Closed", "Cancelled", "Canceled", "Duplicate", "Done"] | Issues in these states are never re-dispatched |
backlog_states | ["Backlog"] | Shown in the leftmost dashboard column(s) |
failed_state | (empty) | Issue is moved here after max retries; leave empty to pause instead |
Run Itervox
Section titled “Run Itervox”From the directory containing WORKFLOW.md:
itervoxItervox starts polling Linear every interval_ms milliseconds. When it finds an issue in an active_states state it spawns an agent and transitions the issue to working_state.
Open the dashboard at http://localhost:8090 to watch issues move through the board in real time.
State transition flow
Section titled “State transition flow”Backlog ──(manual move)──► Todo ──(Itervox picks up)──► In Progress │ ┌────────────────────────┤ │ │ (success) (max retries) │ │ ▼ ▼ In Review Blocked │ (human merges) │ ▼ DoneLimit concurrency per state
Section titled “Limit concurrency per state”If you want at most one agent running in In Progress at any time:
agent: max_concurrent_agents: 10 max_concurrent_agents_by_state: "In Progress": 1Set a failed state
Section titled “Set a failed state”Without failed_state, issues that exhaust their retry budget are paused — they stay in their current state but Itervox stops dispatching them. Setting failed_state gives them a dedicated state so they are easy to find in Linear.
Tune the polling interval
Section titled “Tune the polling interval”The default is 30 seconds (30000 ms). For faster feedback during development you can lower it, but be mindful of Linear API rate limits.
polling: interval_ms: 10000 # poll every 10 secondsIf Linear does rate-limit Itervox (it answers with HTTP 400 and a RATELIMITED error), Itervox reads Linear’s published reset time and stops sending requests until then. Queued comments and state changes wait in the outbox, show a rate limited until HH:MM chip in the dashboard, and are delivered once the window lifts — never dropped and never posted twice. When the window lifts, writes go ahead of polling reads.