Anti·Click

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.

  1. 1Copy the snippet from Sites → your site.
  2. 2Paste it immediately before the closing </head> tag.
  3. 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

FieldTypeRequiredNotes
siteKeystringYesYour site's public key. Identifies the site; authorises nothing.
landingUrlstringNoThe full URL the visitor landed on. Click ids and utm_campaign are read from it.
referrerstringNodocument.referrer, if any.
clickIdstringNogclid, msclkid or fbclid. Read from landingUrl when omitted.
clickSource"google" | "meta" | "microsoft" | "direct"NoWhich network the click id came from.
campaignstringNoCampaign name, usually from utm_campaign.
screen{ w: number, h: number }NoScreen dimensions in CSS pixels.
timezonestringNoIANA timezone, e.g. Europe/Istanbul.
languagestringNonavigator.language.
interactionDeltanumberNoMilliseconds from page entry to first interaction. Null when none happened.
loadTimenumberNoPage load duration in milliseconds.
signalsobjectNoDevice 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.

StatusCodeMeaning
202okAccepted for processing. The snippet ignores the body.
400invalid_jsonThe body was not JSON.
400invalid_payloadA field failed validation. The response lists which.
403origin_not_allowedThe Origin is not on that site's allowlist.
404unknown_siteNo site has that key. Usually a typo or a deleted site.
413payload_too_largeThe body exceeded 4 KB.
429rate_limitedMore than 60 requests in a minute from one IP. Retry-After is set.