The Apply Variables block is a powerful tool for running the same workflow logic across different sets of input data. Instead of creating separate workflows for each input, you define variables once, and the workflow runs automatically for each set.

Purpose

Use the Apply Variables block when you want to:

  • Process a list of items (e.g., search for multiple companies, open several user profiles).
  • Parameterize your workflow (e.g., use different search keywords, test various URLs).
  • Import data from external sources (like CSV) to drive your workflow runs.

This block typically sits at the beginning of a workflow or section where dynamic input is needed.

Configuration

Configuring this block involves setting up a table where columns represent variable names and rows represent the different sets of values for those variables.

  1. Add Columns: Click to add a new column. The column header becomes your variable name (e.g., company_name, search_term, website_url). Variable names should be descriptive and usually contain only letters, numbers, and underscores.
  2. Rows: Each row represents one run of the subsequent workflow steps. Fill in the cells for each row with the specific values for your variables for that run.
  3. Variable Syntax: In subsequent blocks (like Open Websites, Extract Data instructions, Search on Google, etc.), you refer to these variables using double curly braces: {{variable_name}}. For example, if you have a column named company_name, you would use {{company_name}} in another block to insert the value from the current row.
  4. Import (Optional): You can import data directly into this table from a CSV file, which is useful for large datasets. Look for an “Import” button.

[Screenshot: Apply Variables block configuration table with example columns/rows]

Examples

Example 1: Searching for Multiple Companies

  • Apply Variables Block:
    • Column: company_name
    • Row 1: Jsonify
    • Row 2: Google
    • Row 3: Microsoft
  • Search on Google Block (following Apply Variables):
    • Query: {{company_name}} headquarters address
    • Result: The workflow will run three times, searching for the headquarters of Jsonify, Google, and Microsoft respectively.

Example 2: Opening Different Product Pages

  • Apply Variables Block:
    • Column: product_id
    • Row 1: 12345
    • Row 2: 67890
  • Open Websites Block (following Apply Variables):
    • URL: https://yourstore.com/products/{{product_id}}
    • Result: The workflow runs twice, opening the pages for product ID 12345 and 67890.

Key Considerations

  • The workflow steps after the Apply Variables block will execute once for each row defined in the table.
  • Ensure your variable names in the table match exactly how you reference them (including case sensitivity) in other blocks using the {{variable_name}} syntax.

This block is fundamental for scaling your automations and making them reusable across different data inputs.