Valid when statements empower you to show the right ads at the right time. They can be used for campaigns, ad groups, and ads, and they work like "if statements": If it's true, the content is enabled; if it's false, it stays disabled. If there's no statement, the campaign, ad group, or ad is automatically enabled. Valid when statements can be used in various ways, but most often with feature flags.
In This Article:
You can use valid when statements for campaigns, ad groups, and ads in Blueprints. Expand the rows below for instructions on navigating to valid when statements in Backpack.
Go to Blueprints in the top menu.
Choose a Blueprint, then a campaign or ad group.
Click Valid When to expose the field.
Go to Blueprints in the top menu.
Choose a Blueprint, then a campaign, ad group, and ad (creative).
In the Creative section, locate the Valid When field.
Valid when statements are made up of elements (e.g., feature flags and tags) and functions that set conditions for enabling the campaign, ad group, or ad.
When using feature flags in valid when statements, the syntax is [Feature Flag Group Name.Flag Name].
Examples (as seen in the screenshot):
[Campaigns.Discovery Test]
[Campaigns.Display Test]
Valid When Functions
Use functions in valid when statements to indicate how the platform should interpret the included tags and feature flags:
AND
OR
EQUALS or =
ENDS WITH
CONTAINS
DOES NOT CONTAIN
DOES NOT EQUAL or !=
GREATER THAN or >
LESS THAN or < (spaces on both sides required)
GREATER THAN OR EQUAL or >=
LESS THAN OR EQUAL or <=
Note: Spaces are required before and after certain signs: =, !=, >, <, >=, <=. For example, [Campaigns.Discovery Test] AND [Campaigns.Display Test]
Use AND to include multiple parameters in the valid when statement.
Example:
[Campaigns.Discovery Test] AND [Campaigns.Display Test]
This valid when statement enables campaigns if both feature flags are toggled on.
Use OR to include both a data source and a feature flag.
Example:
[Campaign Channels] CONTAINS Search OR [Campaign Channels.Search]
This valid when statement enables campaigns if either the data source tag [Campaign Channels] includes Search or if the [Campaign Channels.Search] feature flag is toggled on.
Use CONTAINS with tags to filter for defined variables.
Example:
[OEM Campaign] CONTAINS [inventory.make]
This valid when statement enables campaigns if they contain the specified make(s) in the [inventory.make] tag.