Revenue Methods
The Revenue API for News Publishers methods described in this document provides programmatic access to the iAd ad server to do the same kinds of tasks as you would do with the iAd Workbench for News Publishers:
GetChannelMetrics
— Obtain revenue performance metrics by channel.GetChannelMetricsByCreativeType
— Obtain revenue performance metrics by creative (ad) type.
Obtaining Reporting Metrics
When requesting data, be aware of the following:
You can request data for the following intervals within past 12 months:
Hourly: one day only.
Daily: up to 7 consecutive days.
GetChannelMetrics
This method allows you to get Revenue, Supply, Fill Rate, Impressions, and Taps by:
Channel
Date
Country
Device type
GetChannelMetrics Input Parameters
Parameter | Type | Required / Optional | Comments |
---|---|---|---|
| String (Alphanumeric) | Required | Session ID obtained from InitSession call. |
| List of Strings | Required | List of full UUIDs (not minified) of up to 10 channels. These are the UUIDs returned by the News Campaign API method |
| String (date) | Required | Start date of report period, formatted as yyyy-mm-dd. |
| String (date) | Required | End date of report period, formatted as yyyy-mm-dd. |
| String | Optional | Must be either |
| String | Required | Must be either |
Listing 4-1 GetChannelMetrics Sample Input
{ |
"method":"GetChannelMetrics", |
"id":"1001", |
"params":{ |
"SessionId":"04df16280af800092be3d638c28db00666164f36", |
"ChannelIds":[ |
"9ae04346-233b-445f-8466-26d708a16ec1], |
"StartTime":"2015-12-08", |
"EndTime":"2015-12-09", |
"Interval":"Daily" |
}, |
"jsonrpc":"2.0" |
} |
GetChannelMetrics Output Parameters
Parameter | Type | Comments |
---|---|---|
| Collection | Collection of revenue metrics parameters and values. |
| String | Full channel UUID for each channel output returned. |
| String | Channel name for each channel output returned. |
| String | Two-character country code, “AU”, “GB”, or “US”. |
| String | All potential Ad positions. |
| String | Type of device. The only device types are |
| String | For For |
| String | Will be either |
| String | Number of times users have tapped on ads. |
| String | Estimated revenue per thousand clicks. |
| String | Number of times that iAd backfill ads appeared in your channels. |
| String | Number of times that direct-sold ads appeared in your channels. |
| String | Number of times that in-house ads appeared in your channels. |
| String | Tap-through rate. |
| String | Revenue from iAd backfill ads displayed. |
| String | The number of ad requests that are eligible for ads. Some ad requests might be ineligible for a variety of reasons. Supply is an indication of the maximum number of ad impressions that could have been delivered during the reporting time period.. |
| String | The ratio of total impressions to the total supply, in percent. |
| Boolean |
|
Listing 4-2 GetChannelMetrics Sample Output
{ |
"id": "1001", |
"jsonrpc": "2.0", |
"result": |
{ |
"Metrics": |
[ |
{ |
"ChannelId": "9ae04346-233b-445f-8466-26d708a16ec1", |
"ChannelName": "GQ", |
"Country": "US", |
"DeviceClass": "iPhone", |
"DateTime": "2015-12-08 00:00:00", |
"Taps": "1", |
"eCPM": "0.00", |
"iAdImpressions": "0", |
"TTR": "1429.00", |
"Revenue": "0.00", |
"Supply": "7", |
"FillRate": "100.00", |
"DirectSoldImpressions": "0", |
"HouseImpressions": "0", |
"AdPosition": "In Feed" |
} |
], |
"Success": true |
} |
} |
GetChannelMetricsByCreativeType
This method allows you to get Revenue, Impressions, and Taps by:
Channel
Date
Creative type
Note that the input parameters are the same as GetChannelMetrics
. The difference in the method name provides a different set of output.
GetChannelMetricsByCreativeType Input Parameters
Parameter | Type | Required / Optional | Comments |
---|---|---|---|
| String (Alphanumeric) | Required | Session ID obtained from InitSession call. |
| List of Strings | Required | List of full UUIDs (not minified) of up to 10 channels. These are the UUIDs returned by the News Campaign API method |
| String (date) | Required | Start date of report period, formatted as yyyy-mm-dd. |
| String (date) | Required | End date of report period, formatted as yyyy-mm-dd. |
| String | Optional | Must be either |
| String | Required | Must be either |
Listing 4-3 GetChannelMetricsByCreativeType Sample Input
{ |
"method":"GetChannelMetricsByCreativeType", |
"id":"1001", |
"params":{ |
"SessionId":"faffb41b6ab628ea8998a77af1d9b8ae694f107a", |
"ChannelIds":[ |
"9ae04346-233b-445f-8466-26d708a16ec1" |
], |
"StartTime":"2015-12-09", |
"EndTime":"2015-12-0", |
"Interval":"Daily" |
}, |
"jsonrpc":"2.0" |
} |
GetChannelMetricsByCreativeType Output Parameters
Parameter | Type | Comments |
---|---|---|
| Collection | Collection of revenue metrics parameters and values. |
| String | Full channel UUID for each channel output returned. |
| String | Channel name for each channel output returned. |
| String | Two-character country code, “AU”, “GB”, or “US”. |
| String | All potential ad positions. |
| String | Type of device. The only device types are |
| String | A different |
| String | For hourly, the value will be the date and hour: yyyy-mm-dd hh:mm For daily, the value is the date: yyyy-mm-dd hh:mm |
| String | Will be either |
| String | Number of times users have tapped on ads. |
| String | Estimated revenue per thousand clicks. |
| String | Number of times that iAd backfill ads appeared in your channels. |
| String | Number of times that direct-sold ads appeared in your channels. |
| String | Number of times that in-house ads appeared in your channels. |
| String | Tap-through rate. |
| String | Revenue from iAd backfill ads displayed. |
| Boolean |
|
Listing 4-4 GetChannelMetricsByCreativeType Sample Output
{ |
"id": "1001", |
"jsonrpc": "2.0", |
"result": |
{ |
"Metrics": |
[ |
{ |
"ChannelId": "9ae04346-233b-445f-8466-26d708a16ec1", |
"ChannelName": "GQ", |
"Country": "US", |
"CreativeType": "Double Banner", |
"DeviceClass": "iPad", |
"DateTime": "2015-12-09 00:00:00", |
"Taps": "1", |
"eCPM": "0.00", |
"iAdImpressions": "0", |
"TTR": "10000.00", |
"Revenue": "0.00", |
"DirectSoldImpressions": "1", |
"HouseImpressions": "0", |
"AdPosition": "In Feed" |
} |
], |
"Success": true |
} |
} |
Copyright © 2016 Apple Inc. All Rights Reserved. Terms of Use | Privacy Policy | Updated: 2016-08-12