Other tools
Send events to server-side GTM
Add Server-side GTM as a destination with your container URL. ROASaurus posts each event to it in GA4 Measurement Protocol format, where the container's Measurement Protocol client turns it into event data for any server tag.
You do not need a server container for ROASaurus itself: it sends to the ad platforms from its own server. This destination is for teams that already route data through their own container and want ROASaurus's order-based events there too, for example to feed a tag ROASaurus does not have.
Only events with confirmed marketing consent are forwarded, because the container's tags can send them anywhere. Profit is not forwarded to server-side GTM yet; that is being built.
Before you start
- A running server-side GTM container on your own domain (for example
https://sgtm.yourshop.com). - A Measurement Protocol client in that container (its activation path, by default
/mp/collect). - The owner or admin role in ROASaurus.
Steps
Add a Measurement Protocol client
In your server container, add a client that accepts GA4 Measurement Protocol requests and note its activation path.
Add the destination
In ROASaurus, open Connections › Tracking & destinations, find Server-side GTM under Analytics and data and click Add pixel. Enter the Container URL and, if it differs from
/mp/collect, the Client path.You should see: The destination saved with the events you ticked: page views, product views, adds to cart, checkouts, purchases, leads and refunds can all go out.
Add the optional fields
Fill in the GA4 Measurement ID if your tags expect
measurement_id(it also lets the scripts read the GA4 session cookie), and an API secret if your client checks one. Tick Send the shop customer id as user_id or Send hashed email, phone and address (user_data) if your tags use them.Test in preview mode
In GTM, open Preview › Send requests manually, copy the
X-Gtm-Server-Previewvalue into Preview header, save and place a test order.You should see: The ROASaurus events in the container's preview. Remove the preview header after testing.
What you should see
Data quality › Deliveries lists every forwarded event with status sent and the container's answer.
Common problems
“The container URL must start with https://.”
Deliveries fail with 404
Some purchases are missing in the container
Next step
Connect Google Analytics 4 directlyStill stuck? Email us.