BugMojoBugMojoBugMojo
FeaturesPricingBlogHelpAbout
Add to ChromeLog inGet started
BugMojoBugMojo

Bug reports that actually help fix bugs — capture, replay, share.

A product of Softech Infra.

Product

  • Features
  • Pricing
  • Browser extension
  • Get started
  • Log in

Resources

  • Help & guides
  • Blog
  • Compare
  • Glossary

Company

  • About
  • Contact
  • Security
  • Privacy
  • Terms
  • Sitemap
© 2026 BugMojo. All rights reserved.
AllGuidesEngineeringPlaybooksCompareGlossaryAlternativesBy roleBug tracking by framework
  1. Home
  2. Blog
  3. Guides
  4. How to Integrate BugMojo with Linear
Guides

How to Integrate BugMojo with Linear

Connect BugMojo to Linear so every captured bug lands as an issue with the session replay one click away — here is exactly what maps to which Linear field, the issueCreate mutation behind it, and how to wire two-way status sync.

BugMojo TeamBugMojo Team·May 22, 2026·8 min read
Guides
Line-art of a BugMojo node connected to a Linear node by a lime flow carrying replay, console and network capture tokens
TL;DR
  • What it does: a BugMojo capture becomes a Linear issue with repro steps, a replay deep link, and console/network context.
  • You need: a Linear personal API key (prefixed lin_api_) and your team's UUID teamId.
  • How: BugMojo calls Linear's GraphQL issueCreate mutation — teamId and title required, everything else optional.
  • Two-way sync: subscribe a Linear webhook to push status changes back into BugMojo.
  • Time: ~5–10 minutes, most of it spent generating the key.

What this integration does

When someone captures a bug with BugMojo, an issue is created in your chosen Linear team with the title, a description carrying the repro steps, and a deep link to the session replay plus console and network context. Map priority, labels, and an assignee too — and add a Linear webhook so status changes sync back.

Bug reports and engineering backlogs usually live in two different tools, and the gap between them is where context dies. A QA engineer files “checkout is broken,” an engineer opens the ticket a day later, and the exact click path, the console error, and the failing network request are all gone. This integration closes that gap: the moment a bug is captured, it appears in Linear as a real issue, and the engineer is one click away from watching the exact rrweb replay that produced it.

Because issues in Linear are team-based, the integration always creates work inside a specific team — so you decide up front whether BugMojo bugs land in your Engineering team, a dedicated Triage team, or somewhere else. Everything past that (priority, labels, assignee, project) is optional mapping you can layer on.

Before you start

You need three things: admin access to BugMojo (Settings → Integrations is admin-only), permission to create issues in the Linear team you're targeting, and two credentials from Linear.

  • A personal API key. Linear keys are prefixed lin_api_ and shown only once at creation, so copy it straight into a password manager. Keys authenticate as you, so create the key under a service account if you don't want issue authorship tied to a person.
  • Your team's teamId. This is a UUID — not the short key like ENG you see in issue identifiers. You can read it from Linear's team settings or query it via the API (shown below).
Finding your teamId

Run this against https://api.linear.app/graphql with your key in the Authorization header to list every team and its UUID:

query { teams { nodes { id name key } } }

The id field is the teamId you paste into BugMojo. The key (e.g. ENG) is not what the API wants.

Step-by-step setup

Step 1: Generate a Linear API key

In Linear, open your workspace settings and create a new personal API key (Settings → Account → Security & Access, or the API section). Give it a memorable name like “BugMojo sync” and copy the lin_api_… value immediately — Linear will not show it again.

Step 2: Connect Linear in BugMojo

In BugMojo, open Settings → Integrations → Linear → Connect. Paste the API key, then pick the team (this sets teamId) and a default project where new bugs should land. BugMojo stores the token encrypted at the application layer.

Step 3: Choose which fields sync

Decide whether BugMojo pushes priority, labels, and an assignee. A good default is to push priority plus a bugmojo label, so every synced issue is filterable in Linear. See the field-mapping table below for exactly what maps where.

