Tracking and attribution

Server-side conversions

Send conversions from your server to the Koast pixel with a server-side key, so ad blockers and cookie rules don't hide them.

Ad blockers and cookie rules hide some conversions from any browser pixel. Server-side conversions close that gap: your server, or your tracker, sends the conversion straight to the Koast pixel with a key you create in Koast. Keep the browser pixel in place too. The two work together.

Koast ad account

Before you start

  • This is for Koast ad accounts, which are provided through our partner Whop.
  • Set up the browser pixel first. See Set up the Koast pixel.
  • You need someone who can change your server code or your tracker's settings.

Create a key

  1. Open Settings, then Pixel, and scroll to Server-side tracking, marked Optional.

  2. Select Create key and give it a name you'll recognise, for example "Checkout server". Names are 2 to 60 characters.

  3. Select Copy key and store the key somewhere safe. It's shown once, so copy it now.

  4. Select I saved it.

Select API instructions to copy a ready-made set of instructions, with your ad account ID already filled in, for your developer or an AI coding agent.

Up to 3 keys per ad account

A key works only for the ad account it was created on, and it can only send conversions. You can't delete keys from Koast yet. If you've used all 3 and need another, message us.

Send an event

Send a POST request to https://api.whop.com/api/v1/events with your key in the Authorization header:

curl -X POST https://api.whop.com/api/v1/events \
  -H "Authorization: Bearer YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{"account_id":"biz_7Qm2NimbusSleep","event_name":"lead","event_id":"order_1234",
       "value":49.99,"currency":"usd","action_source":"website",
       "user":{"email":"buyer@example.com"},
       "context":{"fbclid":"...","ip_address":"...","user_agent":"..."}}'

The event is acknowledged right away and shows up within about 15 minutes.

FieldWhat to send
account_idYour ad account ID, as shown on the Pixel tab. Always send it. The key only accepts that account.
event_nameOne of the supported events below.
event_idThe same ID the browser pixel sends for this conversion, and unique per conversion.
value, currencyThe conversion value. For purchase, the value must be greater than zero.
action_sourceWhere it happened, usually website.
userAs many match keys as you have: email, phone, external_id.
contextAs much attribution as you have: fbclid, fbp, fbc, gclid, ttclid, ip_address, user_agent, utm_source, utm_medium, utm_campaign.

Supported events: lead, complete_registration, submit_application, schedule, contact, view_content, add_to_cart and purchase.

Rules that keep your numbers right

  • Match the browser pixel's event_id. When the browser and your server report the same conversion with the same event_id, it's counted once. Different IDs count it twice.
  • Keep event_id unique per conversion. If a macro such as {txid} isn't filled in, every event carries the same ID and all but the first are dropped as duplicates.
  • Send one IP address, 45 characters at most. If your tracker sends a comma-separated chain of addresses, send only the first one. Anything longer is rejected with "ipAddress is too long (maximum is 45)".
  • Don't resend Whop checkout purchases. Purchases through Whop checkout are already tracked. Send purchase only for sales on your own checkout.

Using ClickFlare? See Send conversions from ClickFlare.

On this page