object value replacement - Avaya-CXI/virtual-agent-public GitHub Wiki

HOME / REFERENCE DOCUMENTATION / OBJECT VALUE REPLACEMENT

Avaya Virtual agent offers the ability to take data from the Call Context and use some of its values in the following locations:

  • Prompts
  • Conditions
  • Number to Transfer To
  • Caller ID
  • SMS Message for SMS Deflection

The example below shows how to reference Call Context values from inside of prompts. The format is as follows: {{field.subField.subField2}} <-- NO SPACES are allowed in between the curly brackets and the field names. You could include multiple object value replacements in any spot where they are valid to use. Some special names that the Virtual Agent recognizes are DATE as well as null/NULL. These are only used in the Conditions section, but best practice is to avoid menu names named DATE or null or NULL. If the object does not exist or any of the subsequent fields you are referencing do not exist then the value will evaluate to undefined. If you have a field that contains a space in it, you access it like follows {{fulfillmentExample.field[“field with spaces”].anotherField}}. It must be wrapped in double quotes as opposed to single quotes. You can also access elements of an array like such {{fulfillmentExample.myArray[0]}} where the 0 tells the Virtual Agent to take the first element out of the myArray field.

Screen Shot 2021-08-25 at 4 55 51 AM

⚠️ **GitHub.com Fallback** ⚠️