Reporting API

From POKKT DOCUMENTATION
Jump to: navigation, search

POKKT Reporting APIs Guide

REST APIs for Publisher and Advertiser Reports

Last Update: 26th March, 2018


API EndPoints

All API requests are made relative to a Base URL

For the current API version, the Base URL is: http://report.pokkt.com

It is advised to URL encode all query parameter values, so that they are not accidentally misinterpreted.


Publisher Data

GET /v2/publisherReport

Get publisher report

Name Data Type Description Type
apiKey String It is the publisher's api key for reporting. The api key can be found in the sidebar tab of your account's page Query parameter
appId String It is the Application's id. This id can be found out on the on edit/view of Application page. Query parameter
startDateTime SQL Timestamp It is the start date of the report. Accepts date in ‘YYYY-MM-DD HH:mm:ss’ format or a Unix timestamp. For example 2012-10-05 00:00:00. Must not be longer than 90 days in the past. Query parameter
endDateTime SQL Timestamp It is the end date of the report. Accepts date in ‘YYYY-MM-DD hh:mm:ss’ format or a Unix timestamp. For example, 2012-10-05 00:00:00 Query parameter
campaignFormType string [Optional]Valid types : ["video", "interstitial", "banner"] Query Parameter

Example Request

GET

http://report.pokkt.com/v2/publisherReport?apiKey=7a917709f09fca2f316fwecd54fa&appId=c333bfbb7fa7sdj4348b246258a0371&startDateTime=2016-11-16+00%3A00%3A00&endDateTime=2016-11-20+00%3A00%3A00

Example Response

{
   "status": 1,
   "message": "OK",
   "response": {
      "revenue": "449.7",
      "ecpm": "2.0",
      "success": "224812",
      "clicks": "12090",
      "impressions": "224849",
      "requests": "643749",
      "conversionRate": "99.98",
      "users": "114258"
   }
} 

Publisher Data by Country

GET /v2/publisherReportByCountry

Get publisher data grouped by country

Name Data Type Description Type
apiKey String It is the publisher's api key for reporting. The api key can be found in the sidebar tab of your account's page Query parameter
appId String It is the Application's id. This id can be found out on the on edit/view of Application page. Query parameter
startDateTime SQL Timestamp It is the start date of the report. Accepts date in ‘YYYY-MM-DD HH:mm:ss’ format or a Unix timestamp. For example 2012-10-05 00:00:00. Must not be longer than 90 days in the past. Query parameter
endDateTime SQL Timestamp It is the end date of the report. Accepts date in ‘YYYY-MM-DD hh:mm:ss’ format or a Unix timestamp. For example, 2012-10-05 00:00:00 Query parameter
campaignFormType string [Optional]Valid types : ["video", "interstitial", "banner"] Query Parameter

Example Request

GET

http://report.pokkt.com/v2/publisherReportByCountry?apiKey=7a917709f0ds9d4bd3f2ecd54fa&appId=c33nd73nd984jd845548b246258a0371&startDateTime=2016-11-16+00%3A00%3A00&endDateTime=2016-11-20+00%3A00%3A00

Example Response

{
   "status": 1,
   "message": "OK",
   "response": [
      {
         "country": "india",
         "revenue": "1032.0",
         "success": "232",
         "requests": "32982329",
         "clicks": "29323",
         "impressions": "982932",
         "conversionRate": "18.0"
      },
      {
         "country": "indonesia",
         "revenue": "1032.0",
         "success": "2030",
         "requests": "19982329",
         "clicks": "32923",
         "impressions": "239239",
         "conversionRate": "15.0"
      },
      {
         "country": "vietnam",
         "revenue": "2383",
         "success": "2030",
         "requests": "34984334",
         "clicks": "9394",
         "impressions": "393443",
         "conversionRate": "20"
      }
   ]
}

Aggregated Advertiser Report

GET /v2/advertiserReport

Get aggregated advertiser data

Name Data Type Description Type
apiKey String It is the publisher's api key for reporting. The api key can be found in the sidebar tab of your account's page Query parameter
startDateTime SQL Timestamp It is the start date of the report. Accepts date in ‘YYYY-MM-DD HH:mm:ss’ format or a Unix timestamp. For example 2012-10-05 00:00:00. Must not be longer than 90 days in the past. Query parameter
endDateTime SQL Timestamp It is the end date of the report. Accepts date in ‘YYYY-MM-DD hh:mm:ss’ format or a Unix timestamp. For example, 2012-10-05 00:00:00 Query parameter
campaignFormType string [Optional]Valid types : ["video", "interstitial", "banner"] Query Parameter

Example Request

GET

http://report.pokkt.com/v2/advertiserReport?apiKey=edab623664857dj4d96d1da6b03f67f&appId=c333bfbb854j8d85548b246258a0371&startDateTime=2016-11-16+00%3A00%3A00&endDateTime=2016-12-20+00%3A00%3A00

Example Response

{
   "status": 1,
   "message": "OK",
   "response": {
      "cost": "4873.3",
      "success": "38473803",
      "impressions": "43838478"
   }
}

Aggregated Advertiser Report campaign wise

GET /v2/advertiserReport/campaignReport

Get aggregated advertiser data campaign wise

Name Data Type Description Type
apiKey String It is the publisher's api key for reporting. The api key can be found in the sidebar tab of your account's page Query parameter
startDateTime SQL Timestamp It is the start date of the report. Accepts date in ‘YYYY-MM-DD HH:mm:ss’ format or a Unix timestamp. For example 2012-10-05 00:00:00. Must not be longer than 90 days in the past Query parameter
endDateTime SQL Timestamp It is the end date of the report. Accepts date in ‘YYYYMM-DD hh:mm:ss’ format or a Unix timestamp. For example, 2012-10-05 00:00:00 Query parameter
campaignFormType string [Optional]Valid types : ["video", "interstitial", "banner"] Query Parameter

Example Request

GET

http://report.pokkt.com/v2/advertiserReport/campaignReport?apiKey=e358c679b478ad74f55c59cacf0c0398&startDateTime=2017-10-01 01:01:01&endDateTime=2017-12-01 01:01:01&campaignFormType=video

Example Response

{
   "status": 1,
   "message": "Success",
   "response": [
        {
            "impressions": 6,
            "success": 2,
            "cost": 0,
            "campaign_id": 6584,
            "campaign_title": "Nescafe",
            "firstQuartile_count": 2,
            "midpoint_count": 2,
            "thirdQuartile_count": 2,
            "complete_count": 2,
            "clicks": 1
        },
        {
            "impressions": 5203,
            "success": 2085,
            "cost": 1551.36,
            "campaign_id": 6299,
            "campaign_title": "Pokkt Test",
            "firstQuartile_count": 2292,
            "midpoint_count": 2864,
            "thirdQuartile_count": 1472,
            "complete_count": 2062,
            "clicks": 1251
        }
   ]
}

For previous version of reporting apis, click here