Skip to main content

Dynamic Variables

Using the Variable Picker

The variable picker is a way to specify dynamic variables and use them in your Automation. Blink has different types of dynamic variables and these can be used as standalone expressions, or be combined in a complex expression to create new values. The variable picker enables you to use available variables, even if you are not familiar with the expression language. The variable picker supports all input types.

Types of Dynamic Variables:

VariableType of Automation trigger
MetadataAll
Event payloadEvent-based
StepsAll
Input parametersManual
Local variablesAll
FilesAll
Global variablesAll

Metadata

  • automation_name: the name of the current Automation.
  • automation_url: a link to the current Automation.
  • automation_id: the ID of the Automation.
  • workspace_id: the ID of the workspace associated with the automation.
  • pack_id: the ID of the pack associated with the automation.
  • execution_id: the ID of the current execution.
  • execution_url: a link to the current execution.
  • start_time: the time at which the execution began.
  • user_email: the email of the user who started the execution.
  • user_groups: the groups in which the current user is a member.

Event Payload

The payload with which the Automation was invoked.

Steps

Variables that are related to a specific Step (status, output etc.)

Input Parameters

All the input parameters defined for the Automation.

Local Variables

Variables defined within the Automation using the set variable Action.

Files

File path, size, and identifier for files used in the Automation.

Global Variables

Variables defined within a workspace. Global variables can be Raw value or Secret.

Using Dynamic Variables in an Automation

  1. In the parameter field of your Step, click +. The variable picker is displayed. In the left pane of the variable picker, a list of available dynamic variables such as a Step (status or output) and other metadata appears. These dynamic variables depend on the current Automation and its Steps. The right pane gives you a preview of the current value of the dynamic variable selected. If it currently has no value, the right pane remains empty.

    variable picker

  2. Select the desired variable. The selected variable appears in the headline of the variable picker dialog box. The tag that will be displayed in your Step, appears at the bottom of the box.

  3. Click Submit.
    The dynamic variable appears as a tag in your Step. When the Automation runs the system automatically replaces the tag with the current variable value. If you hover above the tag, the tooltip shows the variable as expression language.

note

please note that in complex use cases when using the same dynamic variable twice but in two separate steps and set with two different value types, the dynamic variable will take they value type of the second value you gave to the variable.

Searching for a Dynamic Variable

  1. In the headline text bar of the variable picker, type and search for a specific variable. The results appear in the left pane.
  2. Select the variable. The selected variable appears in the headline of the variable picker dialog box. The tag that is displayed in your Step appears at the bottom of the box. When selecting a different variable this replaces the selected one.

Referencing a Key in a JSON

The output from a previous Step may be a JSON object. Use the variable picker to select specific keys from the JSON.

  1. In the JSON object output, click the desired key. Its value will copy to the clipboard which allows you to use the specific key-value pair in subsequent steps of your automation.
  2. In order to access the specific key-value pair in your subsequent step press paste from your keyboard or right click with your mouse and click paste.

References

note

If you want to reference a key that contains a dot("."): use square brackets. (Not like other cases with a dot.)

Using Expression Language Functions

The variable picker search bar can include functions from our expression language. Using the expression language you can create a complex expression with multiple variables.