Publisher API Documentation

This document provides information required to create campaigns by publisher.


Introduction

Affle publisher API has been designed to let publisher manage campaigns directly using information provided by publisher API.

The following sections include description of entities contained in the APIs and the information required to work with campaign.

Publisher-API-Documentation-Diagram



Authentication

All Publisher API calls required publisher key. Please contact us to know your key.



1. List Campaign information by id

Parameters Name Parameters Description
campaignId Campaign Id
campaignName Campaign Name
campaignObjective Campaign Objective (Display, Install, Inapp Event, VAS)
publisherId Unique Id for Tracking (also called as Flight Id)
totalBudget Campaign Lifetime Budget (its either lifetime or daily)
dailyCap Campaign Daily Budget in $ (its either lifetime or daily)
payout Payout to the Publisher
trafficType traffic type(Incent/NonIncent)
startDate Campaign Start Date
endDate Campaign End Date
defaultTrackerURL Default Click Tracker URL (No Association with any Creative)
targeting Geo Targeting (Countries, Region) System Targeting (Operating System, Version)
assetType Type of asset such as android,ios,windows
assetName Name of the asset
assetUrl Asset url e.g play store url,itunes url
creativeId Creative id
creativeName Name of Creative
creativeFormat Format for the creative (Banner, Text, Richmedia)
creativeURL Creative URL
creativeTrackerURL Creative Specific Click Tracker URL
creativeSrc Information about creative such as name,Dimension,type,weight,size etc.
URL http://<base_url>/publisher.php?cId=<campaignId>&key=<publisherKey>
Method GET
Sample response
{
    "data": [
        {
            "campaignId": 1122334455,
            "campaignName": "testCampaign",
            "campaignObjective": "affiliate",
            "publisherId": 1895,
            "totalBudget": 1000,
            "dailyCap": 5,
            "payout": 5,
            "trafficType": "Incent",
            "startDate": "2015-08-25",
            "endDate": "2015-08-27",
            "defaultTrackerURL": "http://click.affle.co/global/click.php?af_cid=1122334455&af_pid=1895&af_pageid=174",
            "targeting": {
                "geoTargeting": {
                    "country": [
                        "Afghanistan",
                        "Antigua and Barbuda",
                        "Anguilla"
                    ]
                },
                "systemTargeting": {
                    "osFamily": [
                        "Apple Mac",
                        "Microsoft Windows",
                        "BlackBerry OS"
                    ]
                }
            },
            "assetType": "android",
            "assetName": "asset Name",
            "assetUrl": "https://play.google.com/store/apps/details?id=com.asseturl",
            "creatives": [
                {
                    "creativeId": 1645,
                    "creativeName": "testCreative1",
                    "creativeFormat": "banner_text",
                    "creativeURL": " https://s3-ap-southeast-1.amazonaws.com/maasbanners/1122334455_ban3_72x72.jpg",
                    "creativeTrackerURL": "http://click.affle.co/global/click.php?af_cid=1122334455&af_pid=1895&af_pageid=173&af_creativeid=1645",
                    "creativeSrc": {
                        "Name": "1122334455_ban3_72x72.jpg",
                        "Weight": "1.55 kb",
                        "Dimension": "72x72",
                        "Type": "jpg"
                    }
                },
                {
                    "creativeId": 1361,
                    "creativeName": "rozip",
                    "creativeFormat": "banner",
                    "creativeURL": " https://s3-ap-southeast-1.amazonaws.com/maasbanners/1122334455_rozip_300x50.png",
                    "creativeTrackerURL": "http://click.affle.co/global/click.php?af_cid=1122334455&af_pid=1895&af_pageid=17131&af_creativeid=1361",
                    "creativeSrc": {
                        "Name": "1122334455_rozip_300x50.png",
                        "Weight": "0.74 kb",
                        "Dimension": "300X50",
                        "Type": "png"
                    }
                }
            ]
        }
    ]
}

2. API Error Codes

Error Code Error Message
400 Bad Request
404 Invalid API method
503 Service Unavailable
1001 No Data Found
1003 Invalid token key
1004 Invalid campaign id
1005 Invalid publisher key