Assigning Values to Variables in a Flow

Use the Assign object to define an attribute's name and value in your flow. For example, you can name and provide a value to a caller based on the digits that they pressed in a Collect Digits object. By using Assign, you can set a value that is meaningful for your flow so you can refer to it in conditions later in the same flow. The Assign Global object has the same function, but also applies to variables within sub flows.

  • Name: This is the label or name for your variable. You can name your variable what you want, but you must enter it the exact same way anytime you use it in a condition later in your flow.
  • Value: This is the value you are assigning to the corresponding name. For example, you might enter values such as:
    • True
    • False
    • A number
    • A string, such as digits pressed
If the value is a string such as true, false, or a digit pressed, surround the value in quotation marks. If it is not a string, such as another variable or a number, don't enter the value with quotation marks.

Referencing Assigned Values in a Flow

With the Assign object, attributes can be referred to in the same portion of the flow as they were defined in. For example, if an attribute is defined with the Assign object in the caller's portion of a flow, it cannot be referenced in a separate sub-flow for the agent's portion unless you define it again.

With the Assign Global object, defined attributes can be referred to anywhere within the main flow and sub-flows.


You might also be interested in: