Skip to content

Commit 03ea2e3

Browse files
committed
New content for renamed file
1 parent 124e8d5 commit 03ea2e3

1 file changed

Lines changed: 20 additions & 5 deletions

File tree

docs/cdp/cdp_activation/cdp_add_tracking.md

Lines changed: 20 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,27 @@
11
---
2-
description: Client-side Tracking in Ibexa CDP.
2+
description: Adding tracking in [[= product_name_cdp =]].
33
edition: experience
44
---
55

6-
# Add Client-side Tracking
6+
# Add tracking
7+
8+
The final step is setting up a tracking script that identifies visitors and records their interactions.
9+
You can set it up in two ways:
10+
11+
## Tracking with built-in Raptor tracking functions
12+
13+
If your project uses the [Raptor connector](raptor_connector.md), use the built-in [Raptor tracking functions](tracking_functions.md).
14+
This recommended approach supports both client-side and server-side tracking, handles cookie consent, and sets the tracking cookie required for [anonymous user segmentation](cdp_configuration.md#anonymous-user-segmentation).
15+
16+
For setup instructions, see [Raptor tracking functions](tracking_functions.md).
17+
18+
## Manual setup
19+
20+
If you aren't using the Raptor connector, you can set up tracking manually.
721

8-
The final step is setting up a tracking script.
922
It requires a head tracking script between the `<head></head>` tags on your website, a main script after the head script, and cookie consent.
1023

11-
For more information about setting up a tracking script, see [Raptor documentation](https://content.raptorservices.com/help-center/client-side-tracking).
24+
For more information about setting up a tracking script manually, see [Raptor documentation](https://content.raptorservices.com/help-center/client-side-tracking).
1225

1326
Now, you need to add a tracker to specific places in your website where you want to track users.
1427
For example, add this tracker to the landing page template to track user entrances.
@@ -26,10 +39,12 @@ raptor.trackEvent('buy', ..., ...);
2639
```
2740

2841
For tracking to be effective, you also need to send ID of a logged-in user in the same way.
29-
Add the user ID information by using below script:
42+
Add the user ID information of logged-in users by using below script:
3043

3144
```js
3245
raptor.push("setRuid","USER_ID_HERE")
3346
```
3447

48+
For anonymous visitors, Raptor's tracking script automatically sets an `rsa` cookie that uniquely identifies the visitor, without calling the `setRuid` method.
49+
3550
For more information on tracking events, see [the documentation](https://content.raptorservices.com/help-center/tracking-events-for-recommendation).

0 commit comments

Comments
 (0)