enableAnonymousTracking: Network User Id

Hi,

I’m trying to setup anonymous tracking with the new feature in 2.15. When I open the console and insert “window.snowplow(‘enableAnonymousTracking’)”, the next page ping hit will not have session or domain id information, but still the network user id. It also seems like the cookies are not deleted at all (sp, spses.xxx …). I’ve also tried with “window.snowplow(‘clearUserData’);”, but the cookies and localstorage still stay the same…

Is this intended behaviour? Are there any additional steps necessary to implement this correctly?

Thank you!
Andreas

Hi @volderette

You can think of this as the first version of anonymous tracking, where we are starting on a journey to full cookieless tracking.

The features available now allow you to keep your events anonymous in terms of client side user identifiers (i.e. the domain user and sesssion information) but it doesn’t currently control the server side user identifiers (i.e. the network user id). In a future release, along with a new collector release, we will have the ability to toggle the server side cookies too with the same anonymous tracking functionality in the tracker (_sp and ip address collection).

The typical way we expect users to integrate is to set anonymousTracking: true when initialising the tracker and then use disableAnonymousTracking when things like cookie banners have been accepted.

We made a call to not automatically delete the cookies/local storage as we didn’t want this side effect to be on automatically for everyone and instead gave users the option to clear them manually. Calling clearUserData should have worked fine (although it will only clear _id and _sescookies not_sp` since that could be a HttpOnly cookie), I’ve noticed some of the browsers seem to fail miserably at updating the storage UI if you’ve got it open when you clear the cookies so try and do it from the Console tab and then navigate to the Storage tab.

Hello @PaulBoocock

I understand, thanks for the explanation! The option to disable the http cookie as well would be great.

For the clean function: I will try it again, but I believe I even used the refresh button in the cookie list of Chrome.

1 Like