Account details


Copy and paste these templates to capture useful details about your user’s account.

The most common data developers send themselves is user’s email (e.g. Depending on your app, instead of an email, you might want to report their username (e.g. stephanie_smith), user ID (e.g. 10d1ac10572b) or their screen name (e.g. dragon_slayer).

These will come in handy later on when you have to match a bug to a user for example!

val currentUser = getLoggedInUser();
val userLoggedIn: Boolean = currentUser.isUserLoggedIn();
if(userLoggedIn) {

Gaming and education

If your app is in the gaming or education industry, think about sending yourself more specific details about your players or people taking classes, maybe a player’s class (e.g. Wizard), a list of their achievements (e.g. [1, 2, 5, 8, 15]), their difficulty settings (e.g. Beginner) or a list of languages or courses they are taking (e.g. English and Spanish) to get the whole picture about the player without nagging them for more details.

val achievements = Array<Achievements>(100);
val courses = Array<Courses>(5);
val difficulty = Difficulty('Begginer');
if(user) {
achievements = user.getUserAchievements();
courses = user.getUserCourses();
difficulty = getCurrentDifficulty();
Shake.setMetadata("achievements", achievements);
Shake.setMetadata("courses", courses);
Shake.setMetadata("difficulty", difficulty);


In a more serious B2B environment, you probably want to always report yourself data like user’s account type (e.g. Admin), their subscription plan (e.g. Free) and similar.

val user = getCurrentUser();
if(user) {
Shake.setMetadata("paymentPlan", user.paymentPlan);
Shake.setMetadata("accountType", user.accountType);