API ReferenceAnnouncementsCommunity Discussion
API ReferenceCommunity DiscussionAnnouncementsSubscribeLog In
API Reference

activity_schedule

NameModifier & DefaultsTypeDescription
activity_scheduleN/AActivity Schedule ObjectAllows you to specify a custom schedule for serving your campaign - e.g. specific days and/or specific hours.
{
   "id": "104",
   "advertiser_id": "demo-account",
   // ...   
   "activity_schedule": {
        "mode": "ALWAYS",
        "rules": [],
        "time_zone": "US/Eastern"
    },
   // ...  
}

📘

The above campaign runs '24/7' (default).

{
   "id": "104",
   "advertiser_id": "demo-account",
   // ...   
   "activity_schedule": {
        "mode": "CUSTOM",
        "rules": [
            {
                "type": "INCLUDE",
                "day": "FRIDAY",
                "from_hour": 0,
                "until_hour": 14
            },
            {
                "type": "EXCLUDE",
                "day": "SATURDAY",
                "from_hour": 0,
                "until_hour": 24
            },
            {
                "type": "EXCLUDE",
                "day": "SUNDAY",
                "from_hour": 0,
                "until_hour": 24
            }
        ],
        "time_zone": "US/Eastern"
    },
   // ...  
}

📘

The above campaign...

  • Runs on a Friday until 2 pm (included - with a custom time range).
  • Does not run on a Saturday or Sunday (excluded).
  • Runs all day long on other days (default values for those days that are not specified).

📘

time_zone

To set time_zone to the default value (i.e. the time zone of the account), submit a value of null.