This topic describes the events that the server sends to the client during a WebSocket session with the Qwen-ASR-Realtime API.
error
Sent when the server detects a client or server error.
|
session.created
Sent first after successful connection. Contains default session configurations.
|
session.updated
Sent after successfully processing the client's session.update event. On error, an error event is sent instead.
|
input_audio_buffer.speech_started
Sent in VAD mode when speech starts in the audio buffer.
Can occur each time audio is added to the buffer, unless speech start has been detected.
|
input_audio_buffer.speech_stopped
Sent in VAD mode when speech ends in the audio buffer.
After this event, the server immediately sends a conversation.item.created event containing the user message item created from the audio buffer.
|
input_audio_buffer.committed
- VAD mode: Sent after the client sends audio data via input_audio_buffer.append event.
- Manual mode: Sent after the client sends audio data via input_audio_buffer.append event, then sends input_audio_buffer.commit event.
|
conversation.item.created
Sent when a new conversation item is created.
|
conversation.item.input_audio_transcription.text
Sent frequently with real-time recognition results.
| text + stash.
Click to view an example For example, assume a user says, "The weather is nice today, sunny and bright."The following table shows the event stream you might receive and explains how to interpret it:
|
conversation.item.input_audio_transcription.completed
Sends the final recognition result, marking the end of a conversation item.
|
conversation.item.input_audio_transcription.failed
Sent when input audio recognition fails. Handled separately from other error events to identify the specific failed item.
|
session.finished
Session finished; all audio recognition complete.
Sent after the client sends session.finish event. Client can disconnect after receiving this.
|