Actions

Affiliate ReportingAPI

From TyrooLabs

Contents

API Integration Process

API for registered Affiliates to fetch the campaign performance data which they are running or had run in the past.

How to generate affiliate id

Affiliate id is required to call the API.

Create an account on Tyroo central - http://ui.tyroo.com/www/admin/index.php

How to call API

Below table list downs the various parameters that can be used while making a request.

Request nodes:

Node Sub Node Description Mandatory
affiliate_id Unique Id on Tyroocentral Platform Yes
inputs Contains dates Yes
startDate The start date(YYYY-MM-DD) Yes
endDate The end date(YYYY-MM-DD) Yes
campaign_id Campaign id for which you want to fetch the data. If no campaign id is filled, data for all the campaigns will be returned No

API Response Parameters

In case one is trying to fetch data for a complete month, it will take around 2 minutes to return the response. In order to get quick response, one should fetch data for a week.


Below table list downs the response parameters. Response Nodes:

Node Sub Node Description
success Displays the ‘true’ msg. if API call is successful.
affiliateId The ID of the publisher on performance central.
Stats Contains the data.
date Particular date in the date range the data.
clicks Total clicks (of all campaigns) on a particular date in the date range.
impressions Total impressions (of all campaigns) on a particular date in the date range.
conversions Total conversions (of all campaigns) on a particular date in the date range.
payout Total payout(of all campaigns) on a particular date in the date range. Values in USD.

Sample request and responses

(Response will be in JSON format)

Sample API request


http://reporting.tyroo.com/?affiliate_id=19037&inputs={"startDate":"2017-07-11","endDate":"2017-07-15"}&campaign_id=12239

Sample response


{
  "affiliate_id": "19037", 
  "stats": [
    {
      "clicks": "16", 
      "conversions": "0", 
      "date": "2017-07-11", 
      "impressions": "300", 
      "payout": "USD 0.0000"
    }, 
    {
      "clicks": "12", 
      "conversions": "0", 
      "date": "2017-07-12", 
      "impressions": "398", 
      "payout": "USD 0.0000"
    }, 
    {
      "clicks": "14", 
      "conversions": "0", 
      "date": "2017-07-13", 
      "impressions": "3953", 
      "payout": "USD 0.0000"
    }, 
    {
      "clicks": "9", 
      "conversions": "0", 
      "date": "2017-07-14", 
      "impressions": "2443", 
      "payout": "USD 0.0000"
    }, 
    {
      "clicks": "0", 
      "conversions": "0", 
      "date": "2017-07-15", 
      "impressions": "240", 
      "payout": "USD 0.0000"
    }
  ], 
  "success": true
}