Skip to content

Instantly share code, notes, and snippets.

@rikutoe
rikutoe / aeo-canary-deploy.mjs
Created May 13, 2026 22:13
AEO Canary Worker source
// SeedX AEO Canary Worker
// Deployed as: aeo-canary (custom domain: canary.seedx.tech)
// KV binding: LOGS (namespace id df34b1428dce4ac0b2ec51ca153a5a12)
//
// Adds AI bot IP CIDR matching + AS-organization matching on top of the
// existing UA regex. New KV log fields: provider, bot, matchedBy.
// Legacy fields aiBotMatched / isAiBot are kept for backward compatibility.
//
// IP ranges are inlined because Cloudflare Worker module bundling for raw
// .mjs uploads is fiddly; the canonical source-of-truth (with types and