Main

Getting Started

Main.GettingStarted History

Hide minor edits - Show changes to output

July 15, 2015, at 04:15 PM by 104.174.151.30 -
Changed line 42 from:
# Grab one of the following JavaScript libraries: [[https://bitbucket.org/ninja_metrics/kapi-javascript-lib/src/master/KApi.js|Katana JavaScript Library ]], [[http://www.ninjametrics.com/docs/kapi-js-lib/KApi.js|Standard JavaScript Library]], [[http://www.ninjametrics.com/docs/kapi-js-lib/KApi-min.js|Minimized JavaScript Library]].
to:
# Grab one of the following JavaScript libraries: [[https://bitbucket.org/ninja_metrics/kapi-javascript-lib/src/master/KApi.js|Katana JavaScript Library ]], [[https://bitbucket.org/ninja_metrics/kapi-javascript-lib/raw/master/KApi.js|Standard JavaScript Library]].
February 16, 2015, at 05:55 AM by 76.175.66.204 -
Changed line 42 from:
# Grab one of the following JavaScript libraries: [[https://api.ninjametrics.com/KAPI/kAPI.js|Katana JavaScript Library ]], [[http://www.ninjametrics.com/docs/kapi-js-lib/KApi.js|Standard JavaScript Library]], [[http://www.ninjametrics.com/docs/kapi-js-lib/KApi-min.js|Minimized JavaScript Library]].
to:
# Grab one of the following JavaScript libraries: [[https://bitbucket.org/ninja_metrics/kapi-javascript-lib/src/master/KApi.js|Katana JavaScript Library ]], [[http://www.ninjametrics.com/docs/kapi-js-lib/KApi.js|Standard JavaScript Library]], [[http://www.ninjametrics.com/docs/kapi-js-lib/KApi-min.js|Minimized JavaScript Library]].
March 01, 2014, at 05:42 PM by 209.121.225.196 -
Changed lines 64-66 from:
You’ll find that the API documentation outlines the parameters and requirements to log events to the Katana API. For each individual event you'll find an event description, the mandatory and optional parameters to call, the Katana dashboards and features impacted by logging the event, and a sample use.

In Addition you’ll also find that the corresponding default values have been listed for each parameter. For those parameters with ‘smart defaults’ you may disregard the parameter requirement. Where parameters relate to types (e.g. Account Types, Social Event Types), of which there may be many, you may find a list of sample types in Appendix A.
to:
You’ll find that the API documentation outlines the parameters and requirements to log events to the Katana API. For each individual event you'll find an event description, the mandatory and optional parameters to call in JSON, the Katana dashboards and features impacted by logging the event, and a sample use.

In addition, you’ll also find that the corresponding default values have been listed for each parameter. Where parameters relate to types (e.g. Account Types, Social Event Types), of which there may be many, you may find a list of sample types in Appendix A.
Changed lines 72-78 from:
Also note that certain initiation and creation events, such as account creation or shard initialization, must be loaded before referencing the event ID in any other logging statements. For those events where this applies, you'll find that this is noted along with the requirements.
to:
Also note that certain initiation and creation events, such as account creation or shard initialization, must be loaded before referencing the event ID in any other logging statements. For those events where this applies, you'll find that this is noted along with the requirements.

For a complete JSON only request, create a POST request to the appropriate url making sure to set the header Content-Type = "application/json":
[@
http://api.ninjametrics.com/event?client_id=1234&app_id=5678&app_pwd=somepassword&api_client=JSON
@]
The body of the post request format should match one of the JSON event samples found in the [[Main/QuickStartGuide|Quick Start Guide]] and [[Main/AdvancedSetupGuide|Advanced Setup Guide]]. In each sample one field that should remain unchanged is the "type" key/value pair, this is the event id.
Changed line 59 from:
You’re in! Now what? Get up and running faster with the [[Main/QuickStartGuide|Quick Start Guide]], or get the full experience with the Advanced Setup Guide. The choice is up to you.
to:
You’re in! Now what? Get up and running faster with the [[Main/QuickStartGuide|Quick Start Guide]], or get the full experience with the [[Main/AdvancedSetupGuide|Advanced Setup Guide]]. The choice is up to you.
Changed line 9 from:
-->[-Step 3: Advanced Setup Guide - Get the complete experience with this guide, designed to optimize your data and get the most out of Katana Analytics.-]
to:
-->[-Step 3: [[Main/AdvancedSetupGuide|Advanced Setup Guide]] - Get the complete experience with this guide, designed to optimize your data and get the most out of Katana Analytics.-]
Changed line 59 from:
You’re in! Now what? Get up and running faster with the Quick Start Guide, or get the full experience with the Advanced Setup Guide. The choice is up to you.
to:
You’re in! Now what? Get up and running faster with the [[Main/QuickStartGuide|Quick Start Guide]], or get the full experience with the Advanced Setup Guide. The choice is up to you.
Changed line 7 from:
-->[-Step 2: Quick Start Guide - Get up and running fast with this quick guide that takes you beyond basic metrics.-]
to:
-->[-Step 2: [[Main/QuickStartGuide|Quick Start Guide]] - Get up and running fast with this quick guide that takes you beyond basic metrics.-]
Added lines 1-72:
The Katana Social Analytics Engine measures the value of social contributions in applications and games, provides detailed projections for the outcomes that matter to developers, and offers the tools to determine how effectively features facilitate engagement and social interaction.

