Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.mirage.strukto.ai/llms.txt

Use this file to discover all available pages before exploring further.

LinearResource exposes a Linear workspace as a tree of teams, projects, and issues. Reads route through the Linear GraphQL API. Setup steps for the API key live at Linear Credentials.

Node

pnpm add @struktoai/mirage-node
import { LinearResource, MountMode, Workspace } from '@struktoai/mirage-node'

const linear = new LinearResource({
  apiKey: process.env.LINEAR_API_KEY!,
  workspace: 'strukto',
})

const ws = new Workspace({ '/linear': linear }, { mode: MountMode.READ })
await ws.execute('ls /linear/teams/')

Browser

pnpm add @struktoai/mirage-browser
import { LinearResource, MountMode, Workspace } from '@struktoai/mirage-browser'

const linear = new LinearResource({
  apiKey: LINEAR_API_KEY,
})

Config

FieldDefaultNotes
apiKeyrequiredPersonal API key. Redacted in snapshots.
workspace(auto)Workspace identifier; auto-detected from the key.
teamIdsnoneOptional allowlist of team IDs to expose.
baseUrlhttps://api.linear.app/graphqlOverride for self-hosted instances.

Mount mode

read. For the mounted layout (teams/, projects/, issues/) see the Python Linear docs.