Product Advisor Event Tracking Integration
This guide explains how to integrate the Product Advisor event to send analytic information to your analytics platform.
Example Product Advisor Track Event
type FinderTrackEvent = {
id: string; // unique identifier of the finder
variant: string; // unique identifier of the finder variant (for A/B testing)
activation: string; // what activated this finder (e.g., 'ribbon' or 'custom')
open: boolean; // is the finder opened or closed
name: string; // name of the finder
version: number; // current version of the finder
page: string; // component currently shown to the end-user (e.g., landing or loading)
question: string; // current question the user is on (e.g., 'gender' or 'goal')
answers: Record<string, string>; // all answers previously given, e.g., {'landing': '1', 'gender': 'male'}
products: string[]; // if the page is a result page, contains the product-IDs advised
};
window.crobox = window.crobox || [];
crobox.push(crobox => {
crobox.on('productfinder.track', (event: FinderTrackEvent) => {
// TODO: Implement the connection to third-party analytics
});
});Implementation Steps
Key Notes on Naming Conventions
Last updated
Was this helpful?
