checkCampaigns

Informs you of changes in the client's campaigns starting from the specified date.

  1. Request
  2. Response
  3. Examples

Request

Request structure in JSON format:

{
  "method": "checkCampaigns",
  "params": { /* params */
    "Timestamp": (string) /* required */
  } 
}
ParameterTypeDescriptionRequired
Params structure (for JSON) / CheckCampaignsRequest structure (for SOAP)
TimestampstringThe exact time to start from to check for changes. Specified in the format YYYY-MM-DDThh:mm:ssZ (conforming to ISO 8601), such as 2015-05-24T23:59:59Z.Yes

Response

Response structure in JSON format:

{
  "result": { /* result */
    "Campaigns": [{  /* CampaignChangesItem */
      "CampaignId": (long), /* required */
      "ChangesIn": [( "SELF" | "CHILDREN" | "STAT" ), ... ] /* required */ 
    }, ... ],
    "Timestamp": (string) /* required */
  }
}
ParameterTypeDescription
Result structure (for JSON) / CheckCampaignsResponse structure (for SOAP)
Campaignsarray of CampaignChangesItem

Campaigns where changes were made.

TimestampstringThe exact time when changes were checked. Specified in the format YYYY-MM-DDThh:mm:ssZ (conforming to ISO 8601), such as 2015-05-24T23:59:59Z. The timestamp is specified in the next method call, to check for changes starting from this time.
CampaignChangesItem structure
CampaignIdlongThe campaign ID.
ChangesInarray of CampaignChangesInEnum

Where exactly the changes occurred:

  • SELF — In campaign parameters.
  • CHILDREN — In child objects: groups, ads, or keywords.
  • STAT — Corrected campaign statistics (usually related to filtering out false clicks).

Examples

Checking for changes in campaigns starting from 02.02.2015 10:08:22 UTC
{
  "method": "checkCampaigns",
  "params": {
    "Timestamp": "2015-02-02T10:08:22Z"
  }
}
Response
{
  "result": {
    "Campaigns": [{
      "CampaignId": 13243,
      "ChangesIn": ["SELF"]
    },
    {
      "CampaignId": 13326,
      "ChangesIn": ["SELF","CHILDREN"]
    },
    {
      "CampaignId": 14742,
      "ChangesIn": ["CHILDREN"]
    }],
    "Timestamp": "2015-02-02T12:24:31Z"
  }
}

Changes were made in three campaigns: campaign parameters changed in two of them, and child objects changed in two of them.