ConversationHandler interface

Properties

canceled

Event that signals an error with the conversation transcription, or the end of the audio stream has been reached.

sessionStarted

Defines event handler for session started events.

sessionStopped

Defines event handler for session stopped events.

Methods

leaveConversationAsync(Callback, Callback)

Leave the current conversation. After this is called, you will no longer receive any events.

startTranscribingAsync(Callback, Callback)

Starts sending audio to the conversation service for speech recognition and translation. You should subscribe to the Transcribing, and Transcribed events to receive conversation translation results for yourself, and other participants in the conversation.

stopTranscribingAsync(Callback, Callback)

Stops sending audio to the conversation service. You will still receive Transcribing, and and Transcribed events for other participants in the conversation.

Property Details

canceled

Event that signals an error with the conversation transcription, or the end of the audio stream has been reached.

canceled: (sender: ConversationHandler, event: ConversationTranslationCanceledEventArgs) => void

Property Value

(sender: ConversationHandler, event: ConversationTranslationCanceledEventArgs) => void

sessionStarted

Defines event handler for session started events.

sessionStarted: (sender: ConversationHandler, event: SessionEventArgs) => void

Property Value

(sender: ConversationHandler, event: SessionEventArgs) => void

sessionStopped

Defines event handler for session stopped events.

sessionStopped: (sender: ConversationHandler, event: SessionEventArgs) => void

Property Value

(sender: ConversationHandler, event: SessionEventArgs) => void

Method Details

leaveConversationAsync(Callback, Callback)

Leave the current conversation. After this is called, you will no longer receive any events.

function leaveConversationAsync(cb?: Callback, err?: Callback)

Parameters

err
Callback

startTranscribingAsync(Callback, Callback)

Starts sending audio to the conversation service for speech recognition and translation. You should subscribe to the Transcribing, and Transcribed events to receive conversation translation results for yourself, and other participants in the conversation.

function startTranscribingAsync(cb?: Callback, err?: Callback)

Parameters

err
Callback

stopTranscribingAsync(Callback, Callback)

Stops sending audio to the conversation service. You will still receive Transcribing, and and Transcribed events for other participants in the conversation.

function stopTranscribingAsync(cb?: Callback, err?: Callback)

Parameters

err
Callback