{ "$schema": "node_modules/wrangler/config-schema.json", // Working default — pick a real subdomain and update this, ORIGIN, and the custom domain. "name": "notify-atmo", "main": ".svelte-kit/cloudflare/_worker.js", "compatibility_date": "2026-04-01", "compatibility_flags": ["nodejs_compat"], "assets": { "binding": "ASSETS", "directory": ".svelte-kit/cloudflare" }, // Public origin of the deployed app (NOT secret). Must equal the domain you // serve from — the atproto OAuth client_id is derived from it. "vars": { "ORIGIN": "https://atmo.pub" }, // KV namespaces required by @svelte-atproto/oauth's `cloudflareKV` stores // (see src/lib/atproto/index.ts). Create them and paste the ids: // pnpm exec wrangler kv namespace create OAUTH_SESSIONS // pnpm exec wrangler kv namespace create OAUTH_STATES "kv_namespaces": [ { "binding": "OAUTH_SESSIONS", "id": "6559fa117ec041a1a5fabda5b6526f83" }, { "binding": "OAUTH_STATES", "id": "a0f731098f5d4bdea2c3b9e622b13153" } ], // Private binding to the relay Worker's `RelayRpc` entrypoint. The relay's // first-party management methods are reachable only this way (no public // XRPC). `service` must match the relay's deployed Worker name (its // wrangler.toml `name`); both Workers must be in the same Cloudflare account. // For local `vite dev`, run the relay via `wrangler dev` so the adapter's // platform proxy can wire this up. "services": [ { "binding": "RELAY", "service": "notifs-relay", "entrypoint": "RelayRpc" } ] // Secrets (set via `wrangler secret put`, never commit): // COOKIE_SECRET (atproto-oauth secret | wrangler secret put COOKIE_SECRET) // CLIENT_ASSERTION_KEY (atproto-oauth keygen | wrangler secret put CLIENT_ASSERTION_KEY) // // Custom domain: bind it in the CF dashboard, or add: // "routes": [{ "pattern": "atmo.pub", "custom_domain": true }] }