Reporting Conversions and Events
Learn how to report purchases and other key events to Pertento using pertentoReportConversion.
2 min read
Pertento uses a reporting function to register conversions and other key events. This function should be executed when a conversion or relevant event has occurred.
For e-commerce, the function should run after a successful transaction. For other use cases, it should run at the appropriate point in the user flow.
pertentoReportConversion('purchase', {
currencyCode: 'EUR',
revenue: xxxxx,
tax: xxxxx,
shipping: xxxxx
})
Event name
The first parameter is the event name.
The example uses "purchase", but this can be changed to match your use case, for example "signup", "lead" or "subscription_start".
Currency and values
- currencyCode can be static (for example "EUR") or set dynamically - enabling a operator to run experiments across multiple currencies simultaneously.
- Significance is calculated separately for each currency
- revenue, tax and shipping should preferably be set dynamically from actual order or event data.
- These fields can be left as zero if not applicable, or set to static values if required, although dynamic values provide more accurate reporting.
- Events that carry no value still requires a currency code, even if NILL
Tracking choice and compatibility
Currently, this reporting method cannot be combined with other tracking integrations for experiment evaluation.
You must choose one of the following approaches:
- 1Pertento native tracking Uses pertentoReportConversion directly. This provides the benefit of including all visitors in experiment tracking, regardless of consent state, since Pertento does not process personal data.
- 2External analytics integration Use an integration such as GA4 or Matomo for experiment evaluation instead of pertentoReportConversion.
Do not mix these methods within the same website setup.
Placement
Call pertentoReportConversion only after the Pertento script has loaded and the event has actually occurred. For e-commerce, this is typically on the order confirmation or thank-you page.