MediaMath
Datafly Signal reports conversions and reach events to MediaMath (TerminalOne / T1) by firing the MathTag event pixel server-side. Because Signal fires the pixel from your own infrastructure rather than the browser, delivery is unaffected by ad blockers and browser tracking prevention, and identity matching uses deterministic ConnectedID keys (SHA-256 hashed email and customer ID) instead of third-party cookies.
MediaMath does not publish a JSON conversions API. Conversions are reported by firing the MathTag pixel (a GET request whose fields ride on the URL query string). Signal fires this pixel server-side. Confirm the exact pixel path and variable slots against a live TerminalOne tag for your account before going live.
Prerequisites
Before configuring MediaMath in Signal you need two identifiers from your MediaMath account team or the TerminalOne platform:
Step 1: Find your Advertiser ID
- Log in to TerminalOne (T1).
- Your Advertiser ID is the value passed as
mt_adidon any MediaMath pixel for the advertiser. Your account team can also provide it directly.
Step 2: Find or create your Pixel ID
- In TerminalOne, go to Admin > Pixels.
- Open the conversion (event) pixel you want Signal to fire, or create a new one.
- Note the Pixel ID — this is the value passed as
mt_idon the pixel tag. - Note which variable slots the pixel is configured to read (see Pixel Variables below). MediaMath pixels read value into
v1–v3(numeric) and strings intos1–s3; the exact slot for value, currency, and order ID is set per-pixel in TerminalOne.
Step 3: Enable ConnectedID matching (recommended)
Server-side pixel fires have no browser cookie, so matching relies on deterministic keys. Ask your account team to confirm ConnectedID is enabled on the advertiser so that hashed email (mt_exem) and hashed customer ID (mt_excl) can be matched to MediaMath users.
Configure in Signal
Configuration Fields
| Field | Required | Description |
|---|---|---|
pixel_id | Yes | Your TerminalOne Pixel ID (the mt_id value). Found in TerminalOne under Admin > Pixels. |
advertiser_id | Yes | Your TerminalOne Advertiser ID (the mt_adid value). Provided by your MediaMath account team. |
Management UI Setup
- Go to Integrations > Add Integration > MediaMath.
- Choose the Default preset (page reach + Order Completed conversion).
- Enter your
pixel_idandadvertiser_id. - Select the consent categories that gate delivery (typically
advertisingormarketing). - Click Save.
The MathTag pixel has no consent parameter on the wire. Consent is enforced by Signal at the pipeline level via the integration’s consent categories — events are only delivered when the visitor has granted the selected category. Make sure you select the correct category.
API Endpoint
GET https://pixel.mathtag.com/event/js
?mt_id={pixel_id}&mt_adid={advertiser_id}
&mt_exem={sha256_email}&mt_excl={sha256_customer_id}
&v1={value}&s1={currency}&s2={order_id}All fields travel on the URL query string; there is no request body and no authentication header — the conversion is identified by mt_id + mt_adid. A mobile in-app variant (/event/mob) is also available for app-sourced events, which additionally requires a device ID (mt_uuid) and ID type (mt_idt: idfa / aaid).
Identity Signals
MediaMath matches server-side pixel fires deterministically using SHA-256 hashed identifiers (ConnectedID). Signal hashes these server-side before the request leaves your infrastructure — raw PII never reaches MediaMath.
| Signal | Wire param | Hashing | Description |
|---|---|---|---|
mt_exem | SHA-256, trimmed, lowercased | User’s email address | |
| Customer ID | mt_excl | SHA-256, trimmed, lowercased | Your stable customer/account ID (Signal user_id) |
How to send identity
Call datafly.identify() when a user logs in, registers, or submits a form:
datafly.identify("user-123", {
email: "jane.doe@example.com"
});Signal normalises and SHA-256 hashes the email into mt_exem and the user_id into mt_excl automatically before firing the pixel.
Pixel Variables
MediaMath pixels expose numeric value slots (v1–v3) and string slots (s1–s3). The Default preset uses:
| Slot | Type | Used for |
|---|---|---|
v1 | numeric | Conversion value / revenue |
s1 | string | Currency code (e.g. USD) |
s2 | string | Order / transaction ID |
s3 | string | Page URL (page events) |
Which slot a pixel actually reads is configured per-pixel in TerminalOne. If your pixel is wired differently (for example value into v2, or currency into s2), edit the integration’s Field Mappings in the Management UI to match.
Event Mapping
Default preset
| Signal event | MathTag fire |
|---|---|
page | Reach pixel (page URL in s3) |
Product Viewed | Pixel with value (v1), currency (s1), product id (s2) |
Order Completed | Conversion pixel with value (v1), currency (s1), order id (s2) |
All other events are dropped (defaults.action: drop). The MathTag pixel has no per-event conversion-type parameter — the Pixel ID itself denotes the conversion, so to track multiple distinct conversion types, attach a separate MediaMath integration (with a distinct pixel_id) per type.
Example: Order Completed (purchase)
Datafly.js call:
datafly.identify("user-123", { email: "jane.doe@example.com" });
datafly.track("Order Completed", {
order_id: "ORD-001",
revenue: 129.99,
currency: "USD"
});Pixel fired by Signal:
GET https://pixel.mathtag.com/event/js?mt_id=1234567&mt_adid=987654&mt_exem=5e8848...&mt_excl=9f86d0...&v1=129.99&s1=USD&s2=ORD-001Testing
Fire a test event
Trigger an Order Completed event on a page where Datafly.js is loaded, with your MediaMath integration enabled and consent granted.
Inspect the outbound request in Signal
Open the Signal Event Debugger for the pipeline and confirm the outbound request goes to pixel.mathtag.com/event/js with mt_id, mt_adid, v1, s1, s2, and (when a user is identified) mt_exem populated. The pixel returns 200/204 for any well-formed request.
Confirm in TerminalOne
In TerminalOne, open Reports > Reach & Conversions for the advertiser. Conversions reported via the pixel appear in conversion reporting (allow for the platform’s reporting delay). Cross-check the value and order count against the events you fired.
Troubleshooting
| Problem | Solution |
|---|---|
| Conversions not appearing in TerminalOne | Confirm mt_id and mt_adid are correct for the advertiser, and that the pixel is active in TerminalOne. The pixel returns 200 even for unattributed hits, so a 200 does not guarantee a match. |
| Value or currency missing in reporting | The pixel may read a different variable slot. Check which v/s slots your pixel is configured for in TerminalOne and adjust the Field Mappings. |
| Low match rate | Ensure datafly.identify() is called so mt_exem/mt_excl are populated, and confirm ConnectedID is enabled on the advertiser. Server-side fires have no cookie, so deterministic match keys are the primary signal. |
| Events not delivered at all | Check the integration’s consent categories — events are gated by consent at the pipeline level. Verify the visitor granted the selected category. |
MediaMath was acquired (Infillion) in 2023. Confirm your advertiser account and the MathTag pixel infrastructure are still active with your account team before relying on this integration.