Prompt group

Represents a group of related prompts used in the project.

Elements of a prompt group object literal
Element Type Description
id String UUID of the prompt group
name String Name of the prompt group (see Naming guidelines)
prompts Array of prompts Prompts in the prompt group
audioFileId String Name of the audio file to play for the Audio Script modality (maximum 255 characters, see Naming guidelines)—the file extension is determined in the project settings
bargeinDisabled Boolean false if barge-in is enabled for this prompt group (default); otherwise true
lastModified String Date and time of the last modification, in this format: YYYY-MM-DD hh:mm:ssZ—for example, 2019-10-17T20:55:38.488Z
  Prompt group example  

Prompt

Represents a prompt in a prompt group.

Elements of a prompt object literal
Element Type Description
payload Prompt payload object Payload of the prompt
language String Locale of the prompt, as a 4-letter language code (for example, en-US)—refer to Geographies for the list of languages available in the current version of Mix
channel String UUID of the channel
lastModified String Date and time of the last modification, in this format: YYYY-MM-DD hh:mm:ssZ—for example, 2019-10-17T20:55:38.488Z
  Prompt example  

Prompt payload

Represents the payload of a prompt.

Elements of a prompt payload object literal
Element Type Description
displayText String Text to display; the string may include dynamic placeholders in this format: [placeholder text|uuid of a variable], where the variables are listed in the displayTextAnnotations element
ttsText String Text to render using text-to-speech; the string may include dynamic placeholders in this format: [placeholder text|uuid of a variable], where the variables are listed in the ttsTextAnnotations element
audioFile String Deprecated
displayTextAnnotations Array of annotations Dynamic content to include in the text to display
ttsTextAnnotations Array of annotations Dynamic content to render using text-to-speech
ttsAudioBackup String Backup text to render using text-to-speech when the specified audio file is unavailable; the string may include dynamic placeholders in this format: [placeholder text|uuid of a variable], where the variables are listed in the ttsAudioBackupAnnotations element
ttsAudioBackupAnnotations Array of annotations Dynamic content to include in the audio backup text
  Prompt payload example  

Annotation

Represents an dynamic placeholder in a prompt payload.

Elements of a annotation payload object literal
Element Type Description
annotation payload Object Key-value pair representing one of the supported annotation payload types
variableId String Only present if the annotation payload is of type variable; UUID of the variable (or SYS_VAR_channel if using the predefined variable channel)
variableExpressionId String Only present if the annotation payload is of type variableExpression; UUID of the element
type String Controls the validation of output formatting properties, if applicable—possible values include alphaNum, currency, date, digits, cardinalNumber
properties Annotation properties object Display attributes for the annotation, and formatting parameters for the value associated with the annotation
  Annotation example for a simple variable of type string  

Supported annotation payload types

Represents the source of the dynamic value for an annotation.

Dynamic value sources for annotations
Element key Value type Description
variable Variable object Variable that contains dynamic content to include in the message
variableExpression Variable expression object Complex variable field, or the result of a supported method against a variable, to include in the message
conceptId String UUID of the entity that contains dynamic content to include in the message
conceptIdLiteral String UUID of the entity whose literal is to include in the message
conceptIdFormattedLiteral String UUID of the entity whose formatted literal is to include in the message
currentEntity String One of: ENTITY_VALUE, ENTITY_LITERAL, ENTITY_FORMATTED_LITERAL, to include in a global confirmation message—Mix.dialog only supports ENTITY_VALUE (current entity value from the last NLU interpretation result)
Intent String One of: INTENT_VALUE (active intent value), INTENT_LITERAL (active intent literal), INTENT_FORMATTED_LITERAL (formatted version of the active intent literal),INTENT_CONFIDENCE (active intent confidence score), to include in the message

Annotation properties

Represent output formatting properties for the value associated with the annotation. Only string is required, all other elements are optional and depend on the data type. If only string is present, this means that the raw value is to be included in the message.

Properties for annotations
Element Type Description
formType String Determines the format editor to use in Mix.dialog for this annotation—one of: ALPHA_NUM_TYPE, CURRENCY_TYPE, DATE_TYPE, DECIMAL_TYPE, DIGITS_TYPE, DISTANCE_TYPE, CARDINAL_NUMBER_TYPE, TEMPERATURE_TYPE, DISTANCE_TYPE, TIME_TYPE
string String Display text for the placeholder in the message
advanced Boolean true if the advanced format editor is to be used in Mix.dialog for this annotation—only for date and time values (in Rich Text messages), and alphanumeric and digits (all message formats)—otherwise, false (default)
pattern String Pattern string to format the value in the message—only for date and time values (in Rich Text messages), and alphanumeric and digits (all message formats)
thousandSeparator Boolean Rich Text only, for amount, decimal, distance, integer, and temperature values: true (default) to show the value with the applicable thousands separator; otherwise, false
playZeroDollars Boolean Amount recorded audio playback only: true (default) to play “zero dollars” (in the session language), when the number of dollars (or selected currency) is zero; otherwise, false
playZeroCents Boolean Amount TTS and recorded audio playback only: true (default) to play “zero cents” (in the session language), when the number of cents (or sub-unit for the selected currency) is zero; otherwise, false
playPrehundred Boolean English (United States) recorded audio playback only, for amount values: true to use different audio recordings for hundreds prior to millions/thousands, and for hundreds prior to tens; false (default) to use the same audio recording for hundreds regardless of their position in amounts
currency String For display purposes only: currency to show on the annotation in Mix.dialog—at runtime (and in preview) the currency is part of the value
partsOfDate String Specifies which parts to play for a date, and the order—examples: mdy to play something like “February 17, 2021”, or my to play something like “August 2023”
playDayOfTheWeek Boolean true to display or play the day of the week (for example, “Sunday”); otherwise, false (default)—only for date values
partsOfTime String For TTS playback only; not exposed in Mix.dialog: Specifies which parts to play for a time value, and the order—default is hms
clock24 String Hour format to use: 12 (default), or 24
decimalPlaces String Number of decimal places to show (0–7, default: 2)—only for decimal, distance, and temperature values
playZeroUnits Boolean Decimal recorded audio playback only: true (default) to play “zero point” (in the session language), when the value is zero; otherwise, false
playZeroDecimals Boolean Decimal TTS and recorded audio playback only: true (default) to play “point zero cents” (in the session language), when the value is zero; otherwise, false
distanceType String For display purposes only: Unit of distance to show on the annotation in Mix.dialog (km, m, cm, mm, mi, yd, ft, in)—at runtime (and in preview) the unit of distance is part of the value
tempType String For display purposes only: Unit of temperature to show on the annotation in Mix.dialog (C, F, K)—at runtime (and in preview) the unit of temperature is part of the value
intonation String Recorded audio playback only: intonation to use for the value in the message: medial (default), or final
case String German recorded audio playback only, for amount, date, and decimal values—Grammatical case to use for the value in the message: nominative (default), or dative
forceTTS Boolean Audio Script message only: true for TTS-formatted annotation (default for languages that don’t support dynamic concatenated audio); false (or empty) for dynamic concatenated audio-formatted annotation
ssmlOpenFreeform String String value in TTS or Audio Script message only: SSML tag to use for TTS playback
ssmlCloseFreeform String String value in TTS or Audio Script message only: Closing tag for ssmlOpenFreeform
  Annotation properties example to format a date value for German recorded audio playback  
  Annotation properties example to format a string value as a phone number for TTS playback