Skip to content

Cloudflare components

Everything server-side is one Worker script named wayglass and the Cloudflare products bound to it. The Worker reaches Artifacts only through Workers bindings, never through an API token with Artifacts access.

Works liveBuilt, not verified liveStubbedPlannedSelect a box to see its status.

Each project lives in exactly one namespace, chosen when it is created (wayglass init --jurisdiction us|eu) and fixed afterwards, because a namespace’s jurisdiction is set when the namespace is created and cannot change.

wayglass wayglass-eu
Worker binding ARTIFACTS ARTIFACTS_EU
Jurisdiction us eu
Holds Trunk and intent forks of us projects Trunk and intent forks of eu projects
Jurisdiction tag on changes us eu, so EU-only rules such as PII to quarantine apply

A binding cannot report its own namespace or jurisdiction, so the Worker configuration states both, and the Worker feeds the project’s jurisdiction to the policy evaluator. A client cannot claim a different one.

  • Worker at api.wayglass.dev. The web app at / and /console/, its assets, and /v1/public/* require Cloudflare Access sign-in. Anonymous audit views are available on self-hosted Workers configured with --public and without Access; projects must also opt in. See self-hosting.
  • Project Durable Object, SQLite-backed, one per project: intents, pushes, decisions, approvals, sessions, and the append-only audit log.
  • Registry Durable Object: SHA-256 hashes of agent and human keys, the name each key is bound to, its kind, source and expiry, and the append-only key event log (key.created, key.revoked).
  • Policy evaluator: the Go policy code compiled to WebAssembly and run inside the Worker, so the server-side decision and the CLI’s local preview use the same code.
  • Queue artifacts-events: new trunks get an Artifacts event subscription for pushes; the Worker consumes the events and counts trunk pushes.
  • Workers Builds: builds and deploys the Worker from main.
  • Workers AI and AI Gateway: the optional reviewer in worker/src/aireview.ts calls the AI binding to approve an eligible agent_review decision or escalate it to a person. AI_GATEWAY_ID selects the gateway per call; an empty value calls Workers AI directly. AI_REVIEW controls whether requests are off, manual or automatic after proposal. Self-hosting defaults to off. A live run on October 14 verified approval, injection escalation, refusal to approve auth changes and advisory output that left the human decision pending. The daily call budget is enforced in the Project Durable Object. See AI review for setup and component status for evidence.