User object

Understand the user object in activity tracking: manage identities, segments, and traits for user identification, analytics, and personalization in your front-end tracking setup.

The user object is part of the activity object and holds all the information needed to identify users.

For example:

"user": {
    "identities": {
        "sessionId": "session-id",
        "eCommerceId": "e-commerce-id",
        "customId1": "custom-id-1",
        "customId2": "custom-id-2"
    },
    "segments": ["segment-1", "segment-2"],
    "traits": {
        "customTrait1": "value",
        "customTrait2": "value"
    }
}

The user object is split into three distinct properties:

  • Identities: Unique identifiers that apply to one user

    • The session ID is mandatory. It is a value unique to a session and can be used to identify even anonymous users.

    • Any additional identities, such as an e-commerce ID, can be used to identify users across sessions and devices.

Session IDs are supported by default. To include additional identities, contact the Crownpeak team.

  • (XO only) Segments: Labels to qualify groups of users sharing common traits or behaviors, such as "Frequent buyer" or "Prospect"

    • Segments can provide more detailed analytics, better personalization, and better recommendations, but are optional.

  • (XO only) Traits: Various qualifying values related to the user in question, including profile, and preference data, age, gender, likes, etc.

    • Traits can provide more detailed analytics, better personalization, and better recommendations, but are optional.

Last updated