Traffic gate
A quality filter that sits between a traffic source and a monetization page. It scores each visit, and in enforce mode it diverts the visits the rules reject instead of passing them on.
Endpoints
| Path | What it does |
|---|---|
/g?clickid=… | Gate entry. Scores the visit, then serves the JS check page. |
/g/j | JS handshake landing. Verifies the signed token, then redirects onward. |
/api/stats | Aggregate report. Requires the stats token. |
/api/zoneblock | Source blocklist. Read or replace it; changes apply live. |
Modes
observe scores and logs everything but never blocks — this is the
current mode, and the intended one while any platform is reviewing the operation.
enforce applies the verdict. The mode lives in lib/config.js.
What is recorded
Aggregated counts per day, country and local hour; individual records only for flagged visits plus a 2% sample, kept 30 days; and a source blocklist. Raw IP addresses are not stored — they are reduced to a salted one-way hash for a short-window counter, and the address itself is never written. Details are in the privacy note.
traffic-gate.pages.dev · self-hosted, no third-party scripts · privacy note