Build log

All posts

One subject per post — what the platform does, how it works, and what to capture as evidence.

The agent-ready storefront: one Worker, two audiences

The Lumina demo serves humans a SPA and AI agents a crawlable information architecture — Content-Signal robots policy, a sitemap generated from D1, llms.txt, an OpenAPI contract, JSON-LD product pages and Markdown negotiation. Plus the crawler-validation story that needed GraphQL forensics.

cloudflareagentsseowaf
The attack lab: proving what the edge blocks — on your own zone

An admin-gated page that fires scanner probes, SQLi, XSS, path traversal, credential stuffing and a rate-limit burst at the Lumina demo from a real browser — plus a DDoS simulator that showed the managed ruleset catching marker traffic at 300 rps.

cloudflarewafddossecurity
A layered prompt firewall: edge WAF + AI Gateway Guardrails + DLP

Before the Lumina demo's chat model runs, prompts pass two dashboard-configured screening layers — the zone WAF's AI Security for Apps rules and the AI Gateway's Guardrails + DLP. How the layers divide the work, and the response-side gap only the gateway can cover.

cloudflarewafai-gatewaysecurity
Customer sign-in done properly: PBKDF2, D1 sessions — and a WAF rule that knows leaked passwords

The Lumina demo's customer login: Turnstile-gated, rate-limited, PBKDF2-hashed roster, D1-backed sessions with hash-at-rest and rotation — plus the compromised-credential WAF rule that edge-blocks breached passwords, and the day it proved itself right.

cloudflaresecurityd1waf
Protecting the admin panel: Cloudflare Access SSO — and verifying the JWT inside the Worker

How the Lumina demo gates /admin with Access SSO and fully verifies the Cf-Access-Jwt-Assertion in the Worker — including the war story of the authentication bypass that trusting the header's presence caused.

cloudflarezero-trustaccesssecurity
Product media on R2: validated uploads, immutable caching and AI-generated photos

The Lumina demo's media pipeline: admin uploads validated by magic bytes, Worker-served images with immutable cache headers, and every catalog photo generated in-Worker by Workers AI.

cloudflarer2workers-ai
Realtime retail with Durable Objects: live viewers, stock broadcasts and atomic reservations

One Durable Object coordinates WebSockets presence, live availability pushes and checkout reservations with an alarm-backed release — plus the D1-first design that keeps it honest.

cloudflaredurable-objectswebsocketsrealtime
Governing agent tools with the MCP Server Portal (the flagship demo)

Toggle a tool off in Cloudflare's MCP Server Portal and watch the AI agent lose the capability live. How the Lumina demo does governed tool access with Access service tokens, portal tool toggles and one control plane.

cloudflaremcpzero-trustsecurityagents
The AI stylist: an agent loop with its own MCP tool server

How the Lumina demo's chat bot becomes an agent: an intent heuristic, a bounded tool loop over the MCP protocol, a purpose-built tool Worker, grounded answers with citations — and GenAI spans so you can watch it all in the dashboard.

cloudflareworkers-aimcpagentsobservability
AI Gateway: model selection as configuration, not code

The Lumina demo's free and paid chat tiers hit one AI Gateway dynamic route that picks the model per request from metadata — with a war story about the day the old mechanism was retired.

cloudflareai-gatewayworkers-ai
Semantic product search: Vectorize embeddings with a SQL safety net

How the Lumina demo answers 'something elegant for a night out' with real products: Workers AI embeddings, a Vectorize index, D1 re-hydration for fresh stock, and an honest SQL fallback.

cloudflarevectorizeworkers-aisearch
Bot defense with Turnstile: one widget, three forms, honest failure

Turnstile on signup, sign-in and checkout in the Lumina demo — the sitekey/secret split, the re-challenge UX pattern, rate limits behind it, and why test keys make local dev painless.

cloudflareturnstilesecurity
Oversell-proof checkout: D1, anonymous carts and conditional updates

How the Lumina demo does e-commerce on Workers + D1: HttpOnly cookie carts, stock validation at every step, and a conditional UPDATE that makes the checkout race safe — with compensation when a race is lost.

cloudflared1workersecommerce
I built an entire retail platform on Cloudflare's edge — here's the map

Two Workers, one D1 database, twelve Cloudflare products. The architecture behind the Lumina retail demo, why it is built this way, and what each product actually does in it.

cloudflareworkersd1architecture