Support Home > Analytics, Reports & API > Introduction to the Premium Publisher API

Introduction to the Premium Publisher API

The Free App Analytics Administration API is a restful based web service that provides a globally accepted format used to access data on the web from any type of application. All server responses from the Free App Analytics Premium Publisher API use HTTP status codes and messages to indicate the state of the request. In some circumstances a JSON response will be returned in the HTTP body.

 

BEST PRACTICES: Kochava recommends using a browser extension called Postman. This is a free Chrome extension that will allow you to specify the Host/URL, URL Params, Headers and the method of the request (GET, POST, PUT, PATCH, DELETE, etc.). Postman makes testing extremely simple and fast. All examples in this documentation are displayed as if Postman is being used.

NOTE: If you are looking for the JSON reporting API, refer to our API Support Documentation.


HTTP Verbs

The following HTTP verbs are used in the Free App Analytics Administration APIs or at the least on the roadmap to be implemented.

 

Verb Definition
GET Used if you intend on retrieving a single entity or list of entities. If retrieving a single entity you will be required to specify the entity ID in the URL.
HEAD Under some circumstances you want to check if an entity exists without receiving a body in the response so you would use this along with the entity ID to check for.
POST When you want to create a brand new entity you would use this along with a JSON entity definition.
PUT Unlike POST, this accepts a JSON entity definition and it will override the existing entity. The entity is identified by the entity ID in the URL. – Not implemented yet.
PATCH Unlike PUT, this will update only the given fields for the given entity. Again just like PUT you will be required to put the entity ID that you intend on updating in the URL.

HTTP Status Codes

Below are the HTTP status codes that the Free App Analytics Administration API will return as a result of a request.

 

Code Definition
HTTP 200 Indicates that the request was successful and there might be a response in the HTTP body.
HTTP 201 This indicates the successful creation of a new entity.
HTTP 400 When you want to create a brand new entity you would use this along with a JSON entity definition.
HTTP 401 If you send the server a malformed request (like JSON) then you will receive this as a result of it.
HTTP 404 The requested entity doesn’t exist.
HTTP 501 If you request an API endpoint that doesn’t exist this will be returned as a result of it.

Authentication

Authentication will require you to send an HTTP header named “Authentication-Key” with your API access key that can be retrieved from your account management console within Free App Analytics. At the time of this writing the Authentication Key is associated to your entire Free App Analytics account and it’s not possible to associate it to a single user or multiple users. This is still under heavy development.


HTTP Body

Below are the different data types that the API will return upon your request. The format below is standard across all Free App Analytics Administration APIs.

NOTE: Any items tagged with “Not implemented” below means that Free App Analytics is not currently using the properties, but they do appear in the API response.

 

API Response Definition
success True or false to indicate if the request was successful or if an issue occurred.
meta Contains extra information about the request or page of entities. Some types of data that is on the roadmap to be stored in here is the total amount of entities available, current page, items per page, total pages, etc. Not implemented.
errors A list of errors that occurred while processing your request. These mean that one or more errors occurred and we failed to successfully fulfill your request. Not implemented.
warnings A list of warnings that occurred while processing your request. These generally mean that something occurred, but processing was still successful and you should do better next time. Not implemented.
messages A list of messages that occurred while processing your request. These are for informational purposes only and don’t indicate that processing failed. Not implemented.
data This will always be a list of entities. If you request a single entity you should still expect data to be a list with a single entity.

 

JSON:

{
	"success": true,
	"meta": null,
	"errors": [

	],
	"warnings": [

	],
	"messages": [

	],
	"data": [

	]
}

 
 

Last Modified: Nov 11, 2022 at 1:09 pm