Skip to content
Conversions API

Server-side Google Tag Manager

Send CAPI events through the Teads sGTM tag.

Use server-side Google Tag Manager (sGTM) with GA4 when you do not want to POST JSON yourself. Read Getting started first.

sGTM sends the same conversion events as direct integration. Consent is handled through Google Consent Mode (ad_storage) on the Teads tag — leave Require ad_storage consent enabled.

Requirements

  • GA4 already deployed.
  • A CAPI token (see Getting started → Authentication) and buyer pixel ID from TAM Events Manager.
  • GTM web container and server container.
  • Custom domain on the same site as the website for server_container_url (strongly recommended so browsers do not block first-party cookies).

Web container

  1. Google Tag — measurement ID, configuration parameter server_container_url = your server-container URL, trigger Initialization - All Pages.
  2. Custom HTML tag on Initialization - All Pages to measure session duration.
  3. GA4 Event named timespent, trigger custom event timespent.
  4. Existing GA4 Event tags for conversions (add_to_cart, purchase, and so on). Optional event parameters: name, price, currency. One product name per event.

Server container — Teads Conversions API tag

Create a Teads Conversions API (CAPI) tag for each action:

ActionTag settingsTrigger
Page viewToken, buyer pixel ID, action Page ViewAll Pages
Time spentSame, action Page View, event name timespentCustom event timespent
ConversionAction Conversion, conversion type, optional name/price/currencyClient name contains GA4 and event name matches (for example add_to_cart)

The time-spent server tag is configured as Page View with a timespent trigger.

Test, then publish

  1. In each Teads tag, Advanced options → Use testing API (same 1 request / second / token limit as the test endpoint).
  2. Preview the server container, trigger the site action, confirm the tag fires and Event Data looks correct.
  3. Uncheck Use testing API, then Submit in GTM.

Click ID must still reach the page (click_id / auctid) — see Getting started → Click ID. Third-party click trackers need forwarding in TAM creative setup.