Identity Resolution
Technical description of the Identity Resolution feature in RudderStack
Understanding your users is crucial to every behavioral analysis. Hence, it is quite essential to tie the events or activities to the individual users generating those events.
There are various analytics platforms that help you collect this event data. Unfortunately, this is not trivial in a world where users often browse anonymously, or use multiple identities (e.g., email ID, phone, etc.) with the same product, or access your app/website from different devices and channels.
With Identity Resolution, you can tie these different identities together whenever required, in a way that preserves your users' privacy.
Identity Resolution is available as a part of RudderStack's Enterprise plan.

Identity Resolution Explained

In this section, we walk you through a user's journey - Alice, in this case - in the context of an e-commerce company using RudderStack.
After integrating RudderStack, you can collect events from sources to build a profile for every user. All this is done on top of your data warehouse without sharing the data with a third-party vendor.
First, Alice searches for the latest iPhone in her mobile app, and signs up with her phone number.
Later, she signs up on the website with her email, verifies her mobile number and then purchases the iPhone. The flow of events is as shown:
Alice then reports an issue via her phone and a ticket for the same is created using Zendesk. This ticket confirmation email is sent to Alice using CustomerIO.
This data can be collected using the RudderStack cloud sources, as shown:
RudderStack has a merge API which takes two different identities and connects them. For example, Stripe is integrated for payments and you would want to merge Alice's Stripe identifier with your internal identifier.
Check out our blog which talks about the internal algorithm used to merge user identities.
This gives you the flexibility to run your own algorithms or machine learning models internally and send the final identity merge events to RudderStack.
RudderStack then applies the identity merges on all events and generates a table that includes the identity mappings of all users. A rudder_id is the unique identifier for all merged identities.
The following rudder_identity_mappings table is an example of how the identity mappings look like in Alice's user journey:

Querying with Identities

The following SQL queries use the rudder_identity_mappings table to generate the results using identity resolution:
1
-- get all tracks of user u1 --
2
3
WITH user_id_to_rudder_id_to_anonymous_id_mapping AS (
4
SELECT
5
DISTINCT(merge_property_value)
6
FROM
7
rudder_identity_mappings
8
WHERE
9
rudder_identity_mappings.merge_property_type = 'anonymous_id'
10
AND rudder_identity_mappings.rudder_id IN (
11
SELECT
12
rudder_identity_mappings.rudder_id
13
FROM
14
rudder_identity_mappings
15
WHERE
16
rudder_identity_mappings.merge_property_type = 'user_id'
17
AND rudder_identity_mappings.merge_property_value = 'u1'
18
)
19
)
20
SELECT
21
*
22
FROM
23
tracks
24
WHERE
25
tracks.anonymous_id IN (
26
SELECT
27
*
28
FROM
29
user_id_to_rudder_id_to_anonymous_id_mapping
30
)
31
32
-- get all users with an added_to_cart event in last 7 days ---
33
34
WITH anonymous_id_to_rudder_id_to_user_id_mapping AS (
35
SELECT
36
DISTINCT(merge_property_value)
37
FROM
38
rudder_identity_mappings
39
WHERE
40
merge_property_type = 'user_id'
41
AND rudder_id in (
42
(
43
SELECT
44
DISTINCT(rudder_id)
45
FROM
46
rudder_identity_mappings
47
WHERE
48
merge_property_type = 'anonymous_id'
49
AND merge_property_value IN (
50
SELECT
51
DISTINCT(anonymous_id)
52
FROM
53
added_to_cart
54
WHERE
55
DATE(timestamp) > DATEADD(day, -7, getdate())
56
)
57
)
58
)
59
)
60
SELECT
61
*
62
FROM
63
users
64
WHERE
65
id IN (
66
SELECT
67
*
68
FROM
69
anonymous_id_to_rudder_id_to_user_id_mapping
70
)
Copied!

Contact Us

For more information on identity mapping and how we have implemented it at RudderStack, feel free to contact us. You can also contact us on our Slack channel, and we will be happy to help you!
Last modified 5mo ago