Skip to main content
Drupal Commerce → The Trade DeskIntegration guide

Connecting Drupal Commerce to The Trade Desk

Drupal Commerce is self-hosted commerce inside a CMS built for complex content, which means the store is one part of a much larger site you fully control. The Trade Desk buys across the open internet rather than inside a walled garden, which means it cannot rely on a logged-in graph and has to work with identity you help it construct. The join between them succeeds or fails on one thing: whether Unified ID 2.0, derived from a hashed email reaches the Drupal Commerce order before the conversion happens, because The Trade Desk can only match a conversion it can tie back to a click it recognizes.

Free30 minutesNo obligation

Specific to this pair

Drupal Commerce to The Trade Desk: UID2 from the order email

The Trade Desk matches on UID2 built from an email, which every Drupal Commerce order carries. Send placed orders server-side from the order placement hook with the normalized hashed email, value, currency and order time, keyed on the order number. Hold out buyers who opted out of sharing or sent Global Privacy Control; Drupal will not filter them.

The Trade Desk matches conversions on UID2, which is built from an email, and every Drupal Commerce order carries one, guest checkout included. Send placed orders server-side from the order placement hook with the normalized, hashed email, value, currency and order time, keyed on the order number so a retry does not count twice. Anonymous browsing that never reaches checkout cannot match, so the addressable share is the share of buyers, not visitors.

Privacy is the constraint that bites on this pair. Sharing a hashed email so an ad platform can match it is likely to count as sharing for cross-context behavioral advertising under California's privacy law, so buyers who used your Do Not Sell or Share mechanism, or whose browser sent a Global Privacy Control signal, should be held out of the upload. Drupal will not do that on its own; record the opt-out against the user or order and filter on it.

Programmatic buying runs alongside search and social, and the same Drupal order will be claimed by all of them. Use the uploads for The Trade Desk's own optimization, and judge incremental value with a holdout or by comparing Drupal revenue in exposed and unexposed regions, not by adding its attributed revenue to everyone else's.

Drupal Commerce → The Trade Desk · what breaks

Why this join usually fails — Drupal Commerce → The Trade Desk

  1. 01

    Unified ID 2.0, derived from a hashed email never reaches Drupal Commerce

    Drupal's internal page cache and any reverse proxy in front of it serve stored renders, so anything relying on dynamically rendered values fails intermittently. Multilingual and multi-site installs add further paths where the capture code may simply not run.

  2. 02

    Configurable workflow states nobody agreed on

    Drupal Commerce lets each install define its own order states. Two people reporting on the same store routinely count different states and never reconcile.

  3. 03

    View-through conversions on the open internet

    A large share of what a DSP claims is view-through: the person saw a display impression and later converted without clicking. Some of that is real influence and some of it is coincidence, and no post-click reporting can separate them. Treat the click-attributed number as the floor and prove the rest with a holdout.

  4. 04

    Nothing reconciles afterwards

    The Trade Desk reports match rates on uploaded conversions. Read the match rate — a low one means your authenticated share is the constraint, and no amount of pipeline work will change that.

Drupal Commerce → The Trade Desk · the fix

What working looks like — Drupal Commerce → The Trade Desk

  • Unified ID 2.0, derived from a hashed email on every order

  • Conversions arriving in The Trade Desk

    The conversion is matched to an impression or click where identity resolves, and feeds the bidding models.

  • Reconciled against the source

Drupal Commerce → The Trade Desk · architecture

How Drupal Commerce and The Trade Desk actually connect

  1. 1

    Drupal Commerce holds the truth

    You own the database, so the truth is exactly as good as the query. Pin down which order states count as revenue before comparing anything — Drupal's workflow states are configurable per install, so no two sites agree by default.

  2. 2

    The Trade Desk needs a click to match

    The Trade Desk needs the conversion with a UID2 or a hashed email it can resolve, plus the value and timestamp. Conversions from anonymous visitors cannot be matched at all.

  3. 3

    The identifier is the bridge

    Unified ID 2.0, derived from a hashed email, captured at the visit and carried into the Drupal Commerce order.

  4. 4

    The event source decides reliability

    Fire server-side from the hook rather than the checkout completion template, which is cacheable and may not execute anything.

  5. 5

    Deduplication at the destination

    Deduplication is on your conversion identifier. Because open-internet buying frequently runs alongside search and social, the more consequential deduplication is across platforms rather than within this one.