For better metrics and clearer insight follow these steps to implement the Katana Analytics API:

-->[-Step 1: Getting Started - Get started by learning how to initialize the Katana API for your app.-]

-->[-Step 2: Quick Start Guide - Get up and running fast with this quick guide that takes you beyond basic metrics.-]

-->[-Step 3: Advanced Setup Guide - Get the complete experience with this guide, designed to optimize your data and get the most out of Katana Analytics.-]


Follow the steps outlined below to initialize the Katana Analytics API for either Android, iOS, JavaScript or PHP. Once you’re done here, continue on to discover how to execute calls to begin logging events.

----
'+Android+'

To get started with Android, you’ll need to include our Android library, the jar file (kapi.jar), into your project lib folder, add it to your build path, and initialize a fresh tracking object to initialize the API. Note that the calls to the Katana Android library are asynchronous.

To initialize the API using Android
# Grab the latest version of the Katana Android Library:  https://bitbucket.org/ninja_metrics/kapi-android-lib
# Include the Android library in your source, using: “import com.ninjametrics.kapi.KApi”
# Initialize a fresh tracking object in your source, using: KApi kapi = new KApi (url, clientID, appID, appPassword);

----

'+iOS+'

To get started with iOS, you’ll need to include our iOS library, the objective---c files (kApi.h and kApi.m), into your iOS environment, and initialize a fresh tracking object to initialize the API. Note that the calls to the Katana iOS library are asynchronous.

To initialize the API using iOS
# Grab the latest version of the Katana iOS Library:  https://bitbucket.org/ninja_metrics/kapi-ios-lib
# Include the iOS library in your source, using: #import “kAPI.h”
# Initialize a fresh tracking object in your source, using: kAPI *api = [[kAPI alloc] clientID, appID, appPassword];

----

'+JavaScript+'

To get started with JavaScript, you’ll need to include our JavaScript library and initialize a fresh tracking object to initialize the API and integrate our JavaScript library into your HTML5 or ActionScript based web app. Note that the Katana JavaScript library makes use of asynchronous POST requests through Cross-Origin Resource Sharing (CORS) to make sure event tracking doesn’t block any of your business logic.

To initialize the API using JavaScript
# Grab one of the following JavaScript libraries: [[https://api.ninjametrics.com/KAPI/kAPI.js|Katana JavaScript Library ]], [[http://www.ninjametrics.com/docs/kapi-js-lib/KApi.js|Standard JavaScript Library]], [[http://www.ninjametrics.com/docs/kapi-js-lib/KApi-min.js|Minimized JavaScript Library]].
# Include the JavaScript library, using: <script type="text/javascript" src="KApi.js"></script>
# Initialize a fresh tracking object, using: var aKApi= new KApi(yourClientId, yourAppId, yourAppPassword);

----

'+PHP+'

To get started with PHP, you’ll need to include our PHP library and initialize a fresh tracking object to initialize the API and integrate our library into your PHP environment. The Katana PHP library works with a vanilla instance of a PHP version 5.2+ environment. Note that this class library is blocking, as PHP does not have a good platform-independent means of setting up asynchronous processing queues.

To initialize the API using PHP
# Grab the latest version of the Katana PHP Library:  https://api.ninjametrics.com/KAPI/kAPI.php
# Include the PHP library in your source, using: require_once('KApi.php');
# Initialize a fresh tracking object in your source, using: $aKApi = new KApi($clientId, $appId, $appPassword);

----

You’re in! Now what? Get up and running faster with the Quick Start Guide, or get the full experience with the Advanced Setup Guide. The choice is up to you.


'+Developer Notes+'

You’ll find that the API documentation outlines the parameters and requirements to log events to the Katana API. For each individual event you'll find an event description, the mandatory and optional parameters to call, the Katana dashboards and features impacted by logging the event, and a sample use.

In Addition you’ll also find that the corresponding default values have been listed for each parameter. For those parameters with ‘smart defaults’ you may disregard the parameter requirement. Where parameters relate to types (e.g. Account Types, Social Event Types), of which there may be many, you may find a list of sample types in Appendix A.

Note that when referencing parameters, they must be called in the exact order displayed in the table and the sample.

When ‘Shard ID’ is a required parameter, use 0 if shards are not used or if the event does not have a shard ID. When ‘Character Id’ is a required parameter and the application does not have character IDs the value of the Account_Id should be repeated as the value of the Character_Id. When ‘Country’ is a required parameter, use one of the [[Main/recommendedcountrycodes|recommended country codes]] from the standardized list, or use a non-standard country code and Katana will convert it to one of the standardized codes based on the nearest probable code.

Also note that certain initiation and creation events, such as account creation or shard initialization, must be loaded before referencing the event ID in any other logging statements. For those events where this applies, you'll find that this is noted along with the requirements.