Logo: Relish

  1. Sign in

Project: Mactagger2

Unique Identification

  • @acceptance

The webSDK needs to be able to uniquely identify users through the browser.

It needs to be able to handle generate unique IDs for new users that do not have IDs stored already on their device.
It needs to be able to handle identifying existing users that already have a ID stored on their device.
It needs to be able to handle opt out users by not setting any ID on their device.

Scenarios
No IDs stored
Given
the user does not have an ID stored in namespace
And
the user is not opt out
And
the webSDK has permission to write to that namespace
Then
store an ID in this format unique to the namespace with he key
Examples:
namespace format key
cache manifest mmh_[md5]_[sha1] haid
local storage mmh_[md5]_[sha1] mmid
cookie mmh_[md5]_[sha1] MAC-ID
Existing User ID in the cache manifest
Given
that the user already has a unique ID stored in the cache manifest
Then
do not overwrite the unique ID in the cache manifest
Existing User ID in the local storage
Given
that the user already has a unique ID stored in the local storage
Then
do not overwrite the unique ID in the local storage
Given
that the user already has a unique ID stored in the cookie
Then
do not overwrite the unique ID in the cookie
User is opt out
Given
that the user has chosen to opt out
Then
do not generate a unique id
And
do not store the unique ID in the cache manifest
And
do not store the unique ID in the local storage
And
do not store the unique ID in a cookie

Last published about 4 years ago by Steven McCord.