Docs/Revenue/Track revenue & purchases

Track revenue & purchases

Send purchases so Dzati attributes revenue to its source.

When you tell Dzati about a sale, it does more than add up money — it attributes that revenue back to the first touch that brought the customer in, so you can see which channels, campaigns and pages actually drive sales.

Send a purchase

A purchase is a custom event:

js
dzati.track('purchase', {
  order_id: 'ORD-10492',   // required — your unique order reference
  value_cents: 4900,       // required — $49.00, in the smallest currency unit
  currency: 'USD'          // optional — defaults to your site currency
});
  • value_cents is the real total you charged, in the smallest unit (cents, pence). $49.00 → 4900.
  • order_id uniquely identifies the order. Dzati de-duplicates on it, so a page reload or retry never double-counts the sale.

Where revenue shows up

  • A Revenue KPI and a revenue line on the main chart.
  • Revenue split by source, campaign, country and page — every breakdown panel can show the money behind it.
  • Per-person lifetime value on the People view.
Note: Attribution is first-touch — the sale is credited to where the customer originally came from, not the last click before buying. To refund a sale, see Refunds & net revenue.