Page View Events

Page View Events

Page view events will be sent to page_view_events table. If you add new columns to this table. You can send these in the event data.

// page_type can have these values
// home / category / product / cart / checkout / promotion / pricing / login / logout / other

// Home page view
dengage("pageView", {
    page_type: "home"
    // ... extra columns in page_view_events table, can be added here
});

// category page view
dengage("pageView", {
    page_type: "category",
    category_path: "Electronics > Laptop" //category path here
    // ... extra columns in page_view_events table, can be added here
});

// product page view
dengage("pageView", {
    page_type: "product",
    product_id: '123' //product id here
    category_path: "Electronics > Laptop", //category path here
    price: 100.50, //price
    discounted_price: 80.50, //if there is no discount, give the same price
    stock_count: 1, //If stock count is not available you can give 1 or 0 as stock availability info, or you can omit
    // ... extra columns in page_view_events table, can be added here
});

// promotion page view
dengage("pageView", {
    page_type: "promotion",
    promotion_id: '123' //promotion id here
    // you can add product_id and category_path too
    // ... extra columns in page_view_events table, can be added here
});

// for cart, checkout, pricing, login, logout pages
dengage("pageView", {
    page_type: "cart", // cart / checkout / pricing / login / logout
    // ... extra columns in page_view_events table, can be added here
});

// for the others
dengage("pageView", {
    page_type: "other"
    // ... extra columns in page_view_events table, can be added here
});