Skip to content

Awin

Server-to-server Awin conversion tracking. The tracking-awin app reports a sale when an order is confirmed, so affiliate conversions are recorded without relying on a browser tag.

How it works

  1. OnOrderConfirmed observes orders and, on the not confirmed → confirmed transition, schedules the reactor with the order number.
  2. awin.sale.create loads the order and, only if it carries an Awin click value, sends a GET to Awin's sread.php endpoint.

Attribution: the Awin click value

Awin appends awc=… to the storefront landing URL when a shopper arrives through an affiliate link. The storefront captures and stamps it; Commerce forwards it onto the order:

MeaningOrder field
Awin click valuecart:tracking:awc

An order without an awc did not originate from an Awin affiliate link, so no sale is reported for it.

Capture it on the landing page

awc only appears on the first page view of the affiliate visit. Store it (for example in session storage) as soon as the shopper lands, and stamp it once a cart exists.

Per-channel and per-country advertiser

The advertiser id — and optionally the commission group — resolves from the order's channel and billing country, so one tenant can route each storefront channel, and each country within it, to its own Awin advertiser account.

Both are configured in the Channel editor, under the collapsible "Awin conversion tracking" section: at the channel level, and per country.

Resolution order, most specific first:

  1. Country overrideawinAdvertiserId on channels/{channelKey}/countries/{cc}
  2. Channel valueawinAdvertiserId on the channel
  3. Global default — the advertiserId app setting

commissionGroup resolves the same way, finally falling back to DEFAULT. The country used is the order's invoice recipient country.

If no advertiser id resolves for an order, it is not tracked — the reactor skips it quietly.

The sale request

The sale is reported as a single GET (tt=ss normal sale, ch=aw Awin channel):

https://www.awin1.com/sread.php
  ?tt=ss
  &tv=2
  &merchant={advertiserId}
  &amount={amount}
  &ch=aw
  &parts={commissionGroup}:{amount}
  &vc={voucher}
  &cr={currencyCode}
  &ref={orderNumber}
  &testmode={0|1}
  &cks={awc}
  • amount is the goods value excl. tax and excl. shipping, rounded to two decimals. Tax-inclusive orders have their tax stripped; net shipping is then subtracted per delivery.
  • parts assigns the full amount to a single commission group.
  • vc is the first commerce_couponCodes value, if any.
  • ref is the order number — Awin de-duplicates on it.

Settings

SettingDescription
enabledMaster switch. When off, the reactor does nothing.
advertiserIdDefault Awin advertiser (merchant) id, used when a channel or country has no override.
commissionGroupDefault commission group code for parts (default DEFAULT). Overridable per channel and country.
testModeWhen on, sends testmode=1 so the sale is excluded from reporting.

Verifying

Enable testMode and schedule the reactor for a known order number that carries cart:tracking:awc. The sale then shows up in Awin's interface as a test transaction.

See Also

© 2026 Hantera AB. All rights reserved.