Track Player Events
Start sending your players' events on your platform to Gameball.
Start sending your players' events on your app to Gameball, along with any metadata that describes the event. Depending on your Gameball programs configuration, the player can be rewarded based on the sent events.
Tracked events can be app events or server side events depending on how you would like to design your programs. App events can be sent via the avialable SDK interface and server-sdie events can be sent to Gameball via the Track Events API.
Every Track Event call records a single user action. We call these “events”. We recommend that you make your event names human-readable, so that everyone can know what they mean instantly.
Event metadata are extra pieces of information you can tie to events you track. They can be anything that will be useful while designing your program.
For more information about events and usage examples, check Tracking Player Events tutorial
To send Player events from your app to Gameball, you can use the addAction SDK interface as below.
addAction interface sends an Action object to Gameball. Where the Action object is a wrapper holding a single or list of events. To add an event you should use the addEvent method on the Action object you have created.
Action action = new Action();
HashMap<String, Object> metaDeta = new HashMap<String, Object>()
metaData.put(<meta_data_string_value>, 500)
action.addEvent(<event_name>, metadata)
GameBallApp.getInstance(<ApplicationContext>).addAction(action, new Callback)

addEvent(String eventName, HashMap metaData)

event name
hashmap holding event related metadata. Each metadata is respresented by string key and object value. Possible data types for a value are integers, numbers, strings
Copy link