Step 4: Capture a test bug

Capture a low-priority test bug with the BugMojo extension. Within a few seconds a new issue should appear in the Linear team you selected. Open it, confirm the description contains the repro steps, and click the deep link to verify the replay loads.

Tip

Always test with a single throwaway bug before turning sync on for the whole team. If nothing appears, check Settings → Integrations → Linear → Logs for the exact API error before reconfiguring — a 400 usually means a bad teamId, a 401 means the key.

Under the hood: the issueCreate mutation

BugMojo talks to Linear through its GraphQL API at https://api.linear.app/graphql, calling the issueCreate mutation. Only teamId and title are required; description (Markdown), priority (an integer, see the scale below), labelIds, and assigneeId are all optional. If you want a fully custom flow, you can replicate the exact call yourself — or drive it through BugMojo's MCP integration so an AI agent files the issue. Here is the shape of that request:

create-linear-issue.jsjavascript
// A BugMojo capture, mapped onto Linear's issueCreate mutation.
const res = await fetch("https://api.linear.app/graphql", {
  method: "POST",
  headers: {
    "Content-Type": "application/json",
    // Personal API key. OAuth apps send "Bearer <token>" instead.
    Authorization: process.env.LINEAR_API_KEY, // lin_api_xxxxxxxx
  },
  body: JSON.stringify({
    query: `
      mutation IssueCreate($input: IssueCreateInput!) {
        issueCreate(input: $input) {
          success
          issue { id identifier url }
        }
      }`,
    variables: {
      input: {
        teamId: "9cfb482a-81e3-4154-b5b9-2c805e70a02a", // required (UUID)
        title: "Checkout: 'Place order' button dead on Safari 17",
        // Repro steps + replay/console deep links live in the description:
        description:
          "**Steps**\n1. Add item to cart\n2. Click Place order\n\n" +
          "[Session replay](https://app.bugmojo.com/r/abc123) · " +
          "[Console + network](https://app.bugmojo.com/r/abc123#logs)",
        priority: 2,                 // 0 None, 1 Urgent, 2 High, 3 Medium, 4 Low
        labelIds: ["<bugmojo-label-uuid>"],
        assigneeId: "<optional-user-uuid>",
      },
    },
  }),
});
const { data } = await res.json();
console.log(data.issueCreate.issue.url); // -> https://linear.app/…/issue/ENG-482

Linear's priority field is an integer, not a string: 0 = None, 1 = Urgent, 2 = High, 3 = Medium, 4 = Low. Map BugMojo's severity onto these numbers — e.g. a CRITICAL capture → 1.

Field mapping: BugMojo → Linear

This is how a captured bug is projected onto IssueCreateInput. Field names are exact where Linear defines them; the mapping of which BugMojo value fills each field is illustrative and configurable in Settings → Integrations → Linear.

FeatureLinear API fieldType / exampleRequired?
Bug summary → titletitleString✓
Target team → teamIdteamIdUUID✓
Repro steps + replay/console links → descriptiondescriptionMarkdown string—
Severity → prioritypriorityInt 0–4—
Tags incl. 'bugmojo' → labelslabelIds[UUID]—
Owner → assigneeassigneeIdUUID—
Default project → projectprojectIdUUID—
Initial workflow state → statusstateIdUUID—
How BugMojo capture data maps onto Linear's issueCreate input fields.

Two-way status sync with webhooks

Pushing bugs into Linear needs only the API key. Getting status back — so closing an issue in Linear marks the BugMojo capture resolved — needs a Linear webhook. Linear sends HTTP push notifications whenever data is created or updated; you subscribe to Issue events and point them at your BugMojo endpoint. Linear's own integration guides walk through the same pattern.

Each delivery carries a Linear-Signature header: a hex-encoded HMAC-SHA256 of the raw body, signed with the webhook's signing secret. Verify it against the raw request body (not a re-serialized JSON object) using a timing-safe comparison, and check the webhookTimestamp is within about a minute to guard against replays. For an Issue update, the payload's data object holds the new state and an updatedFrom object holds the previous values — that diff is what BugMojo uses to detect a Todo → In Progress → Done transition and update the capture.

