With Advanced Variable Options, you can create advanced logic using variable names and options to generate tasks based on the variables selected on Map creation.
This is an advanced feature that we have to activate in your account. If you would like access to advanced variable logic, contact us at support@onboard.io.
Setting Up Advanced Variable Options
The Advanced variable options field uses a special syntax called RQL (Resource Query Language).
To use it, you specify operators, and the Variable name and value you want to create the condition for.
ex. eq(Variable Name,Value) which checks if Variable Name is equal to a Value.
The parantheses determine the logic and specify which values to compare.
When using and/or operators, you will combine them to include all the conditions you want inside the parantheses. ex. and(eq(Variable A, Value), eq(Variable B, Value))
- The Variable name should match exactly what you have set in your variables https://app.onboard.io/variables/
- The Variable value should match one of the options of that specific Variable.
Operators
List of common operators and syntax to use:
Operator | Description | Example |
and | all of the conditions are true | and(eq(Plan,Starter),eq(Customer Type,New)) |
or | any of the conditions are true | or(eq(Plan,Starter),eq(Customer Type,New)) |
eq | equal, used to check if a variable is equal to a specific value | eq(Plan,Starter) |
ne | not equal, used to check if a variable is NOT equal to a specific value | ne(Plan,Starter) |
contains |
used to see if a multi-select variable contains a specific value | contains(Multiselect,New) |
excludes | used to see if a multi-select variable does not contain a specific value | excludes(Multiselect,New) |
When using Multi-select variables, use "contains" and "excludes" since they can have a list of multiple values.
Examples
Example: You have a variable Customer Type, and want a task to be generated only if the Customer Type is either New or Trial, you would use the "or" and "eq" operators.
or(eq(Customer Type,New),eq(Customer Type,Trial)
Example: You have a variable Customer Type and a multi-select variable Integrations and want a task to be triggered for New Customer Type and if Integrations includes Onboard or Hubspot
and(eq(Customer Type,New),or(contains(Integrations,Onboard),contains(Integrations,Hubspot))