declare namespace Cloudflare {
interface Env {
SECRETS_KEY: string;
/** Set to "true" only by vite.config.ts for `vite dev` / `bun run preview`; never in a deployment. */
GITFOR_LOCAL?: string;
/** Deployment name; analytics runs only when unset or "production". */
GITFOR_ENV?: string;
/** One-time secret: a signup presenting it becomes the first admin. Delete it after bootstrapping. */
BOOTSTRAP_TOKEN?: string;
GITHUB_CLIENT_ID?: string;
GITHUB_CLIENT_SECRET?: string;
CF_API_TOKEN?: string;
SITES_COOKIE_SECRET?: string;
/** Turnstile widget secret; required whenever TURNSTILE_SITEKEY is set. */
TURNSTILE_SECRET?: string;
SCRATCH_SITES_PER_IP_PER_DAY?: string;
/** Local e2e only; ignored unless PUBLIC_URL is loopback. */
RATE_LIMITS_DISABLED?: string;
/** Stripe is enabled only when this is set; without it billing UIs hide and plans come from METERING_PLANS. */
STRIPE_SECRET_KEY?: string;
STRIPE_PUBLISHABLE_KEY?: string;
/** Signing secret of the /stripe/webhook endpoint (whsec_...). */
STRIPE_WEBHOOK_SECRET?: string;
/** Price id of the Pro monthly subscription. */
STRIPE_PRICE_PRO?: string;
/** Price id of the recurring per-domain custom domain add-on; quantity follows the account's domain count. */
STRIPE_PRICE_CUSTOM_DOMAIN?: string;
/** JSON: {"<pack id from src/lib/pricing.ts PACKS>": "price_..."}; amounts and quantities come from pricing.ts. */
STRIPE_TOPUP_PRICES?: string;
/** "true" enables the loopback-only /__dev/stripe/replay route (test-mode keys only). */
STRIPE_DEV_REPLAY?: string;
/** "true" stops new checkouts and portal plan changes; the webhook keeps processing events. */
BILLING_CHECKOUT_DISABLED?: string;
/** "test" or "live": the mode of the webhook endpoint behind STRIPE_WEBHOOK_SECRET; must match the keys. */
STRIPE_WEBHOOK_MODE?: string;
/** Days a past_due subscription keeps Pro before usage falls back to Free (default 14). */
PAST_DUE_GRACE_DAYS?: string;
/** Platform-wide ceiling on today's platform-billed AI cost in cents (default 10000 when Stripe is on, else off; "off" disables). */
AI_DAILY_SPEND_CEILING_CENTS?: string;
/** PostHog project token (phc_...). Analytics is off unless this (or VITE_POSTHOG_PROJECT_TOKEN) is set. */