User Identification (Flutter)

Tie events to specific users in your mobile app.

1. Identify

Call identify() when a user logs into your Flutter application. This persists their unique ID in SQLite, so even if they close and reopen the app, they remain identified.

EmpAnalytics.identify("user_12345");
ParameterTypeRequiredDescription
userIdStringYesThe unique ID for this user in your backend.

2. Alias (Sign Up)

Call alias() at the exact moment a user registers a new account to link their anonymous device history to their new account.

// 1. Alias to the new ID
EmpAnalytics.alias("new_user_890");

// 2. Identify as the new ID
EmpAnalytics.identify("new_user_890");

3. Reset (Logout)

When a user logs out, clear their session and generate a new anonymous ID.

EmpAnalytics.reset();

User Profiles (People API)

Update properties directly on the user's profile in the database without firing a track event.

// Set multiple properties
EmpAnalytics.people?.set({
  "Full Name": "John Doe",
  "Email": "john@example.com",
});

// Increment numeric properties
EmpAnalytics.people?.increment("Login Count", 1);

// Append to an array (e.g., interests or tags)
EmpAnalytics.people?.append("Interests", "Flutter");
Last updated on June 4, 2026