GET /api/governor/audit-reports — #1034: the WORKSPACE-WIDE governor audit reports (`agent_profile_id IS NULL`), the rows `run_weekly_audit_sweep` writes. Workspace-admin read, exactly like the per-profile `governor-audit` card beside it: it exposes aggregate quality metrics, not a mutation.
const url = 'https://example.com/api/governor/audit-reports';const options = {method: 'GET', headers: {cookie: 'supacloud_session=<supacloud_session>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://example.com/api/governor/audit-reports \ --cookie supacloud_session=<supacloud_session>Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”Recompute the verdict-source facet chips (default true).
Responses
Section titled “Responses”One page of workspace-wide governor audit reports
GET /api/governor/audit-reports body — one page of workspace-wide governor audit
reports + the total + the verdict-source facets.
object
#1034 — the facet chips of the workspace-wide audit board: how the period verdicts split between a TRUSTED judge and the deterministic fallback. This is the one number that tells an admin whether the quality scores they are reading were produced by the calibrated judge at all.
object
Reports that fell back to the deterministic outcome metrics.
Reports whose headline quality came from the kappa-gated judge.
A persisted governor audit report projected for the read API (the agent-profile
editor’s “Governor audit” card). Carries the audit window, the calibration kappa
and the self-describing metrics blob (success rate, mean reward/cost, judge-
trust verdict, quality score) so the FE renders the headline numbers without a
second round trip. agent_profile_id is None on a workspace-wide audit.
object
Cohen’s kappa of the LLM judge vs ground truth (None until enough
calibration samples — the judge is then untrusted and the verdict is
deterministic).
The self-describing aggregate: sample_count, success_rate, mean_reward,
mean_cost_usd, judge_trusted, quality_score, verdict_source. Runtime
stays serde_json::Value; the spec types it as [GovernorAuditMetrics].
object
Examplegenerated
{ "facets": { "deterministic": 1, "judge": 1 }, "items": [ { "agent_profile_id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "created_at": "2026-04-15T12:00:00Z", "id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "kappa": 1, "metrics": { "calibration_samples": 1, "judge_trusted": true, "mean_cost_usd": 1, "mean_reward": 1, "quality_score": 1, "sample_count": 1, "success_rate": 1, "verdict_source": "example" }, "period_end": "2026-04-15T12:00:00Z", "period_start": "2026-04-15T12:00:00Z" } ], "total": 1}Authentication required
The canonical JSON body of every error response — the single source of truth
the frontend binds to. Every AppError serializes as this exact shape, and
the generated OpenAPI component ApiErrorBody (with its ErrorCode enum) is
what the frontend error schema is generated from, so there is no hand-written
error schema on either end.
object
Machine-readable, stable error code.
Present only on a quota-exceeded 403 — the inline upgrade-CTA payload.
object
The entitlement feature key that was hit, e.g. apps.max_count.
The plan’s limit for this key.
Where to send the user to upgrade.
Current usage (count or bytes, per the key).
Human-readable message (the server’s English text; the client may localize
by code).
Example
{ "code": "not_found"}Permission denied
The canonical JSON body of every error response — the single source of truth
the frontend binds to. Every AppError serializes as this exact shape, and
the generated OpenAPI component ApiErrorBody (with its ErrorCode enum) is
what the frontend error schema is generated from, so there is no hand-written
error schema on either end.
object
Machine-readable, stable error code.
Present only on a quota-exceeded 403 — the inline upgrade-CTA payload.
object
The entitlement feature key that was hit, e.g. apps.max_count.
The plan’s limit for this key.
Where to send the user to upgrade.
Current usage (count or bytes, per the key).
Human-readable message (the server’s English text; the client may localize
by code).
Example
{ "code": "not_found"}Structured server error
The canonical JSON body of every error response — the single source of truth
the frontend binds to. Every AppError serializes as this exact shape, and
the generated OpenAPI component ApiErrorBody (with its ErrorCode enum) is
what the frontend error schema is generated from, so there is no hand-written
error schema on either end.
object
Machine-readable, stable error code.
Present only on a quota-exceeded 403 — the inline upgrade-CTA payload.
object
The entitlement feature key that was hit, e.g. apps.max_count.
The plan’s limit for this key.
Where to send the user to upgrade.
Current usage (count or bytes, per the key).
Human-readable message (the server’s English text; the client may localize
by code).
Example
{ "code": "not_found"}