Data API
Fetch your own runs and receipts as JSON — read-only, authorized by your ingest key or session.
Overview
The Data API is a small read-only endpoint for pulling your own runs and receipts as JSON — for CI budget gates, scripts, or your own dashboards. It reads only data you own; it never runs a graph and never touches provider keys.
Base URL (a Supabase edge function):
https://YOUR_PROJECT_REF.functions.supabase.co/runs-apiAuthentication
Send either header:
x-ingest-key: abk_…— your personal ingest key (from Settings → Your ingest key), orAuthorization: Bearer <session-token>— a signed-in dashboard session.
Both resolve to your account, and the API returns only your runs.
List your runs
curl -H "x-ingest-key: $BREAKERBOX_INGEST_KEY" \
"https://YOUR_PROJECT_REF.functions.supabase.co/runs-api?limit=50"{
"runs": [
{
"run_id": "…",
"status": "completed",
"budget_usd": 5.0,
"spent_usd": 1.42,
"saved_usd": 3.1,
"hops": 7,
"updated_at": "…"
}
]
}Query params: limit (default 50, max 200).
Get one run (the receipt)
curl -H "x-ingest-key: $BREAKERBOX_INGEST_KEY" \
"https://YOUR_PROJECT_REF.functions.supabase.co/runs-api?run_id=RUN_ID"{
"run": { "run_id": "…", "status": "killed", "trip_reason": "budget_exceeded" },
"events": [
{ "seq": 0, "type": "reserve", "estimate_microusd": 120000 },
{ "seq": 1, "type": "reconcile", "actual_microusd": 98000 }
]
}Returns 404 if the run is not found or is not yours.
Notes
- Read-only. There is no endpoint that runs a graph or mutates a run. Pausing/killing a live run is a separate control action from the dashboard.
- Deploy it with
supabase functions deploy runs-api.