How to fetch tealium_visitor_id ?

Bronze Contributor
Bronze Contributor

We are in the process of rolling out Tealium would like to pass the tealium_visitor_id across to internal system.

Question is how to fetch tealium_visitor_id ?

What other ids does Tealium supplies?

Thanks

4 REPLIES 4

How to fetch tealium_visitor_id ?

Gold Contributor
Gold Contributor

There are a few ways to fetch the tealium_visitor_id.

Method 1: Use the Tealium API.

The Tealium API allows you to access data from Tealium's data warehouse. To use the API, you will need to create an API key. Once you have an API key, you can use the following API call to fetch the tealium_visitor_id:

https://api.tealium.com/v1/visitors/get?visitorId=<visitorId>

Method 2: Use the Tealium JavaScript SDK.

The Tealium JavaScript SDK allows you to access Tealium's data warehouse from your website. To use the SDK, you will need to include the Tealium JavaScript library in your website's header. Once you have included the library, you can use the following code to fetch the tealium_visitor_id:

var tealium = new Tealium();
var visitorId = tealium.getVisitorId();

Method 3: Use the Tealium Tag Manager.

The Tealium Tag Manager allows you to manage Tealium's data warehouse from a graphical user interface. To use the Tag Manager, you will need to create a Tag Manager account. Once you have created an account, you can use the Tag Manager to create a tag that will fetch the tealium_visitor_id.

Other IDs that Tealium supplies

In addition to the tealium_visitor_id, Tealium also supplies a number of other IDs. These IDs include:

  • cookie_id: The cookie_id is a unique identifier that is stored in the visitor's browser.
  • device_id: The device_id is a unique identifier that is assigned to the visitor's device.
  • ip_address: The ip_address is the visitor's IP address.
  • user_agent: The user_agent is the visitor's browser's user agent string.

These IDs can be used to track visitors across multiple devices and browsers. They can also be used to segment visitors and target them with different marketing campaigns.

shivam joshi

How to fetch tealium_visitor_id ?

Bronze Contributor
Bronze Contributor
Appreciate ur help Shivam.
Can we also use UTAG.JS to generate/access tealium_visitor_id?
Does this approach has Low level of effort is required as it will form part of the payload configuration ?

Thanks & Regards,
Girish

How to fetch tealium_visitor_id ?

Gold Contributor
Gold Contributor

Yes, you can use UTAG.JS to generate/access the tealium_visitor_id.

UTAG.JS is a JavaScript library that allows you to interact with Tealium's data warehouse. To use UTAG.JS, you will need to include the library in your website's header. Once you have included the library, you can use the following code to generate/access the tealium_visitor_id:

var tealium = new Utag.js();
var visitorId = tealium.getVisitorId();

This approach has a low level of effort required as it will form part of the payload configuration.

Here are the steps on how to use UTAG.JS to generate/access the tealium_visitor_id:

  1. Include the UTAG.JS library in your website's header.
  2. Create a new Utag.js object.
  3. Call the getVisitorId() method on the Utag.js object.
  4. The getVisitorId() method will return the tealium_visitor_id.

Here is an example of how to use UTAG.JS to generate/access the tealium_visitor_id:

<script src="https://cdn.tealium.com/tag/utag.js"></script>

<script>
var tealium = new Utag.js();
var visitorId = tealium.getVisitorId();
</script>

This code will generate/access the tealium_visitor_id and store it in the variable visitorId.

You can then use the visitorId variable to access the tealium_visitor_id in your code.



shivam joshi

How to fetch tealium_visitor_id ?

Bronze Contributor
Bronze Contributor

Awesome. Thank you Shivam.

Appreciate your help.

Public