JTL-Shop Plugin
Native JTL-Shop integration for automatic e-commerce event tracking without custom JavaScript.
Native JTL-Shop integration for automatic e-commerce event tracking — no custom JavaScript required.
Install the plugin
Install the plugin ZIP through the JTL plugin manager, or install it from the JTL Extension Store.
Connect to Tugus
There are two ways to connect the shop. Pick one — you don't need both.
Option A — Connect with Tugus (recommended)
One click, nothing to copy by hand.
In the plugin, click Connect with Tugus. You sign in to Tugus once and confirm your shop domain.
Tugus creates the website for you and writes the API key (and the CNAME, if used) back into the plugin automatically — no domain or token to copy.
Tick the events you want to track. Done.
Option B — Manual
Enter the credentials yourself.
In Tugus, open Settings → Websites → your website → API Key and copy the key (create the website first if it doesn't exist yet).
In the plugin settings, paste the API key. For first-party tracking, also enter your CNAME subdomain (e.g. metrics.yourshop.com).
Tick the events you want to track.
Tracked events
Tick the events you want in the plugin settings. Each is available client-side (JS SDK) and — with server-side tracking on (see Settings) — additionally over CAPI.
| Event | Fires on |
|---|---|
| pageview | Every page |
| view_item_list | Category / listing page |
| view_content | Product detail page |
| add_to_cart | "Add to cart" click |
| view_cart | Cart page |
| initiate_checkout | Checkout start |
| add_shipping_info | Checkout — shipping method |
| add_payment_info | Checkout — address + payment |
| purchase | Order confirmation page |
| search | Search results page |
Two more run server-side only:
refund— sent when an order is cancelled in JTL-Wawi. Tugus nets it against the original purchase by order number, so cancelled revenue doesn't linger.- Identify — sends logged-in customer data to Tugus to build the profile and improve match rates (Meta CAPI et al.).
Settings
Tracking mode
A single Server-side tracking (CAPI) master switch controls the mode:
- Off → Client-Side (JS): events fire from the browser only.
- On → Hybrid: every event is also sent server-side in parallel. The client supplies browser context (URL, referrer, UTM, click IDs, IP/UA, consent), the server the reliable copy (revenue, COGS, customer data); Tugus deduplicates the two into one event. More reliable and ad-blocker-safe.
Price mode
Choose which prices are sent as tracking values:
- Gross (B2C) — default.
- Net (B2B).
Payload structure
The plugin posts server-to-server to POST /collect/{api_key}. Commerce fields
must be nested inside a data object — the same
envelope every server-side sender uses.
A purchase looks like this on the wire:
{
"event": "purchase",
"event_id": "purchase_12345",
"data": {
"order_id": "12345",
"value": 179.80,
"currency": "EUR",
"contents": [
{ "id": "SKU-1", "name": "Sneaker X", "price": 89.90, "quantity": 2 }
]
},
"user": { "email": "kunde@example.com", "country": "DE" }
}Troubleshooting
CAPI HTTP 422: The data.value field is required. (and 1 more error)
The purchase was sent without data.value / data.currency, or with value
and currency at the top level instead of inside data. For purchase and
refund both are required and must sit inside data. Fixes:
- Nest
value,currency,order_id,contentsinside thedataobject (see above) — not at the top level next toevent. - Send
valueas a number with a.decimal separator (179.80), never a locale-formatted string like"179,80". - Send
currencyas a 3-letter ISO 4217 code (EUR).