VoiceAgentAPIEvents
Add the following line to your scenario code to use the events:
require(Modules.QwenCloud);
Constants
Contains information about the connector.
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Final ambient audio transcription in smart_turn mode. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#conversation-item-ambient-audio-transcription-completed
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Incremental ambient audio transcription in smart_turn mode. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#conversation-item-ambient-audio-transcription-delta
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
A conversation item was created. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#conversation-item-created
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
A conversation item was deleted. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#conversation-item-deleted
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Final input audio transcription. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#conversation-item-input-audio-transcription-completed
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Incremental input audio transcription. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#conversation-item-input-audio-transcription-delta
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Input audio transcription failed. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#conversation-item-input-audio-transcription-failed
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
A conversation item was retrieved. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#conversation-item-retrieved
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Sent when an error occurs. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#error
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
The input audio buffer was cleared (push-to-talk). https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#input-audio-buffer-cleared
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
The input audio buffer was committed as a user message. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#input-audio-buffer-committed
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
VAD detected the start of speech. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#input-audio-buffer-speech-started
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
VAD detected the end of speech. In smart_turn mode, reason turn_invalid means the turn was rejected. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#input-audio-buffer-speech-stopped
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Assistant audio output finished. Audio bytes arrive as media, not this event. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#response-audio-done
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Incremental assistant caption in audio mode. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#response-audio-transcript-delta
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Assistant caption finished in audio mode. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#response-audio-transcript-done
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
A content part was added to an output item. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#response-content-part-added
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
A content part finished. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#response-content-part-done
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
A model response started. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#response-created
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
A model response finished. status can be completed, cancelled, or failed. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#response-done
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Incremental function-call arguments. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#response-function-call-arguments-delta
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Function-call arguments are complete. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#response-function-call-arguments-done
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
An output item was added to the response. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#response-output-item-added
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
An output item finished. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#response-output-item-done
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Incremental text in text-only mode. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#response-text-delta
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Text output finished in text-only mode. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#response-text-done
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Returned when a session is created. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#session-created
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Returned after session.update is applied. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#session-updated
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
The unknown event.
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Voiceprint enrollment completed. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#voiceprint-audio-list-completed
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Voiceprint enrollment failed. The conversation continues. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#voiceprint-audio-list-failed
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
Voiceprint enrollment started. https://docs.qwencloud.com/api-reference/qwen-audio-realtime/server-events#voiceprint-audio-list-in-progress
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.
The WebSocket error response event.
Parameters
client:
The QwenCloud.VoiceAgentAPIClient instance.
data:
{customEvent: string, payload: Object}
OptionalThe event payload from the connector.