Overview
The Conditions block allows your automation to make decisions and take different paths based on specific conditions. Think of it as adding “if-then” logic to your workflow.Key Uses
Creating Branching Logic
Make your automation take different paths:
- If user is logged in → proceed to dashboard
- If user is not logged in → go to login page
Handling Different Scenarios
Adapt to various situations:
- If item is in stock → add to cart
- If item is out of stock → join waitlist
Making Dynamic Decisions
Respond to real-time conditions:
- If price is below $50 → purchase now
- If price is above $50 → save for later
Validating States
Check conditions before proceeding:
- If form is complete → submit
- If errors exist → show message
Configuration
☐ Description (Optional)
A brief note explaining the purpose of the condition. This is not an AI prompt.Good Example:
"Check if the user is logged in before proceeding."
First Dropdown: Condition Type
This defines what the condition is checking.Category | Dropdown Options | Description | Additional Inputs Required |
---|---|---|---|
Values | Value | Compare a variable or computed value against another value | Value input box |
Code | Execute custom JavaScript code that returns true/false | Code input box + Execution Context selection | |
Data Exists | Check if a specific variable exists in memory | Input box for variable name (e.g., variables@variableName ) | |
Element | Element Text | Check the text content of a specific element | CSS Selector or XPath |
Element Exists | Check if an element is present in the DOM | CSS Selector or XPath | |
Element Not Exists | Check if an element is absent from the DOM | CSS Selector or XPath | |
Element Visible | Check if an element is visible on the page | CSS Selector or XPath | |
Element Visible in Screen | Check if an element is currently visible in the viewport | CSS Selector or XPath | |
Element Hidden in Screen | Check if an element is outside the current viewport | CSS Selector or XPath | |
Element Attribute Value | Check the value of a specific attribute on an element | CSS Selector or XPath + Attribute Name |
Select the appropriate condition type based on whether you’re checking values (like variables or computations) or elements on the webpage.
Second Dropdown: Condition Operator
Defines how the selected value/element is evaluated.Category | Dropdown Options | Description | Additional Inputs Required |
---|---|---|---|
Basic | Equals | Check if values are exactly the same (case insensitive) | Comparison value |
Equals (case sensitive) | Check if values are exactly the same, including letter casing | Comparison value | |
Not Equals | Check if values are different | Comparison value | |
Number | Greater than | Check if value is larger than comparison | Numeric value |
Greater than or equal | Check if value is larger than or equal to comparison | Numeric value | |
Less than | Check if value is smaller than comparison | Numeric value | |
Less than or equal | Check if value is smaller than or equal to comparison | Numeric value | |
Text | Contains | Check if text includes the comparison value | Text value |
Contains (case insensitive) | Check if text includes the comparison value, ignoring case | Text value | |
Not contains | Check if text does not include the comparison value | Text value | |
Not contains (case insensitive) | Check if text does not include the comparison value, ignoring case | Text value | |
Starts with | Check if text begins with the comparison value | Text value | |
Ends with | Check if text ends with the comparison value | Text value | |
Match with RegEx | Check if text matches a regular expression pattern | RegEx pattern | |
Boolean | Is truthy | Check if value evaluates to true | None |
Is falsey | Check if value evaluates to false | None |
Choose the operator that best matches your comparison needs. Basic operators work for simple equality, Number for numerical comparisons, Text for string operations, and Boolean for true/false checks.
Third Dropdown: Comparison Value
Defines what the first value/element is being compared to.Category | Dropdown Options | Description | Additional Inputs Required |
---|---|---|---|
Value | Value | Compare against a manually entered value | Manual value input |
Element | Element Text | Compare against the text content of a specific element | CSS Selector or XPath |
Element Attribute Value | Compare against a specific attribute value of an element | CSS Selector or XPath + Attribute Name |
Select whether you want to compare against a static value you provide or against dynamic content from the webpage (like element text or attributes).
Special Cases
Code Execution
A JavaScript code editor where you can write custom conditions. Choose context:
- Background: API calls, background operations
- Active Tab: DOM manipulation, browser interactions
Must return boolean (true/false)
Data Exists
Checks if a variable exists in memory.Returns true if the variable is found.
Element Attributes
Checks element attribute values using:
- CSS Selector or XPath
- Attribute name (e.g.,
href
,class
,id
,data-*
)Attribute names are case-sensitive
Usage Examples
Basic Conditions
1. Check if User is Logged In
First Dropdown →
Element Exists →
#profile-icon
Second Dropdown →
Is truthy
Checks if profile icon exists in the DOM
2. Check Product Stock Status
First →
Element Text →
#stock-status
Second →
Equals
Third →
“In Stock”
3. Multiple Conditions Example
Condition 1:
Element Text →
#stock-status →
Equals →
“In Stock”
+ AND
Condition 2:
Element Text →
.price →
Less than →
50.00
Multiple Conditions
AND Logic
- Add conditions using “AND”
- All conditions must be true
- Useful for complex validations
OR Logic
- Add conditions using “OR”
- Any condition can be true
- Useful for alternative paths
Notes
- Paths are evaluated in order—first matching path is followed
- Multiple conditions with AND require all conditions to be true
- Multiple conditions with OR require any condition to be true
- Conditions can be nested for complex logic
- Consider using descriptive names for clarity
- Test complex conditions thoroughly
- Verify selectors and attributes before use