Skip to content
adscapi

Yandex CAPI Payload Preview

The server-side request adscapi builds when you track() a purchase and Yandex is configured. Secrets and hashed values show as placeholders.

Request

POST
Endpoint
https://api-metrika.yandex.net/management/v1/counter/{YANDEX_COUNTER_ID}/offline_conversions/upload
Headers
Authorization: OAuth {YANDEX_METRICA_TOKEN}
Body (purchase example)
{
  "file": {
    "name": "conversion.csv",
    "type": "text/csv",
    "content": "Target,DateTime,UserId,Yclid,PurchaseId,Price,Currency\npurchase,1739452800,order_1001,yclid-example-123,order_1001,49.99,USD\n"
  }
}

Verified against the library dispatcher (src/dispatchers/yandex.ts). See the Yandex setup guide for where to get each secret.

Required secrets

YANDEX_COUNTER_IDYANDEX_METRICA_TOKEN

Yandex activates when every secret is present. One missing key and the platform no-ops — the rest still receive the event.

Event-name mapping

Canonical eventYandex receives
page_viewpage_view
leadlead
signup_startsignup_start (custom event passthrough)
signupsignup
checkout_createdcheckout_created
purchasepurchase
reply_generatedreply_generated (custom event passthrough)
upgrade_clickedupgrade_clicked (custom event passthrough)

Good to know

  • Not JSON: the body is a CSV file uploaded as the multipart form field `file`.
  • The token goes in the Authorization header with the OAuth scheme: `OAuth <token>`.
  • Target is a Metrica goal ID, not a fixed enum; the advertiser must create a matching JavaScript-event goal first.
  • No PII is sent: matching rides on the Yclid click id, UserId, or PurchaseId columns.

Frequently Asked Questions

Related Tools

Discover more free tools to fix your tracking

Event Payload Playground

Pick a canonical conversion event, fill the fields, and see the exact JSON payload adscapi builds — before you write a line of code.

Try it now

PII Hash Previewer

Type a raw email or phone number and see the normalized value plus its SHA-256 hash — the exact rules adscapi applies per platform. Nothing leaves the browser.

Try it now

Platform Coverage Explorer

Search all 26 ad platforms adscapi dispatches to — support level, required secrets, and setup docs, always in sync with the library registry.

Try it now

Ready to track Yandex conversions server-side?

adscapi is free and open source. Set your platform tokens, call track() once, and every configured Conversions API receives the event — hashed the way each platform expects.