Once the workflow has been triggered, the parameters are ingested into the events variables and can be used to customize the workflow’s activities.
They can, for example, be used to define which audience to read in the Read audience activity, the name of the file to transfer in the Transfer file activity, etc. (see this page).
Events variables are used within an expression that must respect the Standard syntax.
The syntax to use events variables must follow the format below, and use the parameter’s name that has been defined in the External signal activity (see Declaring the parameters in the External signal activity):
In this syntax, the $ function returns string data type. If you want to specify another type of data, use the following functions:
When using a variable in an activity, the interface provides help to call it.
: select the events variable among all variables that are available in the workflow.
: edit expressions combining variables and functions (see this page).
This list provides functions that allow you to carry out complex filtering. These functions are detailed in this section.
Additionally, you can use the functions below, which are available in all the activities that allow you to use events variables after calling a workflow with external parameters (see this section):
|EndWith||Indicates if a string (1st parameter) ends with a specific string (2nd parameter).||EndWith(<String>,<String>)|
|startWith||Indicates if a string (1st parameter) starts with a specific string (2nd parameter).||startWith(<String>,<String>)|
|Extract||Returns the first characters of a string using a separator.||Extract(<String>,<Separator>)|
|ExtractRight||Returns the last characters of a string using a separator.||ExtractRight(<String>,<Separator>)|
|DateFormat||Formats a date using the format specified in the 2nd parameter (example: ‘%4Y%2M%2D’)||DateFormat(<Date>,<Format>)|
|FileName||Returns the name of a file path.||FileName(<String>)|
|FileExt||Returns the extension of a file path.||FileExt(<String>)|
|IsNull||Indicates if a string or a date is null.||IsNull(<String/date>)|
|UrlUtf8Encode||Encodes an URL in UTF8.||UrlUtf8Encode(<String>)|
Events variables can be used to customize several activities, listed in the section below. For more on how to call a variable from an activity, refer to this section.
Read audience activity: define the audience to target based on events variables. For more on how to use the activity, refer to this section.
Test activity: build conditions based on events variables. For more on how to use the activity, refer to this section.
Transfer file activity: customize the file to transfer based on events variables. For more on how to use the activity, refer to this section.
Query activity: parameters can be referenced in a query, by using expressions combining events variables and functions. To do this, add a rule then click the Advanced mode link to access the expression editing window (see Advanced expression editing).
For more on how to use the activity, refer to this section.
Channels activities: personalize deliveries based on events variables.
The delivery parameters’ values are retrieved each time the delivery is prepared.
Recurring deliveries preparation is based on the delivery aggregation period. For example, if the aggregation period is “by day”, then the delivery will be re-prepared only once a day. If a delivery parameter’s value is modified during the day, then it will not be updated in the delivery, as it has already been prepared once.
If you plan on calling the workflow multiple times a day, use the No aggregation option, so that the delivery parameters are updated each time. For more on recurring deliveries configuration, refer to this section.
To personalize a delivery based on events variables, you must first declare into the delivery activity the variables that you want to use:
Select the activity, then click the button to access the settings.
Select the General tab, then add the events variables that will be available as personalization fields in the delivery.
Click the Confirm button.
Declared events variables are now available from the list of personalization fields. You can use them in the delivery to perform the actions below:
Define the name of the template to use for the delivery.
This action is available for recurring deliveries only.
Personalize the delivery: when selecting a personalization field to configure a delivery, events variables are available in the Workflow parameters element. You can use them as any personalization field, for example to define the delivery subject, the sender etc.
Delivery personalization is detailed in this section.
Segment codes: define the segment code based on events variables.
This action can be performed from any activity that lets you define a segment code like, for example, Query or Segmentation activities.
Delivery label: define the delivery label based on events variables.