The Trace object
A compact record persisted for every request through the gateway. Traces are read-only — the gateway writes them; the API serves them. See Traces & payloads for the full picture.
Attributes
request_id
string
Stable id used across response metadata, trace records, and payload archives.
organization_id
string
Owning organisation for the request.
api_key_id
string
Resolved caller key id.
provider
string
Final upstream provider selected for the call.
model
string
Final upstream model selected for the call.
requested_model
string
Model alias or string the caller originally sent.
route_reason
string
default or rule:<name>.latency_ms
integer
End-to-end latency measured by routeur.ai.
prompt_tokens / completion_tokens / total_tokens
integer
Usage metrics returned by the upstream provider.
cost_usd
number
Estimate from the configured pricing table.
status_code
integer
Caller-visible HTTP status code.
redactions
integer
Number of input substitutions DLP made before the upstream call.
streamed
boolean
True when the response was delivered as a server-sent event stream.
ttfb_ms
number
Time to first byte — ms from request start until the first response byte left the gateway. Streamed requests only.
stream_aborted
boolean
True when a stream was cut after delivery began — a mid-stream upstream failure, a client disconnect, or a chunked output-moderation block.
disclosed_bytes
integer
Bytes of model output that had already reached the caller when a chunked-moderation block aborted the stream (ADR-011 disclosure trade-off).
payload_url
string
Short-lived signed URL to the full payload archive when payload storage is enabled.