Skip to main content

Lifecycle

The server responds with ready, then text and audio messages as available, and finally end_of_stream. The protocol combines the STT input side (audio in) with the TTS output side (text and audio out). See WebSocket Lifecycle for connection behavior, reusable sockets, browser tokens, and errors.

Client Messages

setup

When using pcm as input format, the input is expected to be at 24kHz using 16 bits little-endian samples. When using pcm as output format, the output is expected to be at 48kHz using 16 bits little-endian samples.

audio

end_of_stream

Server Messages

ready

text

audio

Terminal messages

Error

Headers

x-api-key
string
required

Your Gradium API key

Response

101

WebSocket connection established