Installing BirunX with Google Tag Manager
Two ready-made tags that capture the Google ad click ID and tie it to the order it produced.
Before you start
This guide assumes you have a Google Tag Manager account and that a GTM container is already installed on your store. If it isn't, install it from your store platform first and then come back.
- Publish permission on the GTM container.
- Your BirunX store ID: it is at the top of the dashboard's side menu, with a copy button next to it.
- A purchase event in the dataLayer, or a stable order-confirmation page a trigger can attach to.
Get the two tag files
BirunX ships as two Google Tag Manager tag templates. Download the two files below and import them into your container — the next two sections walk through every click, and a tag imported from a file works exactly as it is with no further setup.
Download the All Pages tagDownload the Purchase tagAdd the All Pages tag
This tag runs on every page and captures the click ID Google adds to the URL when a visitor arrives from an ad. Without it we cannot tie an order back to the ad it came from.
- In your GTM container, go to Templates, and in the Tag Templates box press New. The template editor opens.
- Open the three-dot menu in the editor's top corner and choose Import.
- Pick the birunx-all-pages.tpl file you downloaded, press Save, then close the editor.
- From Tags press New, then Tag Configuration, and choose BirunX — All Pages.
- Paste your store ID into Your Store ID (Required).
- Under Triggering choose the All Pages trigger.
- Name the tag and save it.
Add the Purchase tag
This tag runs once, on order confirmation, and sends us the order number together with the click ID captured earlier. That pairing is its whole job. The order's money — the revenue, the VAT, the shipping — reaches BirunX from your store platform directly, and never from the browser.
- Import the second template the same way: under Tag Templates press New, open the three-dot menu, choose Import, pick the birunx-purchase.tpl file, and press Save.
- Create a new tag and choose BirunX — Purchase under Tag Configuration.
- Paste the same store ID into Your Store ID (Required).
- Under DataLayer Schema pick the schema your platform uses. The next section explains the options.
- Under Triggering choose your store's purchase trigger: usually a custom event named purchase, or a view of the order-confirmation page.
- Name the tag and save it.
Choosing the dataLayer schema
The schema is how your platform writes order data into the dataLayer. Pick the one that matches your platform; if you are not sure, start with the default and check the result in preview mode.
| Option under DataLayer Schema | When to use it |
|---|---|
| Auto (Default) — Detect Schema Automatically | The default. Tries the known schemas in order. Start here. |
| Salla — Use the Order ID override below (map 0.order_id via GTM DLV) | Salla stores. The order ID is filled in by hand; see the note below the table. |
| ecommerce.transaction_id — GA4 Enhanced Ecommerce | GA4 ecommerce. |
| eventModel.transaction_id — GA4 Custom Event | GA4 through a custom event. EasyOrders writes its orders here, and Auto finds them on its own — an EasyOrders store needs no change. |
| ecommerce.purchase.actionField.id — GA Universal | The older Universal Analytics schema. |
| transactionId — Generic Top-Level | Platforms that write the fields at the top level of the dataLayer. |
| Custom — Map the Order ID manually | You point the tag at the order ID yourself. |
Publish and check
- Press Preview in GTM and open your store in the preview window.
- Browse any page and confirm BirunX — All Pages appears under Tags Fired.
- Complete a test order through to the confirmation page, and confirm BirunX — Purchase fired exactly once.
- Come back to BirunX: the Google Tag Manager page in the dashboard shows the first event we received and when it arrived.
- If everything looks right, press Submit and then Publish in GTM.
If nothing arrives
- Check you pressed Publish and not only Preview.
- Check you copied the right store's ID. GTM refuses to save a tag whose ID is not exactly sixteen characters, so a truncated paste is caught immediately — but it cannot tell one store from another, so if you run more than one store, make sure the ID came from the right one.
- Check the GTM container is installed on the order-confirmation page too, not only on the shop pages.
- Open Preview and see whether the tag is listed under Tags Not Fired. If it is, the problem is the trigger, not the tag.
- An ad blocker in your browser can block the tag while you are testing. Try a private window or a different browser.
If it still doesn't work, email us at support@birunx.com with your store name and store ID and we'll take it from there.