Webhooks retry — so make handling idempotent

Failed deliveries are retried (with backoff), and a webhook can be delivered more than once. Deduplicate on the resource id plus updatedAt so a redelivered “issue closed” event doesn't flip the same capture twice.

Troubleshooting

401 / 'authentication failed'

The API key is wrong, revoked, or malformed. Regenerate a fresh lin_api_ key in Linear and re-paste it in BugMojo. Personal keys can also stop working if the underlying Linear user loses access to the team — check the key belongs to an account that can still create issues there. Never commit the key to source control.

400 / 'Entity not found: Team' or bad teamId

The most common setup error: pasting the team key (ENG) instead of the team UUID. Re-run the teams { nodes { id name key } } query and copy the id. The same error appears if you point BugMojo at a team the key's user can't access.

Bugs aren't appearing at all. Confirm the connection is healthy under Settings → Integrations → Linear → Status, verify the target team and project, and read the most recent entry in the integration Logs. Sync is one-way only. BugMojo → Linear works without webhooks; updates flowing back require the webhook subscription and a reachable endpoint — a signature-verification failure will silently drop events, so log rejected deliveries while you set it up.

Caveats — when this isn't the right fit

This integration is built around Linear's team-first model, so it shines for product engineering teams already living in Linear. It's a weaker fit in a few cases. If your organisation standardises on Jira or GitHub Issues, use those guides instead — a Linear team is a hard prerequisite here. If you need the full replay, console, and network trace embedded inside the tracker rather than linked, that isn't how this works by design: those artefacts stay in BugMojo behind authentication and Linear gets a deep link. And if you rely on personal API keys, remember they authenticate as an individual — for shared, auditable automation, prefer an OAuth app or a dedicated service account so issue authorship and rate-limit quota aren't tied to one person who might offboard.

What actually leaves BugMojo

The sync sends bug metadata — title, description with repro steps, priority, reporter, status — plus a deep link to the capture (which needs a separate BugMojo login to open). The rrweb session replay, console logs, and network requests are not sent to Linear; they stay behind your authentication, and PII redaction has already run client-side in the extension before anything was uploaded.

For compliance-sensitive teams this split is a feature: searchable bug metadata lives in your audit-logged Linear workspace, while sensitive capture data stays in BugMojo and never traverses a third party.

Next steps

  • Try BugMojo free — install the extension and capture a replay in one click.
  • Explore other integrations — Slack, GitHub Issues, Jira, Cursor, Claude Code.
  • Read the MCP guide — let AI coding agents file and read bugs directly.
Capture bugs straight into Linear

Install the free BugMojo extension, capture a replay + console + network trace in one click, and sync it to your Linear team automatically.

Install the extension

Frequently asked questions

Frequently asked questions

Sources

  1. Linear Developers — GraphQL API getting started — Linear (2026)
  2. Linear Developers — Webhooks — Linear (2026)
  3. Linear Developers — Rate limiting — Linear (2026)
  4. Linear — Integration guides (webhooks scenario) — Linear (GitHub) (2025)
  5. BugMojo — product site — BugMojo (2026)
Share:
BugMojo Team
BugMojo Team· Engineering & QA

The BugMojo team builds tools for developers, QA engineers, and PMs who want bug reports that actually help fix bugs.

On this page

  • What this integration does
  • Before you start
  • Step-by-step setup
  • Step 1: Generate a Linear API key
  • Step 2: Connect Linear in BugMojo
  • Step 3: Choose which fields sync
  • Step 4: Capture a test bug
  • Under the hood: the issueCreate mutation
  • Field mapping: BugMojo → Linear
  • Two-way status sync with webhooks
  • Troubleshooting
  • Caveats — when this isn't the right fit
  • Next steps

Get bug-tracking insights, weekly.

Engineering deep-dives, QA playbooks, and honest tool comparisons. No spam — unsubscribe in one click.