For a shop on its own platform or any CRM. About an hour of work: one HTTPS request when an order is paid or a deal is won. The key comes from the account owner (Kunads → Connections → Custom shops, or Leads & CRMs → API).
curl -X POST https://app.kunads.ai/api/import \
-H "Authorization: Bearer kimp_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{"orders": [{
"id": "1001",
"date": "2026-10-05T14:30:00+03:00",
"value": 59.80,
"currency": "EUR",
"status": "paid",
"email": "buyer@example.com",
"gclid": "Cj0KCQjw…",
"utm_source": "google", "utm_medium": "cpc", "utm_campaign": "brand",
"items": [{"sku": "PB-250", "name": "Peanut butter 250 g", "quantity": 2, "price": 13.80, "cost": 5.60}]
}]}'curl -X POST https://app.kunads.ai/api/import \
-H "Authorization: Bearer kimp_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{"deals": [{
"id": "D-501",
"date": "2026-10-03",
"value": 4500,
"lead_date": "2026-09-12",
"email": "client@example.com",
"fbclid": "IwAR1x…",
"utm_campaign": "leadform-autumn"
}]}'https://app.kunads.ai/api/import?kind=deal. For orders, leave out ?kind=deal.Authorization: Bearer kimp_…. Body: JSON or form fields, one deal per call.{"ok": true, …}. The deal shows on the account the same day.The email or the click id is what lets Kunads send each won deal back to Meta and Google, so they learn which people actually buy, not just who fills in a form.
| Field | Meaning | |
|---|---|---|
id | required | Your order or deal number. Sending the same id again updates it — refunds, status changes. |
date | required | When it was paid (orders) or won (deals). ISO 8601; a time zone is welcome. |
value | required | What it is worth, excluding VAT and shipping if you can — that is what profit is worked out from. |
currency | ISO code. Left out, it is taken as your account's currency. | |
status | Anything containing cancel, refund, fail or lost is stored at 0. | |
email / customer | Lets Kunads count repeat customers. Kept only for that. | |
gclid, fbclid | The click id from the visit — the strongest link from a sale to the exact ad. | |
utm_source, utm_medium, utm_campaign | How the visitor arrived, when there is no click id. | |
lead_date | Deals: when the lead came in, so Kunads can measure time to close. | |
items | Orders: lines with sku, name, quantity, price and cost — per-product margin. |
Content-Type: text/csv and a header row (?kind=deal for deals). Templates: orders, deals.{"ok": true, "stored": 120, "skipped": 0}. A wrong key gets 401; rows without id, date or value are skipped and counted.