EkStep for Android Developers

EkStep Android SDK

Helps bring the power of EkStep platform to Android apps. Genie can launch APKs and APKs can use the SDK to retrieve locally installed content, generate telemetry and will soon give you access to the micro learning platform. Requires Android API v17 or above.

Launch Genie would launch an APK with the following parameters in intent extras. The APK is expected to indicate the launcher activity while onboarding onto the platform. 1) origin with value as Genie 2) appInfo with a json value. The appInfo contains all metadata about the APK, including the launcher activity, ID and version on the platform. These are required fields while generating telemetry.

Telemetry The APK can send OE telemetry events on user interactions using the SDK. For more details on telemetry events & format refer Telemetry Specification.

Sample Code The following class structure can be used to store telemetry data and Gson library can be used to mashall the object to JSON.


class Telemetry { private String eid; // unique event ID private String ts; // timestamp of event capture in YYYY-MM-DDThh:mm:ss+/-nn:nn format, timezone is mandatory private long ets; // epoch timestamp of event capture in epoch format (time in milli-seconds. For ex: 1442816723) private String ver; // version of the event data structure, currently "2.0" private GameData gdata; // data about the game that generated this event private String sid; // user session ID (created whenever a user signs in), empty when no user is signed in private String uid; // uuid of the user account, empty when no user is signed in private String did; // uuid of the device, created during app installation private EventData edata; // event specific data structure } class GameData { private String id; // genie id since this is generated by genie private String ver; // genie app release version number } class EventData { private Object eks; //There can be a class to hold each type of event data based on the event. } To convert the above class structure to JSON String eventJson = GsonUtil.toJson(telemetryObject, Telemetry.class);

Exit The APK will need to finish its activity so that the previous Genie activity can resume.

Read the documentation to get started with the GenieServices SDK