Stream a session's telemetry
Streams a session’s telemetry as Server-Sent Events (text/event-stream): every frame of the canonical envelope GET /phones/sessions//frames returns, live as the session runs. Each event’s id is its resume cursor, its event name is the frame kind (span or log), and its data is the frame JSON; live spans arrive as a start frame and then an end frame. A new reader (or one whose cursor is older than the live window) first receives the archived trace and then the live frames, deduplicated on span id and phase, followed by an event with no data that carries the cursor the replay ended at. Reconnect with the Last-Event-ID header (EventSource sends it on its own) to resume with no gap. A comment line is sent every 15 seconds while the stream is idle. After the session ends the stream serves what is left and closes; a reconnect with nothing left after its cursor gets 204, which tells EventSource to stop. Authenticate with the API key header, or open the session’s telemetry_url, which carries a read-only token for this one session (for browsers, which cannot set headers on an EventSource). A session started with telemetry off streams nothing (409). Org-scoped: another org’s session reads as not found. The stream is served by the realtime service: telemetry_url points at its host, and this path on the API host is routed there too. Each event carries exactly one frame. Readers MUST ignore events with an unknown name, unknown fields, and unknown span_type or log_type values.
Authorizations
Customer API key (axl_ prefix).
Headers
Resume after this cursor (the id of the last event received).
Path Parameters
Session whose telemetry to stream.
Query Parameters
Read-only token for this one session, as carried by telemetry_url. Not needed with the API key header.
Response
The event stream. Each event's data is one frame.
- Option 1
- Option 2
One telemetry frame: a completed span or a log event, discriminated on kind. Forward-compatible raw JSON consumers should accept unknown fields within known kinds and treat unknown span_type/log_type values generically. Top-level unknown-kind handling varies by interface and SDK version; do not assume every generated SDK exposes an UnknownFrame variant. Live readers should accept either a single frame object or an array for forward compatibility; current first-party forwarding normally sends one frame object per message.
Frame kind discriminator; always "span" for span frames.
span Span name (for sdk_call spans, the SDK operation, e.g. Screen.observe).
Span phase. The archive returns completed spans only ("end"); "start" phases exist only on the live stream.
Telemetry span ID (16 lowercase hex characters). The live and archived copies of a span use the same ID.
Product span role: session (the session root), run, sdk_call, inference, file_push, media_capture. Spans stored before the 2026-08-21 vocabulary cutover carry the retired phone_session value for the session root. Unknown values MUST be rendered generically, never rejected.
Span start, nanoseconds since the Unix epoch.
Telemetry trace ID (32 lowercase hex characters), derived from the session ID; one session produces one trace.
Every attribute the producer stamped (axilio.* vocabulary), verbatim. Attributes are the contract's extension seam: new keys appear here without a version bump.
Span end, nanoseconds since the Unix epoch. Always set in the archive; omitted on the live stream's "start" phase, where the span is still in flight.
Parent span id; omitted on root spans.
Span outcome. Always set in the archive; omitted on the live stream's "start" phase, where the span has no outcome yet.