Shopping Assistant analytics
Luigi’s Box records the assistant flow automatically from your API calls — which questions are shown, which options shoppers select, and which products are returned (the Assistant Listing event). What it cannot see is what happens after: clicks, add-to-cart, and conversions. Your integration sends those events so the assistant can learn and reporting can connect the flow to business results.
Sending product outcome events
Section titled “Sending product outcome events”Send product clicks and add-to-cart events through either the Events API or the DataLayer collector. Pick the one that matches how your storefront already emits events — both patterns are covered below.
Events API tracking
Section titled “Events API tracking”Send events as a POST request to https://api.luigisbox.com/. The examples below use this helper:
const ANALYTICS_API_URL = "https://api.luigisbox.com/";
async function sendAnalyticsEvent(payload) { await fetch(ANALYTICS_API_URL, { method: "POST", headers: { "Content-Type": "application/json" }, body: JSON.stringify(payload), });}Report product clicks as type: "click" with action.type: "click":
function trackAssistantProductClick(productId) { return sendAnalyticsEvent({ id: crypto.randomUUID(), type: "click", tracker_id: trackerId, client_id: userId, action: { type: "click", resource_identifier: productId, }, });}Report add-to-cart as a conversion event. In the Events API, all product interaction events use type: "click" as the envelope type. The action.type field distinguishes the specific interaction:
function trackAssistantProductAddToCart(productId) { return sendAnalyticsEvent({ id: crypto.randomUUID(), type: "click", tracker_id: trackerId, client_id: userId, action: { type: "add-to-cart", resource_identifier: productId, }, });}Use the same pattern for other meaningful product actions, such as wishlist or compare, with an action type that describes the action.
DataLayer tracking
Section titled “DataLayer tracking”Report product clicks with select_item:
function trackAssistantProductClick(productId) { window.dataLayer.push({ event: "select_item", ecommerce: { items: [ { item_id: productId, }, ], }, });}Report add-to-cart with add_to_cart:
function trackAssistantProductAddToCart(productId, productPrice) { window.dataLayer.push({ event: "add_to_cart", ecommerce: { currency: "EUR", value: productPrice || 0, items: [ { item_id: productId, quantity: 1, }, ], }, });}What to measure
Section titled “What to measure”Use assistant metrics and product outcome metrics together.
| Metric | What it tells you | How to read it |
|---|---|---|
| Assistant starts or activation | Whether users enter the assistant experience. | Low activation can point to weak entry-point placement, unclear teaser copy, or an assistant promise that does not match the page context. |
| Completion rate | Whether users reach the final recommendation state. | Low completion usually points to flow friction: confusing question copy, too many steps, unclear options, or a question order that asks too much too early. |
| Exit rate per question | Which question or answer set causes users to leave. | A spike on one question is a strong signal to review that question’s wording, option design, or necessity. |
| Product click-through rate | Whether the returned products look relevant enough to inspect. | High completion with low product CTR usually means users trusted the flow but did not like the resulting products or product cards. |
| Add-to-cart or conversion rate | Whether assistant results lead to business outcomes. | High CTR with low conversion can point to product detail page, price, stock, or cart friction rather than the assistant flow itself. |
Read these metrics in combination. A high completion rate with low product clicks points to weak final product relevance. A low completion rate points to a flow problem: entry point, question order, question copy, option design, or too much effort.
Common patterns:
| Pattern | Likely interpretation |
|---|---|
| Low activation and low conversion | The assistant entry point may not attract the right users, or the promise is not clear enough. |
| High activation and low completion | Users are interested, but the dialogue asks the wrong questions or takes too much effort. |
| High completion and low CTR | The flow works, but the returned products or product cards are not persuasive. |
| High CTR and low conversion | The assistant is sending users onward, but something after the click is blocking the business outcome. |
Debugging checklist
Section titled “Debugging checklist”Before relying on the dashboard, check the event stream:
- The Assistant API calls use the expected
tracker_id,assistant_handle, and stableuser_id. - Product clicks are sent when the user opens a recommended product.
- Add-to-cart is sent only when the product is actually added to cart.
- The product identifier in the click or add-to-cart event matches the identifier rendered from the assistant hit.
- DataLayer integrations push the expected ecommerce event names and product identifiers into
window.dataLayer. - Events API integrations send unique event
idvalues.
Related pages
Section titled “Related pages”Was this page helpful?
Thanks.