Users
How Klime identifies and tracks individual people.
A user represents an individual person using your product. In Klime, users are identified by a unique ID and can have traits attached to them.
klime.identify("user_123", {
email: "jane@acme.com",
name: "Jane Smith",
role: "admin",
})User ID
The userId is required for all events. It's the key that ties everything together — events, traits, and group memberships all connect through the user ID.
Use a stable identifier that won't change, like your database primary key:
// Good - database IDs
"user_123"
"usr_abc123def456"
// Avoid - can change
"jane@acme.com"
"janesmith"Klime doesn't support anonymous tracking. If you don't know who the user is yet, wait until they're identified before sending events.
User traits
Traits are metadata about the user. Common traits include contact info (email, name), account info (plan, role), and any custom data relevant to your business.
klime.identify("user_123", {
email: "jane@acme.com",
name: "Jane Smith",
plan: "pro",
role: "admin",
department: "Engineering",
})Call identify() whenever user information changes. Klime merges new traits with existing ones, so you only need to send what changed.
Users and groups
In Group mode, link users to their company using group():
klime.group(
"acme_inc",
{
name: "Acme Inc",
},
{ userId: "user_123" },
)A user can belong to multiple groups — useful for agency tools, consulting platforms, or multi-tenant apps. See Groups for more details.
In User mode, users are your customers — no groups needed.
Users and events
Every track() call requires a userId:
klime.track(
"Feature Used",
{
feature: "export",
},
{ userId: "user_123" },
)This connects the event to the user's activity timeline. In Group mode, the event also appears in the company's activity through the user's group membership.