Campaign

Basics of the AdUp API

With our AdUp API, you can sit back and automatically transfer all your account data into your preferred BI system.

Overview

With our AdUp API, you can sit back and automatically transfer all your account data into your preferred BI system.

Procedure

In advance

To be able to use the AdUp API, create an access account. To do this, go to Profile in your account or read more in the corresponding support article.

Step 1

Obtain your API login details (e.g. via the frontend).

Step 2

Get an access token from the API via OAUTH.

Step 3

Now use the access token to access the reports route. Have a look at the interactive documentation for this.

Step 4

Then set up your personal API requests. You will find code examples, a description of all fields, as well as notes and links to all possible reports further down in this article. 


Report Request

Code
{
  "report_name": "Test Report",
  "report_type": "CAMPAIGN_PERFORMANCE_REPORT",
  "select": [
    "Month",
    "CampaignName",
    "Clicks"
  ],
  "conditions": [
    {
      "field": "Clicks",
      "operator": "GREATER_THAN",
      "values": [
        "0"
      ]
    }
  ],
  "download_format": "JSON",
  "date_range_type": "LAST_MONTH"

{
  "report_name": "Test Report",
  "report_type": "CAMPAIGN_PERFORMANCE_REPORT",
  "select": [
    "Month",
    "CampaignName",
    "Clicks"
  ],
  "conditions": [
    {
      "field": "Clicks",
      "operator": "GREATER_THAN",
      "values": [
        "0"
      ]
    }
  ],
  "download_format": "JSON",
  "date_range_type": "LAST_MONTH"

{
  "report_name": "Test Report",
  "report_type": "CAMPAIGN_PERFORMANCE_REPORT",
  "select": [
    "Month",
    "CampaignName",
    "Clicks"
  ],
  "conditions": [
    {
      "field": "Clicks",
      "operator": "GREATER_THAN",
      "values": [
        "0"
      ]
    }
  ],
  "download_format": "JSON",
  "date_range_type": "LAST_MONTH"


Field

Description

report_name

User-defined name of the report.

report_type

The report type to be used for the report. See 'API Reports' below

select

List of fields to be displayed in the report. The available fields depend on the report type used. See 'API Reports' below to find out the possible fields.

conditions

List of filters to restrict the rows included in the report. A filter consists of field, operator and values

download_format

Format in which the report is downloaded. Currently only JSON is possible

date_range_type

The date range for which the report should be created. See 'Date ranges' below

date_range

If date_range_type is set to CUSTOM_DATE, this specifies the date range for which the report should be created. See 'Date ranges' below


Notes

Segmentation

To get statistics with a higher level of detail, you can use segmentation.

For example, to get statistics only for mobile devices, you need to filter by device type

In this case, you want to segment your report by DeviceType. For example, if you add the Device field to a Campaign Performance Report, you will get a report with one row for each campaign and device type combination and the statistical values (impressions, clicks, conversions, etc.) split across them. Note that the number of rows can increase exponentially for each additional segment field included in your report.

Implicit segmentation Each report is grouped by a key. For example, the Campaign Performance Report is implicitly segmented by CampaignId.

Rows without metrics

The report may contain rows that do not have values in the metrics. This can be caused by non-deliverable items or items paused within the queried period.

To get rows without metrics, includeZeroImpressions can be set to true (default) in the header. This can be used, for example, to create a structure report that contains all available elements of the account.

However, to reduce the number of rows in the case of many elements without impressions, includeZeroImpressions should be set to false. Alternatively, a filter on metrics in conditions can be used.

Date ranges

For each date_range_type except CUSTOM_DATE, only date_range_type is required.


Date range

Reports are created for...

Example

TODAY

today only


YESTERDAY

yesterday only


LAST_7_DAYS

the last 7 days excluding today


LAST_WEEK

the 7-day period starting from last Monday


LAST_BUSINESS_WEEK

the 5-day business week, Monday to Friday, of the last business week


THIS_MONTH

all days of the current month


LAST_MONTH

all days of last month


ALL_TIME

the entire available period


CUSTOM_DATE

A custom period. See Custom period.


"date_range": {

    "min": "2021-10-29",

    "max": "2021-10-29"

  },

  "date_range_type": "CUSTOM_DATE"
"date_range": {

    "min": "2021-10-29",

    "max": "2021-10-29"

  },

  "date_range_type": "CUSTOM_DATE"
"date_range": {

    "min": "2021-10-29",

    "max": "2021-10-29"

  },

  "date_range_type": "CUSTOM_DATE"

LAST_14_DAYS

the last 14 days excluding today


LAST_30_DAYS

the last 30 days excluding today


THIS_WEEK_SUN_TODAY

the period between last Sunday and today


THIS_WEEK_MON_TODAY

the period between last Monday and today


LAST_WEEK_SUN_SAT

the 7-day period starting with last Sunday



Data Type Micro Amount

Some fields have the data type Micro Amount, these contain e.g. currency values multiplied by a factor of one million (1,000,000).

Example: A value of EUR 123.4567 is displayed in the field as 123456700.



API Reports

We currently offer four different reports that can be individualised and requested via the API.

Account Performance Report (Advertiser) Documentation

Ad Performance Report (Advertiser) Documentation

Campaign Performance Report (Advertiser) Documentation

Direct Placement Performance Report (Advertiser) Documentation

Placement Layout Performance Report (Publisher) Documentation



Other Scopes and Routes

Have you selected other scopes besides reporting in your API access? To get the appropriate routes and information, contact your AdUp representative or write to us at support(at)adup-tech.com​​​​​​​.