Initialize Session — POST /analyze/live/start
string
Optional hint used to infer the extension.
string
Explicit extension (e.g.,
.wav). Defaults to .mp4.integer
Session lifetime (60-3600). Default 900s.
Response
Upload Chunks — POST /analyze/live/{session_id}/chunk
string
required
Live session identifier from
/analyze/live/start.integer
required
Zero-based, must equal
next_chunk_seq.binary
required
PCM/Opus audio chunks.
received_bytes and updated next_chunk_seq. Out-of-order uploads return 409 Conflict.
Subscribe to Events — GET /analyze/live/{session_id}/events
string
required
Live session identifier.
- Returns the same SSE catalog as
/analyze/stream. - Only one connection allowed; a second call returns
409. - When streaming completes, the session is cleaned up.
Control Session — POST /analyze/live/{session_id}/control
string
required
Live session identifier.
string
required
One of:
finalize, cancel, keepalivestring
Optional reason for the action.
Actions
Payload schema:
status, detail, and new expires_at.
Live Capture Python Cookbook (Async)
Async Python examples using
httpx for implementing live capture workflows with asyncio.Live Capture Python Cookbook (Sync)
Synchronous Python examples using
requests for WSGI apps, Lambda, and non-async environments.