Amplitude tag how to identify unique users using user id

Bronze Contributor
Bronze Contributor

We are implementing the Tealium tag on our apps. In the past we previously used the Amplitude SDK and we are able to identify users in tealium via a user id. More explained in there docs here. 

https://amplitude.zendesk.com/hc/en-us/articles/115002278527#setting-custom-user-ids

 

We want to use tealium to send data to amplitude instead of including the SDK in the app. But I cannot figure out how to set custom user id in tealium. We have a user id setup in our datalayer. But I don't know when setting up the mapping the in the amplitude tag which destination I should use for Amplitude. E.g I don't see any user id related destinations. Is this possible as not being able to identify users limits the usefulness of the amplitude tag for our use case.

1 REPLY 1

Amplitude tag how to identify unique users using user id

Employee Emeritus

Hello,

I set up an instance of Amplitude in my local environment, and I'm showing "userId" in the network call after I map my UDO user id (testUserId) to set.UserId (screenshots below). While I'm unable to verify if this is making it to Amplitude, it'd be a quick way to test. I've also seen recommendations to set the userId via tag-scoped custom JavaScript extension, much like the one below. 

setuserId.png

 

networkrequestuserid.png

var count = 20;
var interval = 250;

var setUserId = setInterval(function() {
    if (count > 0) {
        if (window.amplitude && b.customer_email) {
            amplitude.setUserId(b.customer_email);
            clearInterval(setUserId);
        }
        count--;
    } else {
         clearInterval(setUserId);
    }
}, interval);

 

Public