Drupal Commerce → The Trade Desk · normal or broken

Working vs. broken, side by side — Drupal Commerce → The Trade Desk

Normal, not a fault

  • Unified ID 2.0, derived from a hashed email present on the order

  • Sent from the Drupal Commerce order placement hook

  • Deduplicated correctly

    Deduplication is on your conversion identifier. Because open-internet buying frequently runs alongside search and social, the more consequential deduplication is across platforms rather than within this one.

  • Reconciles with the source

Actually broken

  • Unified ID 2.0, derived from a hashed email missing on most records

    Drupal's internal page cache and any reverse proxy in front of it serve stored renders, so anything relying on dynamically rendered values fails intermittently. Multilingual and multi-site installs add further paths where the capture code may simply not run.

  • Sent from the browser

    Drupal Commerce lets each install define its own order states. Two people reporting on the same store routinely count different states and never reconcile.

  • Counted twice, or not at all

    A large share of what a DSP claims is view-through: the person saw a display impression and later converted without clicking. Some of that is real influence and some of it is coincidence, and no post-click reporting can separate them. Treat the click-attributed number as the floor and prove the rest with a holdout.

  • Nobody has reconciled it

Drupal Commerce → The Trade Desk · diagnose

Diagnostic order — Drupal Commerce → The Trade Desk

  1. 01

    Count orders carrying Unified ID 2.0, derived from a hashed email

  2. 02

    Follow one real conversion end to end

  3. 03

    List the order states in use and agree which count as revenue

    Do this before any technical work — it resolves more Drupal Commerce disputes than any code change.

  4. 04

    Split reported conversions into click-through and view-through

    If the great majority are view-through, the honest next step is an incrementality test rather than a bid adjustment.

  5. 05

    Read the match rate, not the success message

    The Trade Desk reports match rates on uploaded conversions. Read the match rate — a low one means your authenticated share is the constraint, and no amount of pipeline work will change that.

Drupal Commerce → The Trade Desk · prove

How it gets proven — Drupal Commerce → The Trade Desk

Source of truth

Drupal's commerce_order records in your own database, filtered to completed states.

  • Unified ID 2.0, derived from a hashed email confirmed present on a live order.
  • Matched conversions reconciled against your own order records, with the click-through and view-through split stated.
  • Order field data confirmed populated on an order placed through a fully warmed cache as an anonymous visitor.

Drupal Commerce → The Trade Desk · free audit

What we check in the free audit

  • Count orders carrying Unified ID 2.0, derived from a hashed email
  • Follow one real conversion end to end
  • List the order states in use and agree which count as revenue
  • Split reported conversions into click-through and view-through
  • Read the match rate, not the success message

Checked against

Drupal's commerce_order records in your own database, filtered to completed states.

Get my free conversion tracking audit

Free30 minutesNo obligation

Drupal Commerce → The Trade Desk · when not to buy

When you don't need this — Drupal Commerce → The Trade Desk

  • Measure identifier coverage yourself first — pull your last hundred orders and count how many carry Unified ID 2.0, derived from a hashed email.
  • If your Drupal site is content-only with commerce elsewhere, work at the commerce system instead — this is the wrong layer.
  • If you cannot collect email addresses from a meaningful share of your buyers, UID2 has little to work with and the open internet is not yet an addressable channel for you.

Drupal Commerce → The Trade Desk · what we deliver

What gets built — Drupal Commerce → The Trade Desk

  • Identifier capture into Drupal Commerce

    Capture the identifier and persist it as order field data through a hook on order placement, server-side, so it never depends on what the cache served.

  • Event source: the Drupal Commerce order placement hook

    Fire server-side from the hook rather than the checkout completion template, which is cacheable and may not execute anything.

  • Dispatch to The Trade Desk

    Server-side conversion upload with the hashed identity and value, from your order system.

  • Reversals where they exist

    Order state transitions to refunded or cancelled are recorded and can drive reversals.

Written guarantee

95%+ tracking accuracy

Measured against Drupal's commerce_order records in your own database, filtered to completed states.. Miss it and we keep working at no cost.

Get my free conversion tracking audit

From $400 · See packages

FAQ

Drupal Commerce → The Trade Desk questions, answered

From the order placement hook, with the normalized hashed email for UID2 matching, value, currency, time and the order number as the conversion identifier.

Free · 30 min

Get Drupal Commerce and The Trade Desk joined properly

Free30 minutesNo obligation