Using Custom Properties in Workflows

A powerful feature of Formulas is the ability to use the dynamic values calculated by your let statements directly in the Actions of your Workflows. This allows automation steps like bid or budget changes to adapt precisely to the data of each individual item in your Segment.

Connecting Calculations to Actions

Recall that defining a variable with let in the Composer (e.g., let new_bid = ...;) also creates a corresponding Custom Property column in your Segment results. The values in this column can then be used to drive actions.

How It Works

1. Define in Formula

Create one or more let statements in your Formula to calculate the desired value(s) you want to use in an action. These become your variables internally and Custom Properties in the output.

// Example: Define a calculated bid
let calculated_bid = case(
   acos(14d) < 25% => cpc(14d) * 1.15,    // Increase bid by 15%
   else bid * 0.9                         // Decrease others by 10%
);

// Filter for active items
state = "effectively enabled" and calculated_bid != 0

2. Configure Workflow Action

When setting up the Action for your Workflow (e.g., attached to the Segment created by the formula above):

  1. Choose the Action type (e.g., Change Bid).
  2. Select the operation (e.g., Set ($)).
  3. Choose the from variable option in the value input/dropdown.
  4. From the subsequent dropdown, select the variable name you defined using let (e.g., calculated_bid).

3. Execution

When the Workflow runs:

  1. The Formula generates the Segment.
  2. A "Calculated Bid" Custom Property column with a specific value for each item (e.g., Target A might have $0.24, Target B might have $0.28).
  3. For Change Bid actions, a "Bid Preview" system property column is generated showing what the bid will be changed to.
  4. The "Change Bid" action executes for each item in the Segment to the value shown in the "Bid Preview".
  5. For Target A, it sets the bid to $0.24 (the value from its "Bid Preview" column).
  6. For Target B, it sets the bid to $0.24 (the value from its "Bid Preview" column).

Benefits

  • Dynamic & Precise: Actions are tailored to each item's specific calculated value, not just fixed increments or values.
  • Sophisticated Automation: Enables complex automation rules where the action taken depends directly on calculated performance or derived metrics.
  • Centralized Logic: Keeps the calculation logic within the Formula, making the Action setup cleaner and focused on which value to use.

By linking let variables (which generate Custom Properties) to Workflow Actions, you unlock truly dynamic and intelligent automation possibilities.

PREVIOUS ARTICLE
NEXT ARTICLE