VoiceMessages APIs
-
VOICE_ALERT_PROFILE[] to String Helper Function
Description: Retrieves the text content for the given profile in the given language.Usage:
POST api/Messages/Voice/Helpers/VoiceContentProfileArrayToText/{SpokenLanguage}/{ItemType}
Parameter Type Source Description SpokenLanguage String FromUri The language to get the content for from the profile ItemType String FromUri The voice item type to get the content for Value Description alert_human The main alert message. The message will be sent to the person who answers the phone call. alert_answering_machine A message that will only be sent to answering machines or voice-mail alert_response_confirm A custom response message that is played when confirming the reciept of digits. (i.e. Response Confirmed) alert_ask_for_pin A custom message that asks the called-party to key in a pin code. (i.e. Please enter your pin code followed by the # key) alert_invalid_pin A custom message that is played to indicate that the pin code entered was invalid. (i.e. the pin code you entered was invalid.) alert_feedback_recording_begin A custom message that plays after a response is keyed to begin recording audio during a voice feedback message ContentProfile VOICE_ALERT_PROFILE[] FromBody The VOICE_ALERT_PROFILE array that contains the current content Returns:
Returns a string containing the textual content of the message including auto-fields if used.
Examples:
<!-- Intent: takes the given array of VOICE_ALERT_PROFILE objects and returns the text content for the specified language. POST to the following url http://api.v4.swiftreach.com/api/Messages/Voice/Helpers/VoiceContentProfileArrayToText/English/alert_human --> <ArrayOfVOICE_ALERT_PROFILE xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"> <VOICE_ALERT_PROFILE> <SpokenLanguage>English</SpokenLanguage> <TTY_Text>this is the TTY message</TTY_Text> <VoiceItem> <VOICE_ALERT_CONTENT> <VoiceItemType>alert_human</VoiceItemType> <AudioSource> <AUDIO_SOURCE xsi:type="AUDIO_SOURCE_TTS_TEXT"> <AudioType>audio_source_tts_text</AudioType> <TTSText>This is the message.</TTSText> </AUDIO_SOURCE> </AudioSource> </VOICE_ALERT_CONTENT> </VoiceItem> </VOICE_ALERT_PROFILE> </ArrayOfVOICE_ALERT_PROFILE> <!-- example return value --> <TextContent>This is the message.</TextContent>