Streaming Intermediate

D-ID's Streaming API creates real-time, interactive talking avatars using WebRTC. Unlike the Talks API which renders videos asynchronously, streaming delivers live video of the animated face with sub-second latency - enabling conversational applications where users interact with a digital human in real time.

How Streaming Works

  1. Create a stream

    POST to /streams to initialize a WebRTC session. D-ID returns an SDP offer and ICE candidates.

  2. Establish WebRTC connection

    Exchange SDP/ICE with D-ID's servers using standard WebRTC APIs in the browser.

  3. Send talk commands

    POST text or audio to the active stream. D-ID renders the face animation in real-time and streams it over WebRTC.

  4. Display the video

    Attach the incoming WebRTC stream to a <video> element. The user sees the avatar speaking live.

Streaming vs. Talks API

FeatureTalks APIStreaming API
Latency30-90 seconds renderSub-second
OutputMP4 fileLive WebRTC video
InteractivityNone (pre-rendered)Full (real-time input)
CostPer video creditPer minute of streaming
Best ForBatch content creationLive conversations, chatbots

Idle Behavior

While not speaking, the streaming avatar displays idle animations: natural blinking, slight head movements, and breathing. This maintains the illusion of a live presence even during pauses in conversation.

Connection Management: WebRTC connections consume resources on D-ID's servers. Set a maximum session duration and implement auto-disconnect after periods of inactivity. Reconnect gracefully when the user returns. Each concurrent stream counts against your plan limits.

Ready to Go Deeper?

Live instructor-led courses from our partners. Affiliate disclosure.