--- title: "User Interaction Tracking (Standalone)" slug: "mapp-fashion-user-interaction-tracking" updated: 2026-09-30T13:06:47Z published: 2026-09-30T13:06:47Z canonical: "docs.mapp.com/mapp-fashion-user-interaction-tracking" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.mapp.com/llms.txt > Use this file to discover all available pages before exploring further. # User Interaction Tracking (Standalone) ## 1 Overview User Interaction Tracking records key steps in a shopper’s online experience, from browsing products to completing an order. It provides a unified view of customer behavior across touchpoints. This tracking is powered by the Standalone Tracking. Once implemented, it automatically links events across sessions, allowing detailed analysis of engagement and conversions. ### Prerequisites Before you begin, make sure you have installed the Standalone Tracking. > [!NOTE] > Note: > > Always trigger a `pageView` event before other tracking events (such as PDP, PLP, or Order) to ensure proper session linking and accurate reporting. --- ## 2 Tracking Events and Functions Each of the following tracking methods captures the shopper’s key interactions. Use these calls to record the corresponding actions. --- ### 2.1 Page View Tracking Tracks when a shopper views a page. This function is essential for linking all subsequent events, especially when the user has multiple tabs open. ```javascript Dressipi("track", "pageView"); ``` --- ### 2.2 Identify (Customer Identification) Connects customer actions before and after login. Use this function when a customer: - Logs in - Registers a new account - You can also include customer identity details in the order event to link purchases with known users. ```javascript Dressipi("track", "identify", {  email: "customer@example.com",   // pseudonymised automatically  customerId: "id_from_your_database_here" }); ``` **Parameters** | Parameter | Type | Description | | --- | --- | --- | | `email` | String | Customer email. Automatically pseudonymised (hashed), but not fully anonymised. | | `customerId` | String | Stable unique identifier, such as a database ID. | Do not send raw names or other personally identifiable information (PII). --- ### 2.3 Product Detail Page (PDP) /itemView Captures when a shopper views a specific product detail page or product view. Use this function when a shopper: - Opens a product detail page - Switches to another product variant (for example, colour or size) - Views products dynamically loaded through JavaScript (trigger a new PDP call for each view) `pdp` and `itemView` are internally identical and can be used interchangeably. Always ensure a `pageView` event is tracked before calling this function. ```javascript Dressipi("track", "pdp", { // you can use 'itemView'instead of 'pdp'  sku: "ABC123",  productCode: "XYZ789" }); ``` **Parameters** | Parameter | Type | Description | | --- | --- | --- | | `sku` | String | Product SKU (unique item identifier). | | `productCode` | String | Style ID of the product (style and colour). Not the product ID. | > [!NOTE] > Note: > > Both `sku` and `productCode` are mandatory parameters. Always provide both for accurate tracking and reporting. --- ### 2.4 Product Listing Page (PLP) Tracks interactions across product listing or search result pages. Required if the PLP widget or PLP API is in use. You must track a `pageView` before calling this. ```javascript Dressipi("track", "plp", {  items: [    { sku: "ABC123", productCode: "XYZ" },    { sku: "DEF456", productCode: "LMN" }  ],  filters: [    { name: "Style", selected: ["Casual", "Evening"] }  ],  page: { number: 1 } }); ``` **Parameters** | Parameter | Type | Description | | --- | --- | --- | | `items` | Array | List of product objects (`sku`, `productCode`). | | `filters` | Array | Any applied filters. | | `page.number` | Number | Page number (1-indexed). | --- ### 2.5 Add to Basket / Remove from Basket Use this function when a shopper adds or removes a product from their basket. ```javascript Dressipi("track", "addToBasket", {  sku: "ABC123",  quantity: 1,  name: "Dress",  category: "Dresses",  unitPrice: 12.99,  currency: "GBP" }); Dressipi("track", "removeFromBasket", {  sku: "ABC123",  quantity: 1,  name: "Dress",  category: "Dresses",  unitPrice: 12.99,  currency: "GBP" }); ``` **Parameters** | Parameter | Type | Description | | --- | --- | --- | | `sku` | String | Product SKU. | | `quantity` | Number | Quantity of items added or removed. | | `name` | String | Product name. | | `category` | String | Product category. | | `unitPrice` | Number | Unit price of the product. | | `currency` | String | ISO currency code (e.g., “GBP”, “EUR”). | --- ### 2.6 Order Confirmation Captures completed orders. At least one line item with a valid `sku` and `quantity` is required. ```javascript Dressipi("track", "order", {  orderId: "1234567",  total: 104.99,  tax: 19.99,  shipping: 5,  currency: "GBP",  lineItems: [    {      sku: "ABC123",      name: "Red Dress",      price: 99.99,      quantity: 1,      currency: "GBP"    }  ] }, { customerId: "CUST123", email: "customer@example.com" }); ``` **Order Validation** An order is considered invalid if: - No line items are provided, or - A line item has no `sku` or `quantity`. **Order Parameters** | Parameter | Type | Description | | --- | --- | --- | | `orderId` | String | Unique order identifier. | | `total` | Number | Total order value. | | `tax` | Number | Tax amount. | | `shipping` | Number | Shipping cost. | | `currency` | String | ISO currency code (e.g., “GBP”). | **Line Item Parameters** | Parameter | Type | Description | | --- | --- | --- | | `sku` | String | Product SKU. | | `name` | String | Product name. | | `price` | Number | Price per unit. | | `quantity` | Number | Quantity ordered. | | `currency` | String | Currency code. | > [!NOTE] > **Note:** The `list_price` field is not supported. --- ### 3 Automatically Captured Parameters In addition to the specified fields, the Standalone Tracking automatically captures contextual data such as: | Parameter | Description | | --- | --- | | `sid` | Session ID (new for each session). | | `vid` | Visit count (increments each visit). | | `duid` | Domain User ID (persistent per browser). | | `res` | Screen resolution (e.g., `1920x1080`). | | `vp` | Viewport size (visible browser area). | | `lang` | Browser language (e.g., `en-US`). | | `cs` | Character set (e.g., `UTF-8`). | | `refr` | Referrer URL. | | `dtm` | Device timestamp. | | `stm` | Sent timestamp. | No additional developer configuration is required. --- ## 4 Parameter Reference | **Parameter** | **Applies to** | **Type** | **Required** | **Description** | | --- | --- | --- | --- | --- | | `sku` | PDP, PLP, Order, Basket | String | Yes | Unique item identifier (SKU) | | `productCode` | PDP, PLP | String | Yes | Style ID (style and colour) | | `quantity` | Order, Basket | Number | Yes | Number of items | | `price` | Order | Number | Yes | Product price per item | | `currency` | Order, Basket | String | Optional | Currency code, e.g., “GBP” | | `filters` | PLP | Object | Optional | Selected filter options | | `orderId` | Order | String | Yes | Unique order identifier | | `email` | Identify, Order | String | Optional | Automatically pseudonymised (hashed) | | `customerId` | Identify, Order | String | Optional | Unique customer reference | --- ## 5 Best Practices - Always trigger a `pageView` before other events. - Use `identify` when customers log in or complete an order to link activity across sessions. - Ensure `sku` and `productCode` are provided for PDP tracking. - Validate that each order includes at least one valid line item. - Use consistent `currency` and `orderId` formats across systems.