# Conversions

Send orders, checkouts and custom events to Klaviyo from your backend, under the metric names its flows and segments read.

`POST /v1/events` sends your events to Klaviyo's Events API. The destination is the connection's Klaviyo account id.

## Send a conversion event

Name the Klaviyo account and its account id as the destination. Klaviyo messages your customers, so it needs the email or phone as typed:

```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": "KLAVIYO_ACCOUNT_ID" }],
    "events": [{
      "eventName": "Purchase",
      "eventTime": 1798804800,
      "eventId": "order_12345",
      "value": 25.99,
      "currency": "USD",
      "items": [{ "id": "SKU-1", "name": "Tee", "price": 25.99, "quantity": 1 }],
      "user": { "email": "customer@example.com", "phone": "+14155550123" }
    }]
  }'
```

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

## Event names

| Zernio event | Klaviyo metric |
|--------------|----------------|
| `Purchase` | Placed Order |
| `InitiateCheckout` | Started Checkout |
| `ViewContent` | Viewed Product |
| `AddToCart` | Added to Cart |
| Any other name | Kept as is, up to 128 characters |

These are the names Klaviyo's own ecommerce integrations use, so flows built on them pick the events up.

## Match keys

Each event needs at least one of these, unhashed:

| Field | How it is sent |
|-------|----------------|
| `user.email` | As typed, lowercased. A hashed address is left out |
| `user.phone` | In E.164. It needs its country code (`+` or `00`); a national number is left out |
| `user.externalId` | As `external_id` |

`firstName`, `lastName`, `city`, `state`, `zip` and `country` fill the Klaviyo profile too.

## What else is sent

- `value` and `currency` as the event's value. `items` as `Items` and `ItemNames`, and `sourceUrl` as `URL`.
- `platformData` fields become event properties. On a `Purchase`, `platformData.order_id` (or else `eventId`) is the `OrderId`.
- `eventId` goes to Klaviyo as `unique_id`. Klaviyo keeps one event per profile, metric and id, so a repeated event counts once.

## Consent

- An event whose `consent.adUserData` is `DENIED` is not sent: every Klaviyo event names the person.
- 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).

## How it behaves

- One request per event, five at a time, so each event gets its own answer.
- Klaviyo has no test mode. A request with `testCode` is refused: test against a separate Klaviyo account.

## If it fails

| Error | Cause | Fix |
|-------|-------|-----|
| `Klaviyo needs an unhashed email, a phone with its country code (+...), or an external id.` | No usable match key | Send the email as typed, an international phone or an external id. |
| `Klaviyo metric names are at most 128 characters.` | The event name is too long | Shorten it. |
| `The visitor did not consent to sharing their data, …` | `adUserData` is `DENIED` | Nothing to fix: the event is not sent. |
| `Klaviyo has no test mode: …` | The request has a `testCode` | Drop `testCode`, and test on a separate Klaviyo account. |
| `destinationId must be this connection's Klaviyo account id` | Another id was sent | Use the id from `GET /v1/ads/conversions/destinations`. |
| `401` with `reconnect_required` | Klaviyo refused the saved key | [Connect again](/platforms/klaviyo/connect) with a fresh key. |

## Related

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