> Documentation index: https://docs.zernio.com/llms.txt. Every page is also Markdown: add .md to its URL.

# Conversions

Send purchases, leads and shopping events to the Spotify Conversions API from your backend, matched by IP address and hashed email, and counted once with the Spotify Pixel.

`POST /v1/events` sends your conversions to the Spotify Conversions API. The destination is the connection's Connection ID.

## Send a conversion event

Name the Spotify Ads account and its Connection ID. Send the visitor's IP address and email, and the same `eventId` your Spotify Pixel sends:

```bash
curl -X POST "https://zernio.com/api/v1/events" \
  -H "Authorization: Bearer $ZERNIO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "profileId": "PROFILE_ID",
    "destinations": [{ "accountId": "ACCOUNT_ID", "destinationId": "0f8fad5b-d9cb-469f-a165-70867728950e" }],
    "events": [{
      "eventName": "Purchase",
      "eventTime": 1798804800,
      "eventId": "order_12345",
      "value": 25.00,
      "currency": "USD",
      "sourceUrl": "https://shop.example.com/checkout/thank-you",
      "user": { "email": "ana@example.com", "ipAddress": "203.0.113.7" }
    }]
  }'
```

To send every conversion to Spotify without naming it each time, create a [forwarding rule](/conversions/create-forwarding-rule) for the account instead.

## Event names

Zernio maps the standard names to Spotify's events:

| `eventName` | Spotify event | Also needs |
|---|---|---|
| `PageView` | `VIEW` | |
| `ViewContent` | `PRODUCT` | |
| `AddToCart` | `ADD_TO_CART` | |
| `InitiateCheckout` | `CHECK_OUT` | |
| `Purchase` | `PURCHASE` | `value` other than 0 and `currency` |
| `Lead` | `LEAD` | |
| `CompleteRegistration` | `SIGN_UP` | |

Spotify's own names `CUSTOM_EVENT_1` to `CUSTOM_EVENT_5` go as is. Any other name is refused. Rename an event in the forwarding rule when yours is named otherwise.

## Match keys

Each event needs one of these:

- `user.ipAddress`, sent as is. Spotify matches on it alone.
- `user.email`. Zernio trims and lowercases it and sends its SHA-256 hash; an email you already hashed with SHA-256 goes as is.
- `user.phone`, with its country code. Zernio sends the SHA-256 of the country code and number, digits only.

Name, location, `externalId`, user agent and click ids are not sent.

## What else is sent

- `eventId` as Spotify's `event_id`.
- The event time as `event_time`, ISO 8601. Spotify refuses events older than 30 days.
- `value` and `currency` as `amount` and `currency`, only together, and the first item's `name` as `content_name`.
- `sourceUrl` as `event_source_url`, when it starts with `http://` or `https://`.
- `actionSource`: `web` (or none) as `WEB`, `app` as `APP`, anything else (`offline`, `crm`, `phone_call`) as `OFFLINE`.

## Dedup with the Spotify Pixel

Spotify counts an event once by its `event_id`, whether it came from the Spotify Pixel or the Conversions API.

Send the same `eventId` your pixel sends for the event, and you can keep both running.

## From the Zernio tag

A forwarding rule sends Spotify your site's conversions and funnel steps (product views, carts and checkouts) from visitors with an IP address, which every site visit has.

## Consent

- Without `adUserData` consent, the email and phone are left out: only the IP address is sent, with `opt_out_targeting` so Spotify uses the event for measurement only.
- Without `adPersonalization` consent, the event is sent with `opt_out_targeting`.
- On profiles created since 22 November 2026, an event from the EEA, UK or Switzerland is sent only with `adUserData` granted and no ad signal denied. See [Consent](/products/server-side-tracking/consent).

## Test mode

Spotify has no test mode for the Conversions API, so an event sent with `testCode` is skipped (`TEST_MODE_UNSUPPORTED`), nothing is sent: `POST /v1/events` lists it in `skipped`, not in `failures`.

Check the **Events** activity graph in Spotify Ads Manager after your first live events. They can take 20 minutes to show.

## How it behaves

- One request per event, five at a time. Spotify refuses a whole request for one bad event without naming it, so each event goes alone.
- A `429`, a `5xx` or no answer is retried: Spotify drops a repeat by `event_id`.
- A `401` or `403` on every event means Spotify refused the token: the send fails with `reconnect_required`.
- In the first 30 minutes after you connect, Spotify may still be turning a new token on, so Zernio sends those events again instead.
- Spotify cannot take a refund or a change back, so a retracted event stays counted there.

## If it fails

| Error | Cause | Fix |
|-------|-------|-----|
| `Spotify needs a match key …` | No `ipAddress`, `email` or `phone` | Send the visitor's IP address. |
| `Spotify takes PageView, ViewContent, …` | The event name has no Spotify event | Rename it in a forwarding rule. |
| `Spotify needs the currency on a purchase` | No `currency` on `Purchase` | Send the ISO currency code. |
| `Spotify needs a purchase amount other than 0` | `value` is 0 or missing on `Purchase` | Send the order value. |
| `Spotify accepts conversion events up to 30 days …` | The event is older than 30 days | Send events as they happen. |
| `Spotify 400: …` | Spotify refused the payload | Fix the field Spotify names. |
| `destinationId must be this connection's Spotify connection ID` | Another id was sent | Use the id from `GET /v1/ads/conversions/destinations`. |
| `401` with `reconnect_required` | Spotify refused the token, or the connection has none | Generate a new token and [connect again](/platforms/spotify-ads/connect). |

## Related

- [Send events](/conversions/send-events)
- [Create a forwarding rule](/conversions/create-forwarding-rule)
- [Consent](/products/server-side-tracking/consent)
- [Limits and errors](/platforms/spotify-ads/reference)