Retrieving Contentsquare session identifiers from the customer's website
Once an integration has been installed, the Provider should start collecting Contentsquare session identifiers during web visits on the common customer’s website. These identifiers will be used to attach the enrichment data to the right Contentsquare sessions when data will be received from the Provider.
Those identifiers are:
- The project ID: identifies the Contentsquare project ID where the data is stored
- The user ID: identifies the Contentsquare anonymous user ID for the user visiting the website
- The session number: identifies a specific session (as an ordered index) of the user ID. For example, if Contentsquare has tracked 4 different sessions of the same anonymous user, the last session number will be 4.
How to get those Contentsquare session identifiers?
Section titled How to get those Contentsquare session identifiers?During a visit on a website, you can interact with Contentsquare’s tag to pull
those identifiers via the afterPageView
command. A JavaScript code using that
command should look like this:
By calling this function you will get the project ID, user ID and session number of each session that are required to identify the Contentsquare sessions to be enriched.
Android native
Section titled Android nativeYou can call the Contentsquare public API on the Android SDK to retrieve these identifiers at any time.
iOS native
Section titled iOS nativeYou can call the Contentsquare public API on the iOS SDK to retrieve these identifiers at any time.