JuicyAds API v1.0 ------ Overview The JuicyAds API v1.0 can be used by both Advertisers and Publishers to automate the following tasks. Advertisers 1. Retrieving a list of the Advertiser's Campaigns, and their current settings. 2. Retrieving an Advertiser's Statistics for specific Campaigns by Date, Country and Site ID. Publishers 1. Retrieving a Publisher's Statistics by Date, Country and Site ID. ------ The URL for all JuicyAds API requests is https://api.juicyads.com. Please note that only HTTPS requests are supported. ------ All dates must be provided and are returned in the short variant of the ISO 8601 standard: YYYY-MM-DD ------ All error messages will have a standard format consisting on an error code and appropriate error message. Example - {"code":4xx,"message":"Error Message"} ------ PopUnder Advertiser Methods campaigns GET - /campaigns/popunders/{token} Description: Returns a list of all PopUnder Campaigns associated with the users account. URL Params: {token} - Required - The Authorization Token Success: Response Code - 200 Example - [{"id":"12345","campaign_name":null,"buyer_id":"1234","accepted_countries":"US","daily_max":null,"daily_max_reached":"0","url":"https:\/\/www.test.com","amount":"0.0012","throttle":"100","active":"1","suspend":"0","hide_campaign":null,"lockdate":"0000-00-00","last_active":null,"last_modified":null}] Error Codes: 401 - Unauthorized statistics GET - /statistics/popunders/advertiser/{token}/{campaign-id}/{start-date}/{end-date} Description: Returns statistics for a specific PopUnder Campaign by Campaign ID grouped by Date. URL Params: {token} - Required - The Authorization Token {campaign-id} - Required - The Campaign ID {start-date} - Required - The Starting Date of the Date Range {end-date} - Required - The Ending Date of the Date Range Success: Response Code - 200 Example - [{"thedate":"2017-01-01","spend":"12.3456","imps":"123456"}] Error Codes: 401 - Unauthorized 404 - Page not found GET - /statistics/popunders/advertiser/{token}/{campaign-id}/{start-date}/{end-date}/country Description: Returns statistics for a specific PopUnder Campaign by Campaign ID grouped by County Code. URL Params: {token} - Required - The Authorization Token {campaign-id} - Required - The Campaign ID {start-date} - Required - The Starting Date of the Date Range {end-date} - Required - The Ending Date of the Date Range Success: Response Code - 200 Example - [{"country_code":"US","spend":"12.3456","imps":"123456"}] Error Codes: 401 - Unauthorized 404 - Page not found GET - /statistics/popunders/advertiser/{token}/{campaign-id}/{start-date}/{end-date}/site Description: Returns statistics for a specific PopUnder Campaign by Campaign ID grouped by Site ID. URL Params: {token} - Required - The Authorization Token {campaign-id} - Required - The Campaign ID {start-date} - Required - The Starting Date of the Date Range {end-date} - Required - The Ending Date of the Date Range Success: Response Code - 200 Example - [{"site_id":"123456","spend":"12.3456","imps":"123456"}] Error Codes: 401 - Unauthorized 404 - Page not found PopUnder Publisher Methods statistics GET - /statistics/popunders/publisher/{token}/{start_date}/{end_date} Description: Returns Publisher's PopUnder statistics grouped by Date. URL Params: {token} - Required - The Authorization Token {campaign-id} - Required - The Campaign ID {start-date} - Required - The Starting Date of the Date Range {end-date} - Required - The Ending Date of the Date Range Success: Response Code - 200 Example - [{"thedate":"2017-01-01","total":"12345","paid":"12.345"}] Error Codes: 401 - Unauthorized 404 - Page not found GET - /statistics/popunders/publisher/{token}/{start_date}/{end_date}/country Description: Returns Publisher's PopUnder statistics grouped by Country Code. URL Params: {token} - Required - The Authorization Token {campaign-id} - Required - The Campaign ID {start-date} - Required - The Starting Date of the Date Range {end-date} - Required - The Ending Date of the Date Range Success: Response Code - 200 Example - [{"country_code":"US","total":"12345","paid":"12.345"}] Error Codes: 401 - Unauthorized 404 - Page not found GET - /statistics/popunders/publisher/{token}/{start_date}/{end_date}/site Description: Returns Publisher's PopUnder statistics grouped by Site ID. URL Params: {token} - Required - The Authorization Token {campaign-id} - Required - The Campaign ID {start-date} - Required - The Starting Date of the Date Range {end-date} - Required - The Ending Date of the Date Range Success: Response Code - 200 Example - [{"site_id":"123456","total":"12345","paid":"12.345"}] Error Codes: 401 - Unauthorized 404 - Page not found