- Overview
- SDK Installation
<li><a href="#sdk_gendoc">SDK Generated Documentation</a>
<ul>
<li><a href="#sdk_gendoc_yuidoc">YUIdoc</a></li>
</ul>
</li>
<li><a href="#sdk_advertiser_reporting_overview">Advertiser Reporting Overview</a>
</li>
<li><a href="#sdk_exporting_reports">Exporting Advertiser Reports</a>
</li>
<li><a href="#sdk_license">MIT License</a>
</li>
<li><a href="#sdk_issues">SDK Issues</a>
</li>
The TUNE Reporting SDKs addressed in this posting are for creating hosted applications which require handling requests to TUNE Advertiser Report services with utility focus is upon Advertiser Reporting endpoints.
Even though the the breadth of the Service goes beyond just reports, it is these reporting endpoints that our customers primarily access.
The second goal of the SDKs is to assure that our customers’ developers are using best practices in gathering reports in the most optimal way.
Supported programming languages for TUNE Reporting SDKs are:
- PHP: tune-reporting-php
- Python: tune-reporting-python
- Java: tune-reporting-java
- Node.js: tune-reporting-node
- Go: Coming soon
- C#: Coming soon
The TUNE Reporting SDKs should absolutely not be included within Mobile Apps.
All information pertaining to TUNE SDKs for Mobile Apps are found here.
Developers Community Site for MobileAppTracking™ (MAT), the industry leader in mobile advertising attribution and analytics, provides TUNE Reporting API documentation to best practices and everything you need to be successful with MAT.
This site contains complete information about TUNE Reporting API, and references to all available TUNE Reporting SDKs with sample code.
This section detail what is required to use this SDK and how to install it for usage.
These are the basic requirements to use this SDK:
* node >= 0.10.*
* npm >= 1.4.*
To use SDK to access Advertiser Reporting endpoints of TUNE Advertiser Report, it requires a MobileAppTracking API Key: Generate API Key.
You can install tune-reporting-node via npm or by downloading the source from github.
It is available on npm: tune-reporting
Install as follows
$ npm install tune-reporting
Click here to download the source code
(.zip) for tune-reporting
.
$ git clone [email protected]:MobileAppTracking/tune-reporting-node
$ cd tune-reporting-node
$ npm install .
The TUNE Reporting SDK configuration is set within file ./config.js
.
And the appropriate environment settings:
config
├── development.json
├── production.json
└── test.json
With generated API_KEY from TUNE MobileAppTracking Platform account, replace UNDEFINED
.
; TUNE MobileAppTracking Platform generated API Key. Replace UNDEFINED.
tune.reporting.auth_key=UNDEFINED
; TUNE Reporting Authentication Type: api_key OR session_token.
tune.reporting.auth_type=api_key
; Validate use TUNE Service fields used within action parameters.
tune.reporting.verify_fields_boolean=false
; TUNE reporting export status sleep (seconds).
tune.reporting.status.sleep=10
; TUNE reporting export fetch timeout (seconds).
tune.reporting.status.timeout=240
; TUNE reporting export fetch verbose output.
tune.reporting.status.verbose=false
The TUNE Reporting SDK reads configuration through module ./config.js
with the
current environment SDK configuration file.
var
authKey = config.get('tune.reporting.auth_key'),
authType = config.get('tune.reporting.auth_type');
By default, configuration is assumed using api_key
authentication type.
To override 'api_key' authentication type:
config.set('tune.reporting.auth_key', apiKey);
config.set('tune.reporting.auth_type', 'api_key');
To override authentication type using session_token
:
config.set('tune.reporting.auth_key', sessionToken);
config.set('tune.reporting.auth_type', 'session_token');
If you wish to generate your own session_token, class SessionAuthentication
is provided:
var
apiKey = config.get('tune.reporting.auth_key'),
sessionAuthenticate = new SessionAuthenticate();
sessionAuthenticate.getSessionToken(apiKey, function (error, response) {
if (error) {
return next(error);
}
console.log(' Status: "success"');
sessionToken = response.getData();
console.log(' session_token:');
console.log(sessionToken);
return next();
});
and you're good to go!
SDK code is well commented and to see full documentation of its source using the provided Makefile commands that initiate code documentation generators.
The following will generate YUIdoc from Node.js codebase:
This code documentation generation may require npm installation of YUIdoc.
$ make docs-yuidoc
TUNE Reporting SDK YuiDoc Generated
### Advertiser Reporting Overview
The utility focus of the SDKs is upon the Advertiser Reporting API endpoints. Even though the the breadth of the Management API goes beyond just reports, it is these endpoints that our customers primarily access. The second goal of the SDKs is to assure that our customers' developers are using best practices in gathering reports in the most optimal way.
The endpoints interfaced by TUNE API SDKs provide access in gathering four types of reports:
- Log Reports
-
Log reports provide measurement records for each Click, Install, Event, Event Item and Postback. Instead of being aggregated, the data is on a per transaction / request basis. MobileAppTracking™ (MAT) uses these logs to generate the aggregated data for the Actuals and Cohort reports. Note that we don’t provide Log reports for Impressions and Opens currently.
Advertiser Reporting classes that perform Log Reports are:
AdvertiserReportLogClicks
: /advertiser/stats/clicks/AdvertiserReportLogEventItems
:/advertiser/stats/event/items/AdvertiserReportLogEvents
:/advertiser/stats/events/AdvertiserReportLogInstalls
:/advertiser/stats/installs/AdvertiserReportLogPostbacks
:/advertiser/stats/postbacks/
- Actuals Report
-
The Actuals report gives you quick insight into the performance of your apps and advertising partners (publishers). Use this report for reconciliation, testing, debugging, and ensuring that all measurement and attribution continues to operate smoothly. MAT generates this report by aggregating all the logs of each request (MAT updates the report every 5 minutes).
Actuals report endpoint include: /advertiser/stats/: Reports' class
AdvertiserReportActuals
Advertiser Reporting class that perform Actuals Reports is:
AdvertiserReportActuals
: /advertiser/stats/
- Cohort Report
-
The Cohort report analyzes user behavior back to click date time (Cohort by Click) or to install date time (Cohort by Install). Depending on whether you view the results based on click or install, the data in the report is vastly different.
Advertiser Reporting class that perform Cohort Reports is:
AdvertiserReportCohortValue
: /advertiser/stats/ltv
- Retention Report
-
The Retention report shows you how many of your installed users open or engage with your app over time (how users continue to get value from the app). AdvertiserReportCohortRetention reports are particularly good for evaluating the quality of users as opposed to the quantity of users (as in the case of user acquisition campaigns). For more information about retention reports, please visit Running AdvertiserReportCohortRetention Reports.
Advertiser Reporting class that perform Retention Reports are:
AdvertiserReportCohortRetention
: /advertiser/stats/retention
TUNE Reporting API Endpoints
Currently, there are two different ways of handling advertiser report exports. Both approaches require (A) an action to request that a report be exported and (B) another action to request the report status (if ready to be exported), and if ready, then provide a URL to download the completed report.
Logs and Actuals reports all request an export using action find_export_queue.json
, which returns a job_id
. You then pass the job_id
onto another endpoint Export::download.json
, which performs the status checking and report URL retrieval.
Cohort and AdvertiserReportCohortRetention reports all request an export using action export.json
, which also returns a job_id
. You then pass the job_id
onto another action status.json
, which performs the status checking and report URL retrieval.
Report issues using the Github Issue Tracker or Email [email protected].