DialVoiceRelayOptions

data class DialVoiceRelayOptions @JvmOverloads constructor(val ttsVoice: String, val sttLanguage: String, val serviceId: String? = null, val enableInterruptions: Boolean? = null, val callHeaders: Map<String, String>? = null)

Options for dialing a Voice Relay endpoint through the Sinch Voice V2 platform.

Voice Relay connects the call to speech-to-text (STT) and text-to-speech (TTS) services through a WebSocket endpoint. A null optional property is omitted from the dial request and the Voice V2 platform applies its default.

See Voice locales for the available voices and locales.

Parameters

ttsVoice

Name of the voice used for speech synthesis, for example Emma. Must not be empty.

sttLanguage

BCP 47 language tag used to transcribe inbound audio, for example en-US. Must not be empty.

serviceId

Voice V2 service ID to use for the dial. If null, the project's default service is used.

enableInterruptions

Whether callers can interrupt, or barge in on, TTS playback.

callHeaders

Custom headers included in the destination call setup. If null, no custom headers are included. At most 16 headers; each key must be 1 to 255 characters, and each value at most 255 characters.

Constructors

Link copied to clipboard
constructor(ttsVoice: String, sttLanguage: String, serviceId: String? = null, enableInterruptions: Boolean? = null, callHeaders: Map<String, String>? = null)

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard