# Identify people

 There's a new version available!

These pages cover version 3 of our SDK, but a newer version is available. In general, we suggest that you update to the latest version to take advantage of new features and fixes.

*   Are you new to our SDKs? [Check out the latest docs.](/integrations/sdk/android/getting-started)
*   Otherwise, [learn about updating to the latest version](/integrations/sdk/android/whats-new/)

You need to identify a person using a mobile device before you can send them messages or track events for things they do in your app.

You must have have the Tracking SDK to use this feature.

```groovy
implementation 'io.customer.android:tracking:3.11.1'
```

This page is part of a setup flow for the SDK. Before you continue, make sure you've implemented previous features—i.e. you can't identify people before you initialize the SDK!

## Identify a person[](#identify)

Identifying a person:

1.  Adds or updates the person in your workspace. This is basically the same as an [`identify` call to our server-side API](/api/#operation/identify).
    
2.  Saves the person’s information on the device. Future calls to the SDK reference the identified person. For example, after you identify a person, any events that you track are automatically associated with that person.
    
3.  Associates the current device token with the the person.
    

You can only identify one customer at a time. The SDK “remembers” the most recently-identified customer. If you identify person A, and then call the identify function for person B, the SDK “forgets” person A and assumes that person B is the current app user. You can also [stop identifying a person](#clearIdentify), which you might do when someone logs off or stops using your app for a significant period of time.

```kotlin
CustomerIO.instance()
  .identify(
    identifier = "989388339",
    attributes = mapOf("first_name" to "firstName")
  )
```

An identify request takes the following parameters:

*   **identifier** (required): The unique value representing a person—an ID, email address, or the [cio\_idAn identifier for a person that is automatically generated by Customer.io and cannot be changed. This identifier provides a complete, unbroken record of a person across changes to their other identifiers (id, email, etc).](/identifying-people/#cio_id) (when updating people), depending on your workspace settings.
*   **attributes** (Optional): Contains [attributesA key-value pair that you associate with a person or an object—like a person’s name, the date they were created in your workspace, or a company’s billing date etc. Use attributes to target people and personalize messages.](/journeys/attributes/) that you want to add to, or update on, a person; accepts strings, enums, primitives (int, float, char, etc.), their boxed counterparts (Integer, Float, Character, etc.), arrays, collections, lists, sets, and maps.

### Update a person’s attributes[](#identify-again)

You store information about a person in Customer.io as [attributesA key-value pair that you associate with a person or an object—like a person’s name, the date they were created in your workspace, or a company’s billing date etc. Use attributes to target people and personalize messages.](/journeys/attributes/). When you call the `identify()` function, you can update a person’s attributes on the server-side.

If a person is already identified, and then updates their preferences, provides additional information about themselves, or performs other attribute-changing actions, you can call `identify()` again to update their attributes on the server-side.

### Device attributes[](#device-attributes)

When you register a device token to a person, we automatically collect device [attributesA key-value pair that you associate with a person or an object—like a person’s name, the date they were created in your workspace, or a company’s billing date etc. Use attributes to target people and personalize messages.](/journeys/attributes/). You can use these attributes in [segmentsA group of people who match a series of conditions. People enter and exit the segment automatically when they match or stop matching conditions.](/journeys/data-driven-segments/) and other campaign workflow conditions to target the device owner, just like you would use a person’s other attributes. You cannot, however, use device attributes to personalize messages with [liquidA syntax that supports variables, letting you personalize messages for your audience. For example, if you want to reference a person’s first name, you might use the variable `{{customer.first_name}}`.](/using-liquid) yet.

For each device, we automatically collect the device `platform` attribute. Within your workspace, we also automatically set a `last_used` timestamp indicating when the device owner was last identified, and the `last_status` of a push notification you sent to the device. By default, we also automatically capture a series of `attributes`, like the device’s operating system, model, `push_enabled` preference. You can add custom attributes to the `attributes` object.

*   id string
    
    Required The device token.
    

#### Custom device attributes[](#custom-device-attributes)

When we collect device attributes, you can also set custom device attributes with the `deviceAttributes` method. You might do this to save app preferences, time zone, or other custom values specific to the device.

```kotlin
CustomerIO.instance().deviceAttributes = mapOf("key" to "value")
```

However, before you set custom device attributes, consider whether the attribute is specific to the `device` or if it applies to the person broadly. Device tokens are ephemeral—they can change based on user behavior, like when a person uninstalls and reinstalls your app. If you want an attribute to persist beyond the life of the device, you should [apply it to the person](#identify-again) rather than the device.

#### Disable automatic device attribute collection[](#disable-attributes)

By default, the SDK automatically collects the device attributes [defined above](#device-attributes). You can change your config to prevent the SDK from automatically collecting these attributes.

```kotlin
// set before you build
builder.autoTrackDeviceAttributes(false)
```

## Stop identifying a person[](#clearIdentify)

When a person logs out, or does something else to tell you that they no longer want to be tracked, you should stop identifying them.

Use `clearIdentify()` to stop identifying the previously identified person (if there was one).

```kotlin
// Calls to the Customer.io SDK will be ignored until you identify a new person. 
CustomerIO.instance().clearIdentify()
```

### Identify a different person[](#identify-a-different-person)

If you want to identify a new person—like when someone switches profiles on a streaming app, etc—you can simply call `identify()` for the new person. The new person then becomes the currently-identified person, with whom all new information—messages, events, etc—is associated.