Create stream
Create a video inference Stream on the deprecated v0.2 API and get transport connection details; new integrations should use v1.
Authorizations
Provide your API key in the Authorization header as 'Bearer <api_key>'
Body
Create a new video inference stream.
Minimal example (frame mode, native transport):
Clip mode processing config. Samples frames into short video clips for temporal analysis (motion, actions, events).
Provide target_fps directly, or the legacy fps + sampling_ratio pair (not both).
- ClipProcessingConfig
- FrameProcessingConfig
What the AI model should do with the video.
Legacy WebRTC source. Send an SDP offer and receive an SDP answer in the response.
- WebRTCSourceConfig
- LiveKitSourceConfig
- NativeSourceConfig
(Legacy) WebRTC offer. Use source instead.
Processing mode. Auto-detected from processing config if omitted. 'clip' for video clips, 'frame' for single images.
clip, frame Optional client metadata for request tracking.
Response
Stream created. Use stream_id for all subsequent operations.
Returned after successfully creating a stream. Contains connection details specific to the chosen transport.
Unique stream identifier. Use this for keepalive, close, prompt update, and WebSocket connection.
SDP answer for WebRTC sources. Null for native/livekit sources.
Stream lease info including ttl_seconds. Send keepalives before TTL expires.
TURN server credentials for WebRTC sources. Null for native/livekit sources.
LiveKit connection details (url + token) for native sources. Connect to this room to publish video.