API ReferenceAnnouncementsCommunity Discussion
API ReferenceCommunity DiscussionAnnouncementsSubscribeLog In
API Reference

Create a Custom Audience Rule

🚧

display_name

display_name must be unique across all Custom Audience Rules, for a given account.

If you create a new Custom Audience Rule with an existing display_name, the API returns Error 500.

📘

Exclude From ALL Campaigns

To exclude a custom audience by default, set exclude_from_campaigns to true. (Applies to new and existing campaigns.)

You can override this behavior for a given campaign by updating its Custom Audience Targeting to target this audience.

🚧

Network account

You can invoke this endpoint using the network account.
The audience created will be visible to all sub-accounts in the network.


For more detail, see: Network Accounts.

📘

Custom Audiences

To create and manage pixel-based custom audiences, use Backstage API (this topic).

To create and manage CRM-based custom audiences, use Backstage UI.

To target either of the above audiences in a campaign, use Backstage API (Get Custom Audience Targeting and Update Custom Audience Targeting).

{
    "display_name": "Add to cart",
    "look_back_window": null,
    "category": "ADD_TO_CART",
    "status": "ACTIVE",
    "type": "BASIC",
    "event_name": "page_view",
    "condition": {
        "property": "URL",
        "predicate": "CONTAINS",
        "value": "test.com",
        "children": []
    },
    "effects": [
        {
            "type": "REVENUE",
            "data": "15"
        }
    ],
    "include_in_total_conversions": true,
    "exclude_from_campaigns": false,
    "description": null,
    "last_modified_at": null
}
{
    "id": 75,
    "display_name": "Add to cart",
    "look_back_window": null,
    "category": "ADD_TO_CART",
    "status": "ACTIVE",
    "type": "BASIC",
    "event_name": "page_view",
    "condition": {
        "property": "URL",
        "predicate": "CONTAINS",
        "value": "test.com",
        "children": []
    },
    "exclude_from_campaigns": false,
    "description": null,
    "advertiser_id": "demo-advertiser",
    "last_modified_by": "[email protected]",
    "last_modified_at": null,
    "audience_size": 0
}

📘

audience_size

The Customer Audience Rule returned in the response contains an audience_size field.

{
    "look_back_window": null,
    "category": "ADD_TO_CART",
    "status": "ACTIVE",
    "type": "BASIC",
    "event_name": "page_view",
    "condition": {
        "property": "URL",
        "predicate": "CONTAINS",
        "value": "test.com",
        "children": []
    },
    "effects": [
        {
            "type": "REVENUE",
            "data": "15"
        }
    ],
    "include_in_total_conversions": true,
    "exclude_from_campaigns": false,
    "description": null,
    "last_modified_at": null
}
{
    "http_status": 400,
    "message": "Missing required field 'displayName'",
    "offending_field": "display_name"
}
Language
Authorization
OAuth2