> ## Documentation Index
> Fetch the complete documentation index at: https://docs.migma.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Events and conversion tracking API

> Report customer events and attribute revenue to the emails that earned the click

Adds `POST /v1/events` and `/v1/events/batch` so your backend can report customer events like purchases, trials, and refunds. Send a single event with an **Idempotency-Key** header, or batch up to 500 events with per-row dedupe keys and row-level partial success.

An event that carries an order identifier and a numeric value is recorded as a conversion and attributed to the last email the recipient clicked within the previous five days, credited once. Event names containing refund or cancelled record negative amounts, so returned revenue is subtracted instead of counted.

Conversions and revenue then appear in campaign stats, shown only when real activity has been reported so a campaign with no attributed revenue shows no figures rather than fake zeros. Events never change subscription status.

[Events](/events) · [API reference](/api-reference/introduction)
