Skip to main content
The Veriox Worker is a lightweight Cloudflare Worker that runs on your account, under your domain. It intercepts page requests, checks for a valid session cookie, and injects the verification trigger when needed.

1. Get your private key and worker code

In portal.veriox.io, go to Workers and create a new worker (or open an existing one).
  • Copy the private key shown after creation — it’s displayed only once. Your worker signs every request with it; Veriox only ever stores the matching public key.
  • On the worker’s Install page, click Download worker to get veriox-worker.js. This file is personalised to your worker — your Worker ID is already built in.
Keep your private key secret and never commit it to version control. You’ll set it as a Cloudflare Worker secret (not a plain variable) so it’s encrypted and never exposed in logs or source.

2. Create a project

Put the downloaded veriox-worker.js in a new folder alongside a wrangler.toml:
name = "my-site-age-verification"
main = "veriox-worker.js"
compatibility_date = "2024-05-01"
compatibility_flags = ["nodejs_compat"]
There are no settings to configure here — your Worker ID is baked into the code, and all verification options (age, network, session length, excluded paths) are managed in the portal.

3. Set your private key as a secret

wrangler secret put VERIOX_PRIVATE_KEY
Paste your private key when prompted. This stores it encrypted in Cloudflare — it is not visible after this point. This is the only secret you need to set.

4. Deploy

wrangler deploy
Wrangler will output the worker URL. The worker is now deployed to your Cloudflare account and ready to be routed.

Next step

Configure your site — add the Cloudflare Worker Route so requests flow through Veriox.