Create or Update Trait Rules and Segment Rules

The create and update worksheets accept a traitRule header that lets you apply multiple rules in a single operation. Follow these instructions to make bulk rule requests.

Attention: The Bulk Management Tools are not supported by Audience Manager. This tool is provided for convenience and as a courtesy only. For bulk changes, we recommend that you work with the Audience Manager APIs instead. RBAC group permissions assigned in the Audience Manager UI are honored in the Bulk Management Tools.

Working with trait rules

In your worksheet, the trait rule column returns and accepts rules that consist of Boolean expressions, comparison operators, and regular expressions. You can create rules with trait or segment builder in Audience Manager and copy them to your worksheet. Or, if you're familiar with rule syntax, you can write expressions directly in the worksheets.

Rule builder example

Let's take a look at an example that demonstrates how to use Segment Builder to create a rule you can to the bulk worksheet. However, this isn't a set of step-by-step instructions for those tools. Instead we're going to start with a simple rule that's already been created. For instructions about how to use the rule builders see Segment Builder and Trait Builder.

With the visual rule builder, we've created a segment rule with 3 traits and a Boolean AND operator.

Click Code View to get the text version of this rule.
Tip: Click Validate Expression to check your rule logic. This will help prevent you from uploading an invalid rule.

Paste the rule into the Bulk Management Tools worksheet and commit your changes to update segment rules in bulk.

Creating your own rules

You can write your own rules outside of Rule Builder. Before you start, be sure to read the documentation that covers things like operators, expression, and required variables. We recommend you review the following: