API ReferenceAnnouncementsCommunity Discussion
API ReferenceCommunity DiscussionAnnouncementsSubscribeLog In
API Reference

Create a Conversion Rule

Submit a JSON object representing the new Conversion Rule in the request body. (See examples below.)

Returns the newly created Conversion Rule in the response body.

{
   "display_name": "Add to cart",
   "category": "ADD_TO_CART",
   "status": "ACTIVE",
   "type": "BASIC",
   "condition": {
      "property": "URL",
      "predicate": "CONTAINS",
      "value": "test.com",
      "children": []
   },
   "effects": [
      {
         "type": "REVENUE",
         "data": "15"
      }
   ],
   "include_in_total_conversions": true
}
{
    "id": 78,
    "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,
    "advertiser_id": "rsschecking",
    "last_modified_by": "[email protected]",
    "last_modified_at": null
}

🚧

display_name

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

If you create a new Conversion Rule - with the same display_name as an existing one - the server returns Error 500.

{
   "id": null,
   "display_name": null,
   "category": "ADD_TO_CART",
   "status": "ACTIVE",
   "type": "BASIC",
   "condition": {
      "property": "URL",
      "predicate": "CONTAINS",
      "value": "test.com",
      "children": []
   }
}
{
    "http_status": 400,
    "message": "Missing required field 'displayName'",
    "offending_field": "display_name"
}
Language
Credentials
OAuth2