to get going quickly. This library makes use of asynchronous POST
requests through Cross-Origin Resource Sharing (CORS) to make sure
Event tracking does not block any of your business logic.
- Grab the Katana
- Include the
- Initialize a
fresh tracking object: var aKApi
= new KApi(yourClientId,
- Register an
Account Id for use later:
= new Date(1980,
This equates to saying that a United States, Male, English speaker,
born on Sept 22, 1980 registered just now (the new Date() call) and
has $50.30 in his account.
a Character Id:
A new character registration happened just now for a character named
“that one guy” identified by the string
“wizard” of the “fish” race.
If your application does
not use the character distinction,
then do not initialize characters. Use an empty string anywhere
there is an opening for Character Id.
a Login Event:
in just now (the new Date() call) using the Facebook Mobile
platform. Based on the first “0” this application does
not use shards, and based on the second “0” this app
does not use areas.
a Logout Event:
out just now from his Facebook Mobile based session.
on getting started!
that any Account Id or Character Id you want to reference must first
be initialized; the initialization only has to happen once over the
lifetime of any Id. Take a look at the inline method documentation
(in KApi.js) or the HTTPS & JSON API for more information on
accepted parameter values.
the numeric values for yourClientId and yourAppId from
the account management panel, or ask your account manager for help.