ServiceBoundMessage (client to server) or ClientBoundMessage (server to client).
Messages are binary-encoded protobuf. JSON examples below are shown for readability. Download the proto file.
This endpoint runs pure VAD — it does not perform LLM inference, TTS synthesis, or transcription. Use it when you only need speech activity events and want to drive your own processing pipeline downstream. For the full conversational AI pipeline, see the Opal WebSocket Protocol.
Connection
Client Messages
Messages sent from client to server, wrapped inServiceBoundMessage.
InitializeSessionRequest
InitializeSessionRequest
Must be the first message sent. Configures the audio input format and VAD parameters.
Inference, TTS, and playback reporting fields from the full realtime protocol are not used here and will be ignored if present.
ReconfigureSessionRequest
ReconfigureSessionRequest
Reconfigure the input audio format of an ongoing session.
UserInput
UserInput
Raw PCM audio input for VAD processing. Only audio data is accepted — text input and inference trigger modes are not supported on this endpoint.
Server Messages
Messages sent from server to client, wrapped inClientBoundMessage.
SessionReady
SessionReady
Sent once the session is fully initialized and ready to accept audio input. Wait for this message before sending
UserInput.VadStateEvent
VadStateEvent
Emitted on every VAD state-machine transition. Always sent, regardless of whether
enable_vad_frame_telemetry is set.VadAnalysisFrame
VadAnalysisFrame
Per-frame VAD telemetry, emitted at ~50 Hz (20 ms frames on 16 kHz audio). Only sent when
enable_vad_frame_telemetry: true was set in InitializeSessionRequest.Frame indexing is monotonic per session and reflects the post-resampling frame stream that the VAD engine actually processes.SessionErrorNotification
SessionErrorNotification
Structured error notification sent before the server closes the connection.
Type Definitions
AudioLineConfiguration
SampleFormat
VadConfiguration
Voice Activity Detection settings.VadState
The VAD pipeline is a debounced state machine. Rather than emitting a transition on every raw frame, the engine appliesstart_duration and stop_duration windows to smooth out transient noise and brief pauses before committing to a new state. A frame is considered above threshold when both confidence ≥ confidence_threshold AND volume ≥ min_volume; both conditions must hold simultaneously.
SILENCE — The initial state. The engine is processing audio but no speech onset has been detected. Frames are evaluated every ~20 ms; the machine stays here until it sees a frame that clears both confidence_threshold and min_volume.
SPEECH_STARTING — A potential speech onset has been detected: at least one frame exceeded both thresholds. The machine enters this state and starts the start_duration debounce timer. This window guards against brief noise bursts or transient spikes being misclassified as speech. Two outcomes are possible:
- If frames remain above threshold continuously for the full
start_duration, the machine advances toSPEECH. - If any frame drops below threshold before
start_durationelapses, the machine returns toSILENCEimmediately — the onset is treated as a false positive.
SPEECH — Active speech is confirmed. The machine entered here after sustained above-threshold audio lasting at least start_duration. Audio is considered live speech until the engine sees a frame that drops below threshold, at which point the machine moves to SPEECH_ENDING.
SPEECH_ENDING — A potential speech offset has been detected: a frame dropped below threshold while in SPEECH. The stop_duration debounce timer starts. This window prevents brief pauses — breaths, hesitations, word gaps — from prematurely ending a speech segment. Two outcomes are possible:
- If any frame returns above threshold before
stop_durationelapses, the machine snaps back toSPEECH, continuing the same segment. - If frames remain below threshold for the full
stop_duration, the machine transitions toSILENCEand the speech segment is considered complete.
Duration
SessionErrorCategory
Session Lifecycle
A typical VAD session follows this sequence:If
enable_vad_frame_telemetry is true, VadAnalysisFrame messages are interleaved continuously between state events at ~50 Hz.