Skip to main content
Saleor → TikTokIntegration guide

Connecting Saleor to TikTok Events API

Saleor is headless and GraphQL-first, which means the storefront and the commerce engine are separate applications and the identifier has to survive a boundary that traditional platforms do not have. TikTok's audience skews to exactly the browsers and app contexts where browser-side tracking performs worst. The join between them succeeds or fails on one thing: whether the ttclid reaches the Saleor order before the conversion happens, because TikTok can only match a conversion it can tie back to a click it recognizes.

Free30 minutesNo obligation

Specific to this pair

Saleor to TikTok: ttclid through the headless checkout

Write the ttclid to the Saleor checkout's privateMetadata as soon as the checkout is created, since TikTok's webview may lose storage. Send CompletePayment from the ORDER_FULLY_PAID webhook with the Saleor order number as event_id matching the pixel, order value, currency and hashed email and phone. Store the ttclid against the customer email for carts later paid in Safari.

TikTok ads usually land on a product page of the Saleor storefront inside TikTok's in-app browser, and the visitor may complete checkout there or move to a regular browser. Write the ttclid to the checkout's privateMetadata as soon as a checkout is created, not at payment, because the webview may lose storage between adding to cart and paying.

Send CompletePayment from the ORDER_FULLY_PAID webhook with event_id set to the Saleor order number, the same value the storefront's pixel uses, and value and currency from the order. Include the hashed email and phone from the order as fallback match keys. If your storefront fires the pixel from client-side routing, test that the confirmation event fires once.

TikTok buyers often add to cart in the webview and pay in Safari later, which creates a second checkout on Saleor. The first checkout carries the ttclid and the paying one does not. Check whether your storefront merges a returning user's cart into the existing checkout; if not, store the ttclid against the customer email as well so the paying order can still find it.

Saleor → TikTok · what breaks

Why this join usually fails — Saleor → TikTok

  1. 01

    The ttclid never reaches Saleor

    The storefront holds the browser session; the commerce API holds the order. Nothing carries between them unless the storefront puts it there.

  2. 02

    A storefront that knows the click and an API that holds the money

    Headless architectures split exactly the two things attribution needs to join. If the storefront does not deliberately write the identifier into order metadata, the connection does not exist anywhere.

  3. 03

    The ttclid is lost in the in-app browser

    TikTok traffic arrives through an in-app webview whose storage behavior is inconsistent. An identifier captured but not immediately persisted server-side often is not there by the time the conversion happens.

  4. 04

    Nothing reconciles afterwards

    TikTok Events Manager shows received events and their match status. As with Meta, arriving is not the test — deduplicated and matched is. Reconcile TikTok's reported conversions against the source system for the same window.

Saleor → TikTok · the fix

What working looks like — Saleor → TikTok

  • The ttclid on every order

  • Conversions arriving in TikTok

    Events appear in TikTok Events Manager, deduplicated against the pixel, and become usable for optimization.

  • Reconciled against the source

Saleor → TikTok · architecture

How Saleor and TikTok actually connect

  1. 1

    Saleor holds the truth

    In a headless setup the storefront is one of several possible clients. Attributing from it means measuring one channel of a system designed to have many.

  2. 2

    TikTok Events API needs a click to match

    TikTok matches server events using ttclid where available, falling back to hashed contact information. Both should be sent — the fallback is what carries the events where the click ID did not survive.

  3. 3

    The identifier is the bridge

    The ttclid, captured at the visit and carried into the Saleor order.

  4. 4

    The event source decides reliability

    Send fully paid orders at their net total, sourced from the API.

  5. 5

    Deduplication at the destination

    TikTok deduplicates on event_id, the same pattern as Meta: the pixel and the Events API must send the same event_id for the same conversion. Mismatched IDs mean double counting.

Saleor → TikTok · normal or broken

Working vs. broken, side by side — Saleor → TikTok

Normal, not a fault

  • The ttclid present on the order

  • Sent from the Saleor order webhook

  • Deduplicated correctly

    TikTok deduplicates on event_id, the same pattern as Meta: the pixel and the Events API must send the same event_id for the same conversion. Mismatched IDs mean double counting.

  • Reconciles with the source

Actually broken

  • The ttclid missing on most records

    The storefront holds the browser session; the commerce API holds the order. Nothing carries between them unless the storefront puts it there.

  • Sent from the browser

    Headless architectures split exactly the two things attribution needs to join. If the storefront does not deliberately write the identifier into order metadata, the connection does not exist anywhere.

  • Counted twice, or not at all

    TikTok traffic arrives through an in-app webview whose storage behavior is inconsistent. An identifier captured but not immediately persisted server-side often is not there by the time the conversion happens.

  • Nobody has reconciled it

Saleor → TikTok · diagnose

Diagnostic order — Saleor → TikTok

  1. 01

    Count orders carrying the ttclid

  2. 02

    Follow one real conversion end to end

  3. 03

    Inspect order metadata on a live order for the identifier

    Either it is on the order or the attribution is guesswork. There is no middle state.

  4. 04

    Measure ttclid capture rate on TikTok traffic specifically

    Not on all traffic. TikTok's in-app browser is the failure case, so a healthy overall capture rate can hide a poor one on exactly the traffic that matters.

  5. 05

    Read the match rate, not the success message

    TikTok Events Manager shows received events and their match status. As with Meta, arriving is not the test — deduplicated and matched is. Reconcile TikTok's reported conversions against the source system for the same window.

Saleor → TikTok · prove

How it gets proven — Saleor → TikTok

Source of truth

Saleor orders by payment status, read from the API rather than inferred from the storefront.

  • The ttclid confirmed present on a live order.
  • Deduplication confirmed in Events Manager, and ttclid capture rate measured on TikTok traffic specifically.
  • Paid orders reconciled from the API against imported conversions.

Saleor → TikTok · free audit

What we check in the free audit

  • Count orders carrying the ttclid
  • Follow one real conversion end to end
  • Inspect order metadata on a live order for the identifier
  • Measure ttclid capture rate on TikTok traffic specifically
  • Read the match rate, not the success message

Checked against

Saleor orders by payment status, read from the API rather than inferred from the storefront.

Get my free conversion tracking audit

Free30 minutesNo obligation

Saleor → TikTok · when not to buy

When you don't need this — Saleor → TikTok

  • Measure identifier coverage yourself first — pull your last hundred orders and count how many carry the ttclid.
  • If you run a single storefront and no other clients, the added complexity of headless attribution buys you nothing over a standard integration.
  • If TikTok is a small share of spend, the effort is hard to justify. It pays when TikTok is a channel you are actively scaling.

Saleor → TikTok · what we deliver

What gets built — Saleor → TikTok

  • Identifier capture into Saleor

    Capture in the storefront and write the identifier into order metadata through the API at checkout, so it lives on the order rather than in a session.

  • Event source: the Saleor order webhook

    Send fully paid orders at their net total, sourced from the API.

  • Dispatch to TikTok

    Server events to the TikTok Events API with the ttclid, hashed contact information and a matching event_id.

  • Reversals where they exist

    Refunds and cancellations reverse.

Written guarantee

95%+ tracking accuracy

Measured against Saleor orders by payment status, read from the API rather than inferred from the storefront.. Miss it and we keep working at no cost.

Get my free conversion tracking audit

From $400 · See packages

FAQ

Saleor → TikTok questions, answered

Write it to checkout privateMetadata when the checkout is created, so it survives until payment.

Free · 30 min

Get Saleor and TikTok joined properly

Free30 minutesNo obligation