Fix context bundle
get_fix_contextFetch a paste-ready fix prompt, plain-English diagnosis, repro steps, root cause, blast radius, and app tokens for one bug report in a single call before writing a fix.
Instructions
Bundle everything an agent needs to fix one bug in a single call: a paste-ready fixPrompt (plain-English diagnosis + reproduction + suggested fix + relevant code + blast radius), plus report detail, repro steps, component, root cause, ontology tags, and the inventory action (with its expected_outcome contract) the report is filed against, plus recipe: a ≤4 KB excerpt with the app's tokens (CSS var / TS names), the design deviance score and deviance findings in the files this fix touches, so the fix uses the app's tokens instead of literals, and recipe.context: the tables the stack trace names with their columns from the latest schema snapshot (and any it says do not exist), whether the last merged fix is live, and the open hole-check findings, each section with its own state and note. Returns { report, fixPrompt, reproductionSteps, component, rootCause, bugOntologyTags, inventoryAction, recipe }; recipe is always { state, note, … } with state ok | drift | unknown | not_connected | error, never null. Read-only; no second LLM key needed. Use before writing a fix; use triage_issue for a multi-report review packet, or suggest_fix for just the Stage-2 hint.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| reportId | Yes | The report UUID to fix (`report_id` is accepted too.) | |
| projectId | No | Project UUID — required for org-scoped keys with multiple projects. (`project_id` is accepted too.) |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| recipe | Yes | Design excerpt (≤ 4 KB) for the report's project: tokens with CSS var / TS names, the deviance score, findings in the files this fix touches, and context (tables the stack trace names, whether the last fix is live, open hole checks). Never null; when it could not be read, { state: 'error', note }. | |
| report | Yes | ||
| component | Yes | Component or page the bug was attributed to | |
| fixPrompt | Yes | Paste-ready fix prompt composed server-side, or null | |
| rootCause | Yes | Stage-2 root cause, or null before Stage 2 runs | |
| bugOntologyTags | Yes | Bug ontology tags, or null | |
| inventoryAction | Yes | The inventory action (with its expected_outcome contract) the report is filed against, or null | |
| reproductionSteps | Yes | Reproduction steps recorded on the report ([] if none) |