← Back to home

Tollbooth

Tollbooth: charge bots micro-fees instead of blocking them with captchas

Problem Statement

Tollbooth: Pay-Per-Crawl Access ControlMost websites today defend against bots with captchas or outright blocking. That frustrates AI agents, crawlers, and automation tools that want legitimate access. WithTollbooth, site owners don’t have to choose between “let everyone in” or “block them all.” Instead, they can charge a small fee for automated traffic.How It WorksBot requests a pageIf the site requires payment, it responds withHTTP 402 Payment Required, including the cost in headers.Bot pays with X402The agent automatically uses its wallet (managed via X402) to confirm payment intent.Site grants accessOnce payment is verified, the site returns normal content—no captchas, no friction.On Flow: SubscriptionsInstead of paying per request, sites can configure recurring access windows (e.g., 30 seconds, 1 day, or a custom interval). This is implemented via Flow’s scheduled callbacks, which automatically handle subscription renewals.Why It’s BetterFor sites & publishersEarn revenue from automated traffic instead of wasting resources on captchas or blocking.(Coming soon: split payments between stakeholders like website owners and journalists.)For bots & agentsNo more captcha-solving farms, OCR hacks, or blocked sessions. Just pay a micro-fee or subscribe for seamless browsing.Features at a GlancePay-per-crawl accesswith X402Subscription-based accesspowered by FlowExpiration support(access ends when time runs out unless renewed)Captcha fallbackfor humansPlanned: Revenue splittingto automatically share fees across multiple parties

Solution

How It’s MadeWe built a lightweight edge proxy that routes all traffic through agate page. Humans can pass through by solving a captcha, while bots are offered the option to pay a small fee usingCoinbase X402. Once either path succeeds, the backend issues ashort-lived access tokenthat grants entry to the requested resource.Payments are processed viaX402 intents and webhooks, with all verification handled in a minimal Node/TypeScript backend. On the subscription side, we usedFlow’s scheduled callbacksto implement recurring access windows, so agents can pay once and continue browsing for the duration of their subscription.The stack is intentionally simple:Cloudflare Workers→ edge gate & traffic routingNode/TypeScript→ token issuance & payment verificationCoinbase AgentKit→ wallet and payment abstractionFlow→ subscription scheduling and expiration handlingWe’ve kept the design hack-friendly and modular—no heavy bot-detection heuristics, just a clear binary choice:solve a captcha or pay.👉Coming soon:split-payment support, so revenue can be automatically shared between multiple parties (e.g. site owner and journalist).

Hackathon

ETHGlobal New York 2025

2025

Prizes

  • 🏆

    Best Use of Actions & Agents on Flow2nd place

    Flow

  • 🏆

    Flow Builder Pool Prize

    Flow

Contributors