Use this page when you want Cevoid to receive completed purchase events from your storefront. If you are trying to instrument widget, post, or product interactions, use Using Cevoid Galleries or Manual Event Tracking instead. For the exact manual SDK method surface and payload reference, use SDK API and sale.complete.Documentation Index
Fetch the complete documentation index at: https://docs.cevoid.com/llms.txt
Use this file to discover all available pages before exploring further.
Choose the right sales-tracking path
Shopify storefronts
If your storefront runs on Shopify, Cevoid sales tracking is handled through the Shopify checkout web pixel. That means:- you do not need
@cevoid/analytics-sdkjust to track completed sales - you do not need to call
trackSale()for the standard Shopify setup - you should enable the Cevoid checkout web pixel for each Shopify store that should send checkout events
trackSale() calls for the same storefront. If you run on Shopify, follow the Shopify sales-tracking setup only.
Non-Shopify storefronts
If your storefront is not Shopify, use the manual sales-tracking path. That means:- initialize Cevoid tracking in your storefront
- call
trackSale()when an order is completed - send one completed sale per final order
When to use trackSale()
Use trackSale() when both of these are true:
- your storefront is not Shopify
- you have a final completed order record to send to Cevoid
- order confirmation pages
- checkout success callbacks
- server-confirmed storefront completion handlers
trackSale() before the order is actually completed.
For Shopify storefronts, the supported sales-tracking path is the checkout web pixel. Do not add manual
trackSale() calls on top of it.Why session tracking usually belongs with sales tracking
Cevoid uses the session layer to measure attribution between Cevoid gallery activity and a completed order. That means:- if session tracking is enabled and consent resolves to granted, Cevoid can connect supported gallery interactions and the completed sale through
session_id - if session tracking is not enabled, the sale can still be recorded, but Cevoid usually cannot connect a Cevoid widget event to that order
1. Initialize the SDK
2. Optionally identify the shopper
If you already know the shopper identity, callidentify() first so the conversion event can include that context.
3. Send the completed sale
orderIdcurrencyrevenue
marketIdcustomerIdskus
revenue must be sent as a decimal major-unit amount in the same currency as currency, such as 129.99 USD.
4. Send one event per completed order
Recommended pattern:- choose one stable completion trigger
- send one conversion event per completed order
- prevent duplicates on page reload or repeated callbacks
orderId, so repeated trackSale() calls for the same order do not create multiple counted sales. You should still do your own best-effort deduplication and avoid sending the same order more than once from the client or server.
Avoid sending trackSale() from:
- cart pages
- checkout start events
- optimistic client-side states before payment confirmation
5. Verify the sales flow
After setup:- complete one real or test order through the path you implemented
- confirm the order only triggers one completed sale event from your chosen integration path
- if session tracking is enabled and consent resolves to granted, confirm the sale can include
session_id
trackSale() trigger.
Session note
Session tracking is optional, but it is usually recommended when you want sales attribution. If session tracking is enabled and consent resolves to granted,trackSale() can include a Cevoid session_id.
If consent is denied:
- the conversion event can still be sent
session_idis omitted