Skip to content

SDK & REST ingestion

Pasting a trace into the playground is great for a one-off. To catch silent failures continuously, send your runs to Lumni as they finish. Every ingested run is normalized and passed through all five detectors automatically.

Ingestion is authenticated with a per-tenant API key sent as a bearer token. Keep it server-side.

Terminal window
export LUMNI_API_KEY="sk_live_…"

The core endpoint is POST /v1/ingest/runs. A run is the full execution plus its ordered steps.

POST /v1/ingest/runs
curl -sS https://agentf.lumniverse.com/v1/ingest/runs \
-H "authorization: Bearer $LUMNI_API_KEY" \
-H 'content-type: application/json' \
-d '{
"userRequestText": "Refund my last order",
"success": true,
"outcomeSummary": "Your refund has been processed.",
"metadata": { "model": "gpt-4o", "costUsd": 0.021 },
"steps": [
{
"stepKind": "tool",
"stepName": "issue_refund",
"status": "failed",
"errorMessage": "502 Bad Gateway",
"inputSummary": "{ order_id: 8842 }"
},
{
"stepKind": "model",
"outputSummary": "Your refund has been processed."
}
]
}'

The run above trips the False Success detector: a tool failed, but the final message claimed the refund went through.

You don’t need to capture everything, but the more of these you send, the sharper the detectors get:

  1. userRequestText — powers Missing Tool Call (did the agent do the verb the user asked for?).

  2. Step status / errorCode / errorMessage — the failure signal for False Success and loop detection.

  3. stepKind — so Lumni can tell tool steps from model steps.

  4. retryCount and repeated tool calls with the same inputSummary — feeds Expensive Loop.

  5. metadata.model and metadata.inputTokens — feeds Context Overflow.

  6. metadata.costUsd — lets Lumni estimate wasted spend on runaway loops.