Fix & ship — API reference
Typed remediations, the evals-from-failures flywheel, and deploy-event correlation.
0.16.6). Download the full spec at /docs/openapi.json.remediations
GET /remediations
Get Remediations
Details
Responses
| Status | Description |
|---|---|
200 | Successful Response |
GET /remediations/agent-context
Get Agent Context
Return the project’s optional agent context (nulls when unset).
Details
Responses
| Status | Description |
|---|---|
200 | Successful Response |
PUT /remediations/agent-context
Put Agent Context
Upsert the project’s agent context (improves future grounded generations).
Details
Request body (application/json) — required
| Field | Type | Required | Description |
|---|---|---|---|
systemPrompt | string | null | no | |
repoUrl | string | null | no | |
notes | string | null | no |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
GET /remediations/efficacy-report
Efficacy Report
Per-project post-merge efficacy + MTTR report from LIVE close-out data: failure volume before/after, fixes shipped/verified/regressed/pending, median MTTR, and a monthly trend.
Details
Responses
| Status | Description |
|---|---|
200 | Successful Response |
POST /remediations/generate
Generate Remediation
Details
Request body (application/json) — required
| Field | Type | Required | Description |
|---|---|---|---|
clusterId | string | null | no | |
failureModeId | string | null | no |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
GET /remediations/items
List Remediations
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
clusterId | query | string | null | no | |
failureModeId | query | string | null | no | |
failure_mode_id | query | string | null | no | |
status | query | string | null | no | |
workState | query | string | null | no | |
type | query | string | null | no | |
label | query | string | null | no | |
q | query | string | null | no | |
sort | query | string | null | no | |
includeArchived | query | boolean | no | |
include_ungrounded | query | boolean | no | |
include_advisories | query | boolean | no | |
actionability | query | string | null | no | |
failureLocus | query | string | null | no | |
failure_locus | query | string | null | no | |
view | query | string | null | no |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
GET /remediations/items/{rid}
Get Remediation
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
rid | path | string | yes |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
PATCH /remediations/items/{rid}
Patch Remediation
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
rid | path | string | yes | |
force | query | boolean | no | |
reason | query | string | null | no |
Request body (application/json) — required
| Field | Type | Required | Description |
|---|---|---|---|
status | string | null | no | |
workState | string | null | no | |
labels | string[] | null | no | |
prUrl | string | null | no | |
commitSha | string | null | no | |
acknowledgedBy | string | null | no | |
note | string | null | no |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
DELETE /remediations/items/{rid}
Delete Remediation
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
rid | path | string | yes |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
GET /remediations/items/{rid}/closeout
Get Closeout
The single most-recent close-out for this remediation, or 404.
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
rid | path | string | yes |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
GET /remediations/items/{rid}/efficacy
Efficacy
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
rid | path | string | yes |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
GET /remediations/items/{rid}/fix-bundle
Get Fix Bundle
Assemble a remediation’s root cause + typed fix spec + proof evals + anonymized failing
exemplars into ONE coding-agent-ready pack (markdown + structured JSON + a pre-generated
neens eval run CI command). Pure assembly of data Neens already computes — no LLM, no
egress, no repo access. Read-only; mirrors the sibling GET-detail routes.
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
rid | path | string | yes |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
POST /remediations/items/{rid}/record-merge
Record Merge Route
Record that a Neens-opened fix PR for this remediation was MERGED (the manual + MCP path):
stamp a deploy event + a pending close-out watch. The webhook (POST /webhooks/github) is the
automated sibling. Returns the close-out dict.
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
rid | path | string | yes |
Request body (application/json)
Schema: object.
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
POST /remediations/items/{rid}/regenerate
Regenerate Remediation Item
Re-run the CURRENT grounded engine for this remediation’s source (cluster or failure mode),
producing a FRESH remediation and archiving this one as a superseded predecessor. Force-capable on ANY status — the old proposal (and its PR/verification state) is
preserved, never mutated in place and never deleted. Runs synchronously (one generation). 404 if
rid is not in the caller’s project scope; 409 if it is already superseded. Returns the NEW
remediation dict with regeneratedFromId set and an embedded compact predecessor.
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
rid | path | string | yes |
Request body (application/json)
Schema: object.
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
POST /remediations/items/{rid}/simulate
Simulate
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
rid | path | string | yes |
Request body (application/json)
Schema: object.
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
GET /remediations/items/{rid}/simulation-plan
Simulation Plan
Describe what a simulate run WOULD do WITHOUT running any replay. Shares the exact
target-selection + judge/model resolution used by POST.../simulate. The optional
override query params mirror SimulateRequest (minus the explicit cohort — the UI holds
the selected ids client-side) so the Configure panel gets a live preview of a tuned run.
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
rid | path | string | yes | |
judgeId | query | string | null | no | |
threshold | query | number | null | no | |
maxTargets | query | integer | null | no | |
sampling | query | string | null | no | |
connectionId | query | string | null | no | |
strategy | query | string | null | no |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
POST /remediations/regenerate-bulk
Regenerate Remediations Bulk
Regenerate a SET of remediations with the current engine. Resolves the
target id list under project scope from exactly one selector (remediation_ids |
failure_mode_id | all_open), caps it at a server-side maximum, then:
Details
Request body (application/json) — required
| Field | Type | Required | Description |
|---|---|---|---|
remediationIds | string[] | null | no | |
failureModeId | string | null | no | |
allOpen | boolean | null | no | |
reason | string | null | no |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
GET /remediations/stats
Remediation Stats
Details
Responses
| Status | Description |
|---|---|
200 | Successful Response |
GET /remediations/trend
Remediations Trend
Throughput trend for the Remediations page: per-day (or per-hour) count of fix tasks created over the selected window, plus a period-over-period total. Scoped to the current project. Creation volume is counted regardless of later archive state, so a historical trend doesn’t drift as tasks are archived.
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
range | query | string | null | no | |
from | query | string | null | no | |
to | query | string | null | no | |
grain | query | string | null | no |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
flywheel
POST /flywheel/failure-modes/{mode_id}/generate-eval
Generate Eval
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
mode_id | path | string | yes |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
GET /flywheel/gates
List Gates
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
status | query | string | null | no | |
failureModeId | query | string | null | no | |
name | query | string | null | no | |
sort_by | query | string | null | no | |
sort_dir | query | string | null | no |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
GET /flywheel/gates/{gate_id}
Get Gate
Rich single-gate detail: the stored gate row PLUS the provenance it binds together (failure mode / judge / dataset / deployment) and a bounded history of its recent eval runs, so the UI can explain what this gate checks, when it last ran, and how it has been trending on one click. Every cross-table read is best-effort and project-scoped.
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
gate_id | path | string | yes |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
PATCH /flywheel/gates/{gate_id}
Patch Gate
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
gate_id | path | string | yes |
Request body (application/json) — required
| Field | Type | Required | Description |
|---|---|---|---|
status | string | null | no | |
baselinePassRate | number | null | no |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
POST /flywheel/gates/{gate_id}/run
Run Gate
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
gate_id | path | string | yes |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
deploy-events
GET /deploy-events
List Deploy Events
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
agentName | query | string | null | no | |
since | query | string | null | no |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
POST /deploy-events
Create Deploy Event
Details
Request body (application/json) — required
| Field | Type | Required | Description |
|---|---|---|---|
kind | string | yes | |
title | string | yes | |
agentName | string | null | no | |
oldValue | string | null | no | |
newValue | string | null | no | |
deployedAt | string | null | no | |
deployedBy | string | null | no |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |
GET /deploy-events/what-changed
What Changed
Details
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
at | query | string | yes | ISO-8601 reference instant |
agentName | query | string | null | no | |
windowHours | query | integer | no |
Responses
| Status | Description |
|---|---|
200 | Successful Response |
422 | Validation Error |