Installing the snippet
One script tag, on every page an ad can land on.
The tag
Your site's own key is on its page under Sites — this is the shape.
<script async src="https://anti-click-production.mesutcandemir39.workers.dev/t.js" data-site="YOUR_SITE_KEY"></script>
Platform guides
Plain HTML
Paste the tag before </head> on every page an ad can land on.
- 1Copy the snippet from Sites → your site.
- 2Paste it immediately before the closing </head> tag.
- 3Deploy, load a landing page, then press Verify installation.
It has to be on the landing pages, not only the homepage. A click that lands on /offers and never sees the snippet is a click we cannot score.
API reference
The snippet posts to POST https://anti-click-production.mesutcandemir39.workers.dev/api/track with content-type: text/plain, which keeps it a CORS-simple request and avoids a preflight on every hit. You only need this if you are reporting clicks from something other than a browser.
Request body
| Field | Type | Required | Notes |
|---|---|---|---|
| siteKey | string | Yes | Your site's public key. Identifies the site; authorises nothing. |
| landingUrl | string | No | The full URL the visitor landed on. Click ids and utm_campaign are read from it. |
| referrer | string | No | document.referrer, if any. |
| clickId | string | No | gclid, msclkid or fbclid. Read from landingUrl when omitted. |
| clickSource | "google" | "meta" | "microsoft" | "direct" | No | Which network the click id came from. |
| campaign | string | No | Campaign name, usually from utm_campaign. |
| screen | { w: number, h: number } | No | Screen dimensions in CSS pixels. |
| timezone | string | No | IANA timezone, e.g. Europe/Istanbul. |
| language | string | No | navigator.language. |
| interactionDelta | number | No | Milliseconds from page entry to first interaction. Null when none happened. |
| loadTime | number | No | Page load duration in milliseconds. |
| signals | object | No | Device signals: webdriver, cores, touch, memory, canvas. |
Responses
The IP, country and User-Agent are read from the request at the edge, never from the body — sending them has no effect.
| Status | Code | Meaning |
|---|---|---|
| 202 | ok | Accepted for processing. The snippet ignores the body. |
| 400 | invalid_json | The body was not JSON. |
| 400 | invalid_payload | A field failed validation. The response lists which. |
| 403 | origin_not_allowed | The Origin is not on that site's allowlist. |
| 404 | unknown_site | No site has that key. Usually a typo or a deleted site. |
| 413 | payload_too_large | The body exceeded 4 KB. |
| 429 | rate_limited | More than 60 requests in a minute from one IP. Retry-After is set. |