Pausing/unpausing Campaign Items

To pause (or unpause) an Item, update the Item, and set is_active to false (or true).

Pausing a campaign item

To pause an Item (i.e. prevent it from being served), set is_active to false:

{
    "is_active" : false
}
{
    "id"             : "3",
    "campaign_id"    : "124",
    "type"           : "ITEM",
    "url"            : "http://news.example.com/demo_article.html",
    "thumbnail_url"  : "http://cdn.example.com/demo_image.jpg",
    "title"          : "Updated Title",
    "approval_state" : "APPROVED",
    "is_active"      : false,
    "status"         : "PAUSED"
}

πŸ“˜

Pausing an Item

By setting is_active to false, you can:

  • Pause an active Item immediately.
  • Flag a pending Item to pause upon approval.

For a detailed description of the business logic, see below.

πŸ“˜

Setting is_active to false

Setting is_active to false, updates the read-only status field.

If status = RUNNING:

Setting is_active to false changes status to PAUSED.

If status = PENDING_APPROVAL:

Setting is_active to false does not change the status (immediately).
However, upon approval, status will be set to PAUSED.

Unpausing (resuming) a campaign item

To unpause an Item, set is_active to true:

{
    "is_active" : true
}
{
    "id"             : "3",
    "campaign_id"    : "124",
    "type"           : "ITEM",
    "url"            : "http://news.example.com/demo_article.html",
    "thumbnail_url"  : "http://cdn.example.com/demo_image.jpg",
    "title"          : "Updated Title",
    "approval_state" : "APPROVED",
    "is_active"      : true,
    "status"         : "RUNNING"
}

πŸ“˜

Unpausing an Item

By setting is_active to true, you can:

  • Resume an active Item immediately.
  • Flag a pending Item to run upon approval.

For a detailed description of the business logic, see below.

πŸ“˜

Setting is_active to true

Setting is_active to true, updates the read-only status field.

If status = PAUSED:

Setting is_active to true changes status to RUNNING.

If status = PENDING_APPROVAL:

Setting is_active to true does not change the status (immediately).
However, upon approval, status will be set to RUNNING.