Skip to content

Environment variables

The source of truth for environment configuration is the repo-root .env.example file. This page walks through it grouped by domain. Which keys each host reads is declared in @repo/config (packages/config), parsed at boot by apps/api, apps/worker and the apps/svelte-web server; bun run scripts/check-env-schema.ts (CI) fails when .env.example, the per-app .env.example files or turbo.json drift from it. A bad environment refuses to boot; CONFIG_ENFORCE=false logs the report and starts anyway.

VariablePurpose
DATABASE_URLApp connection string. Railway DEV uses a service reference to the private postgres.railway.internal host.
DIRECT_URLDirect DB connection used by migrations. Railway DEV also derives it from the postgres service rather than duplicating a credential.
DATABASE_POOL_MAXMax pg connections per process (packages/database/src/kysely.ts). Default 10; the svelte-web Dockerfile sets 5 because web serves many short requests per instance (PRO-173, decision D2). Every autoscaled instance opens its own pool, so size it against the database’s connection limit.
DATABASE_POOL_IDLE_TIMEOUT_MSClose a pooled connection idle this long. Default 30000; 0 keeps connections open.
DATABASE_POOL_CONNECT_TIMEOUT_MSFail a checkout waiting this long for a free connection. Default 10000; 0 waits forever. A pool that is too small for the load surfaces here as timeout exceeded when trying to connect.
DATABASE_STATEMENT_TIMEOUT_MSServer-side statement_timeout sent as a startup parameter on every pooled connection. Default 30000; 0 disables. The migrators and the operator scripts under apps/worker/scripts/ use getDbWithoutStatementTimeout() and are exempt; inside a host, wrap a known-long query in a transaction with SET LOCAL statement_timeout. A tripped timeout is pg SQLSTATE 57014, tagged db_timeout=statement_timeout on the Sentry event by all three hosts. Invalid values for any of these four log one warning at boot and keep the default.
VariablePurpose
BETTER_AUTH_SECRET32+ character secret. Generate with openssl rand -base64 32.
BETTER_AUTH_URLOrigin for cookie scope. http://localhost:5173 in dev.
COOKIE_DOMAINLeave unset for single-origin dev/prod. Set to a parent domain (.<domain>) once apps/api is on a sibling subdomain — adds Domain + crossSubDomainCookies for sharing. Cookies stay SameSite=Lax (web↔api are same-site).
AUTH_COOKIE_PREFIXPer-environment session cookie name prefix (kottia-dev / kottia-stg / kottia). PRD’s apex-scoped Domain=.kottia.com cookie also reaches the dev/stg hosts, so distinct names keep the tiers’ sessions from overwriting each other in one browser profile. Unset = Better Auth’s default better-auth, which local dev, the e2e fixtures and the contract-fixture generator expect. Changing it on a deployed tier signs everyone out once.
TRUSTED_PROXY_CIDRSComma-separated IPv4 CIDRs whose socket peers may supply forwarded client-IP headers. Railway DEV currently sets 100.64.0.0/10 on web and API as the internal proxy range. Treat it as provisional: verify observed socket peers and prove that forged forwarding headers sent directly to Railway-provided domains cannot influence client-IP resolution before calling it final. When unset in production, getTrustedClientIp fails closed to the socket peer.
AUTH_TRUST_CUSTOM_SCHEMEStrue (default) keeps the native apps’ custom URL schemes in Better Auth trustedOrigins. Set false only after verified App Links are live — otherwise mobile sign-in breaks.
MOBILE_APP_LINK_ORIGINSComma-separated verified HTTPS origins for Universal Links / App Links (e.g. https://app.<domain>). Drives the native apps’ associatedDomains (iOS) / intentFilters (Android) deep-link config.
GOOGLE_CLIENT_ID / GOOGLE_CLIENT_SECRETOAuth credentials from Google Cloud Console.
VariablePurpose
PORTListen port. Default 4000.
CORS_ORIGINSComma-separated browser origin allowlist. Used by both the CORS layer and the CSRF Origin allowlist (enforceOrigin + avatar guard) — a browser request with a non-listed Origin is rejected 403. Mobile (RN fetch) sends no Origin and is exempt.
BETTER_AUTH_URL_APIOverride BETTER_AUTH_URL specifically for apps/api. Falls back to BETTER_AUTH_URL when unset.

Mobile distribution (Firebase App Distribution)

Section titled “Mobile distribution (Firebase App Distribution)”

Local-tooling only — consumed by native/tooling/src/firebase-distribute.ts (Bun auto-loads .env.local from the repo root), never by an app build or a deployed service. CLI auth is a one-time firebase login, not an env var.

VariablePurpose
FIREBASE_APP_ID_IOS_USER / _IOS_AGENT / _ANDROID_USER / _ANDROID_AGENTPer-app Firebase App ID (Firebase console → Project settings → Your apps → “App ID”, e.g. 1:1234567890:ios:abcd…). Not the bundle id. Not secret.
FIREBASE_DISTRIBUTION_GROUPSDefault tester group alias(es), comma-separated (e.g. qa). Override per run with --groups.
APPLE_TEAM_IDApple Developer Team ID — required for iOS ad-hoc archive signing.

See Mobile distribution → Sending test builds for the workflow.

VariablePurpose
PUBLIC_API_URLOrigin of the standalone tRPC host for browser-side fetches. Build-time — baked into the browser bundle via a Vite define; a runtime change does nothing, so rebuild. Required on Railway DEV as https://api.dev.useast.kottia.com. Railway passes service variables to Docker builds for matching declared ARGs, which is how the existing Dockerfile receives it. SSR/form actions are unaffected because they use createCaller(locals) in process.
VariablePurpose
RESEND_API_KEYFrom resend.com/api-keys. Required for OTP delivery + Knock email channel.
RESEND_FROM_EMAILSender address (e.g. noreply@<domain>). The domain must be verified in Resend for each tier before that tier’s first account purge: the account deleted email cannot be resent later (see Transactional email).
CONTACT_INBOX_EMAILInbox for the footer “Contacto” form (web /contact action, PRO-120). Messages arrive with the visitor as reply-to; unset makes the form report a send failure.
VariablePurpose
VALKEY_URLredis://... or rediss://... for TLS. The volatile instance (ADR-0028): server-side cache and rate-limit counters — maxmemory-policy volatile-lru, no persistence. Also the fallback for VALKEY_DURABLE_URL.
VALKEY_DURABLE_URLThe durable instance: BullMQ queues (db1), the psearch:* property search index (db0), withLock keys, session-revocation epochs — maxmemory-policy noeviction + AOF. Optional: unset, everything uses VALKEY_URL (one instance, the pre-split behaviour). On Railway DEV it references the original valkey service (\${{valkey.VALKEY_URL}} in Doppler) while VALKEY_URL references valkey-volatile. See ADR-0028.
VALKEY_TLStrue for self-signed TLS (Proxmox). The TLS settings apply to both instances.
VALKEY_TLS_REJECT_UNAUTHORIZEDfalse to accept self-signed certs over TLS (default verifies). Honored by @repo/cache, the shared queue connection, and the worker (apps/worker/src/connection.ts no longer hardcodes rejectUnauthorized: false).
VALKEY_CA_CERTOptional PEM CA cert for verifying a private TLS Valkey endpoint.
QUEUE_SUFFIXSuffix appended to every BullMQ queue name. Railway DEV and local dev use -dev; production will leave it empty. Producer and worker must use the same suffix.
WORKER_QUEUESWorker only (PRO-168). Which queues this process consumes: a comma-separated list of queue names (search-indexing, leads, alerts, billing, cdn-purge, storage, accounts, identity, image-sanitize, ai-room-staging, ai-descriptions, listing-import, ai-import-extraction) and/or the pool aliases core (the first eight) and media (the last five). Unset or empty means all thirteen — the single-service default on DEV today. Names are exact and case-sensitive; an unknown name stops the boot with the valid list in the error. Every repeatable job is registered by the module that consumes its queue, so a pool owns exactly its own schedulers and two pools never double-fire or orphan one. /health reports only the queues the process started. Set it per service when the worker is split into core / media pools (two Railway services from one image); until then leave it unset.
DLQ_RETENTION_DAYSDays to retain failed_lead_ingestions rows before the worker dlq-purge job deletes them (default 90). Resolved / replayed / discarded rows are purged regardless of age.
ACCOUNT_DELETION_GRACE_DAYSDays between an account-deletion request and the worker purge that erases the PII (default 30). The account is hidden and its listings go offline at request time; signing in before the window ends restores it. Read by @repo/integrations (requestAccountDeletion) when the request is opened — it fixes scheduledFor on the row; the worker’s hourly account-purge-scan only compares that timestamp, so changing the value later does not move purges already scheduled. Set in Doppler dev (inherited by every branch config); add it to each STG/PRD config when those exist.
BULL_BOARD_USER / BULL_BOARD_PASSWORDHTTP Basic auth for the worker’s Bull Board dashboard. DEV/STG only — Bull Board is not deployed in PRD (a Cloud Run worker pool has no URL; PRD uses the queue:admin scripts — see Incident guides). Required wherever the dashboard runs, in every environment — the worker refuses to start it without both (it grants full queue control + exposes lead PII, and binds 0.0.0.0). Leaving them unset is what keeps the dashboard off PRD; there is no NODE_ENV gate, and none would work, because apps/worker/Dockerfile pins NODE_ENV=production into DEV and STG images too. The credential gate itself used to key off NODE_ENV=production, which served the dashboard unauthenticated wherever the platform env said development/staging. Failed auth attempts are limited to 10/min per client IP (resolved through getTrustedClientIp, so admins behind a proxy don’t share one bucket), after which the IP is refused for 5 minutes before its password is compared. During a Valkey outage the counter still denies but the lockout is not remembered — degraded, not absent.
VariablePurpose
AWS_ENDPOINT_URLS3-compatible endpoint. Cloudflare R2 (https://<ACCOUNT_ID>.r2.cloudflarestorage.com, region auto) on the deployed dev env; local SeaweedFS / MinIO for local dev. The S3 client keeps forcePathStyle.
AWS_S3_BUCKET_NAMEBucket name (e.g. uploads).
AWS_ACCESS_KEY_ID / AWS_SECRET_ACCESS_KEYCredentials.
AWS_DEFAULT_REGIONauto for Cloudflare R2 (dev env). us-east-1 for local SeaweedFS / MinIO (conventional default).
VariablePurpose / placement
AI_ROOM_STAGING_ENABLEDFail-closed paid-prediction switch. Only exact true enables submissions/new provider attempts; unset or false stays disabled. Set identically on svelte-web, apps/api, and worker. Persisted active attempts remain recoverable/cancelable.
BFL_API_KEYWorker only. Creates and polls FLUX.2 [pro] tasks on the Black Forest Labs API (x-key header). Never placed on apps/api or svelte-web; there is no staging webhook.
AI_STAGING_LEGACY_ALIAS_SUNSET_ATsvelte-web + apps/api. ISO timestamp ending the 90-day compatibility window for the six legacy style names.
AI_STAGING_RESOLUTIONsvelte-web + apps/api. Output megapixel budget captured on each new job: match_input, 1mp (default), 2mp, or 4mp. The worker derives the exact width/height from the source photo and keeps its aspect ratio.
AI_STAGING_OUTPUT_FORMATsvelte-web + apps/api. jpeg (default), png, or webp; captured on each new job.
AI_STAGING_PROVIDER_MODELsvelte-web + apps/api. BFL model for new staging jobs: unset is flux-2-pro (default); flux-3-image opts in to anchor boxes (PRO-107, off until its paid spike passes). Any other value fails submission closed.
AI_STAGING_CONCURRENCY / AI_STAGING_RATE_LIMIT_PER_MINUTEWorker only. Independent BullMQ controls for the dedicated ai-staging queue. BFL allows 24 active tasks per account, so concurrency × worker replicas must stay at or below it.
AI_DESCRIPTION_CONCURRENCYWorker only. Description queue concurrency; intentionally separate from staging.
AI_STAGING_STRUCTURE_CHECKWorker only. Structural guardrail mode (PRO-64): off, log (default; record a Claude structure verdict on every attempt, never reject) or enforce (a drifted output fails with OUTPUT_STRUCTURE_DRIFT and is retried once on a new seed). Any other value is treated as log. Uses ANTHROPIC_API_KEY.
AI_STAGING_USER_HASH_SECRETWorker only. Independent HMAC secret used to pseudonymize the opaque user identifier sent to BFL. Generate with openssl rand -hex 32.

See the AI room staging rollout and smoke-test runbook.

Three independent, strict-"true" kill switches (PRO-79 / PRO-81 / PRO-82). Set each one identically on svelte-web, apps/api and the worker — the web reads them for routes and the dropzone, the shared service for create / confirm, the api host for the document upload route, the worker to start the queues. All three are false on PRD until QA signs off the matching scenarios in the Testing team.

VariablePurpose / placement
LISTING_IMPORT_ENABLEDPhase 1: the spreadsheet importer at /dashboard/listings/import, the listing-import queue (import-batch, import-purge, import-document-purge). The plan gate (maxImportRowsPerBatch) is the product control once enabled. Geocoding at preview time uses GOOGLE_MAPS_API_KEY.
IMPORT_AI_MAPPING_ENABLEDPhase 2: Claude header mapping for spreadsheets that do not match the template (ai queue, ANTHROPIC_API_KEY on the worker). Off, such a file is refused with header_row_missing.
IMPORT_AI_EXTRACTION_ENABLEDPhase 3: PDF / DOCX documents through POST /api/listing-imports/document and the dedicated ai-import queue (ANTHROPIC_API_KEY on the worker; pdf-lib and mammoth are pure JS, no image change). Documents live under the S3 prefix imports/ for 7 days after the batch finishes. Off, the dropzone accepts spreadsheets only and the route answers import_ai_extraction_disabled.
IMPORT_PARSER_ISOLATIONapps/api + worker (PRO-100). The document parsers (pdf-lib, mammoth) run in a throwaway child process per document under the budget below; a child stopped by a limit refuses the document (import_document_invalid at upload, document_unreadable in the worker). On unless exactly "false"; turn it off only to debug locally. Leave it unset in every deployed environment.
IMPORT_PARSER_MAX_RSS_MBapps/api + worker. The parser child’s resident-memory watchdog, default 768. The in-process bounds keep a legitimate 20 MB document far below it; raise it only if the worker logs a memory budget refusal on a document that should pass.

Spend per month, for the three Claude uses of the importer:

select date_trunc('month', "createdAt") as month, type, count(*) as jobs,
sum("tokensIn") as tokens_in, sum("tokensOut") as tokens_out, sum("costCents") as cents
from ai_jobs
where type in ('IMPORT_MAPPING', 'IMPORT_EXTRACTION')
group by 1, 2 order by 1 desc, 2;

Design and runbooks: packages/api/src/services/listings-import.FEATURE.md; acceptance fixtures and scenarios: docs/listing-import-qa.md.

VariablePurpose
IMGPROXY_URLPublic origin serving signed images (e.g. https://assets.<domain>).
IMGPROXY_KEY / IMGPROXY_SALTHex-encoded HMAC key + salt. Match the imgproxy container config.
IMGPROXY_URL_TTL_SECONDSSigned URL lifetime (default 86400 = 24 hours). Expiry is part of the HMAC payload — leaked URLs stop working after this window. Also caps the image routes’ cache window: both /api/images/* proxies ship max-age = s-maxage = min(86400, this), so lowering it shortens the browser and CDN windows with it. A literal 0 is the exception — it disables signature expiry rather than requesting a zero-second cache, so the window stays at 86400. Empty, unset, or non-numeric all fall back to the default; only a literal 0 disables expiry (not recommended — the URL then never stops working).

Worker only — consumed by the cdn-purge queue, which evicts a listing’s photos from the edge when it stops being publicly viewable.

VariablePurpose
CDN_PURGE_PROVIDERcloudflare, or gcp-cloud-cdn (not implemented — throws on the first job so a misconfigured STG fails loudly; see PRODUCTION.md prerequisite 8). Leave unset to disable purging: jobs complete as no-ops with one log line per process and de-listed photos stay cached until the 24h s-maxage clamp expires.
CLOUDFLARE_ZONE_IDZone containing the web + api hosts.
CLOUDFLARE_API_TOKENAPI token scoped to exactly one permission: Zone → Cache Purge. Cloudflare honours tag purges on Enterprise zones only — on any other plan the worker logs one Sentry warning (cdn-purge-unsupported) and falls back to the 24h bound.

Worker only — consumed by the storage queue. The per-minute outbox drain needs no configuration; these two govern the daily orphan sweep.

VariablePurpose
STORAGE_ORPHAN_SWEEP_EXECUTEOnly exact true arms the sweep to act. Unset (the default) is report-only: it logs a summary and raises one fingerprinted Sentry warning when it finds anything. When armed it still does not call DeleteObject — it enqueues the keys into storage_deletion_outbox with reason ORPHAN_SWEEP, so the drain’s reference re-check remains the single deletion path. Leave unset until a dry run has been read.
STORAGE_ORPHAN_SWEEP_GRACE_HOURSHow old an unreferenced object must be before it counts as an orphan (default 48). Must cover both the pending-upload window (bytes land before the row that points at them) and the drain’s 24h “still referenced” defer. Empty, unset, negative, fractional or non-numeric all fall back to the default; only a literal 0 disables the grace, which is for local verification and never production.
VariablePurpose
MEILISEARCH_HOSTInternal hostname (http://meilisearch.railway.internal:7700 on Railway DEV, supplied through a service reference).
MEILISEARCH_ADMIN_API_KEYWrite access for sync scripts and BullMQ worker.
MEILISEARCH_SEARCH_API_KEYRead-only for client autocomplete.
VariablePurpose
GOOGLE_MAPS_API_KEYServer-side: Places, Geocoding. Browser: Maps JS API.
GOOGLE_MAPS_MAP_IDCloud-styled map. From Google Cloud Console Maps Studio.
VariablePurpose
PUBLIC_GETSTREAM_API_KEYPublic-by-design — client embedding. Set in repo-root .env.local; consumed by apps/api (token mint) and apps/svelte-web.
GETSTREAM_API_SECRETServer-only. Used to mint client user tokens via HMAC. Never ship to the browser or mobile. Lives in repo-root .env.local only, consumed by apps/api.
VariablePurpose
PUBLIC_KNOCK_API_KEYPublic — used by the Knock Feed SDK.
KNOCK_SIGNING_KEYServer-only. Signs the userToken for Knock Feed authenticate(). Required in production — signKnockUserToken throws when missing. Enable “Require identification token verification” in the Knock dashboard.
KNOCK_FCM_CHANNEL_IDServer-only. Android FCM push (shared by both apps).
KNOCK_APNS_CHANNEL_IDServer-only. iOS APNs for the agent app.
KNOCK_APNS_USER_CHANNEL_IDServer-only. iOS APNs for the customer app (separate bundle id / auth key). registerDevice’s app field routes customer tokens here; leave empty until the channel is provisioned (push then no-ops).
KNOCK_SERVICE_TOKENCLI/CI only — not read by the app. Authenticates the Knock CLI for knock push/pull against the knock/ source of truth.
VariablePurpose
PUBLIC_POSTHOG_KEY / PUBLIC_POSTHOG_HOSTConsent-gated product analytics in the browser. svelte-web, apps/api and the worker also use them server-side to read the product flags (PRO-170); unset, each flag reads its env key.
POSTHOG_PERSONAL_API_KEYServer-only, worker. A PostHog personal API key with the person:write scope (the project key cannot delete persons). The account purge uses it to delete the user’s PostHog person with its events and recordings. Unset: that step is skipped.
POSTHOG_PROJECT_IDWorker. Numeric PostHog project id for the purge step above. Both this and the key must be set.
POSTHOG_API_HOSTWorker, optional. PostHog app host for that API call; defaults to https://us.posthog.com (not the us.i.posthog.com ingest host).
SENTRY_DSN / VITE_SENTRY_DSNError + replay. One project per deployable, so each service (svelte-web, apps/api, apps/worker) sets SENTRY_DSN to its own project’s DSN; VITE_SENTRY_DSN is the svelte-web client DSN (same project as the server). Native-app DSNs are inlined in each app’s Monitoring init (publishable, not env).
SENTRY_RELEASEapps/api, optional. Release tag on captured events; unset, the commit Railway injects as RAILWAY_GIT_COMMIT_SHA is used.
SENTRY_ENVIRONMENTTier tag on captured events (development / staging / production). apps/api, the svelte-web server hooks and apps/worker read it ahead of NODE_ENV, which every Dockerfile pins to production and so cannot distinguish the tiers. Set per Doppler root config.
SENTRY_ORG / SENTRY_PROJECT / SENTRY_AUTH_TOKENSource-map / symbol upload during build (svelte-web; native apps upload symbols from their own build pipelines).

Setup and debugging: Operations → Identity verification.

VariablePurpose
DIDIT_API_KEYServer-only. apps/api (session create, decision reads) and apps/worker (reconcile scan, account purge). Use the Sandbox application’s key everywhere except production. Unset: verification reads as unavailable.
DIDIT_WORKFLOW_IDThe Didit workflow new sessions run on. Same hosts.
DIDIT_ENVIRONMENTsandbox (default) or live: the Didit application this deployment works against. Results from the other environment are ignored. All three hosts, with the same value.
DIDIT_WEBHOOK_SECRETapps/api only. The webhook destination’s secret_shared_key; verifies POST /api/webhooks/didit.
IDENTITY_VERIFICATION_ENABLEDThe env default of the identity-verification product flag. All three hosts.
APP_STORE_URL_USER, APP_STORE_URL_AGENT, PLAY_STORE_URL_USER, PLAY_STORE_URL_AGENTapps/svelte-web only. Store pages the /get-app page links to. Public URLs. Unset hides that store’s button.
VariablePurpose
STRIPE_SECRET_KEYServer-only. Read by @repo/integrations, apps/api (the webhook at POST /api/webhooks/stripe) and apps/worker (the daily stripe-reconcile). Unset disables checkout and the billing pages rather than erroring. Test and live are separate keys — each tier needs its own.
NATIVE_PURCHASE_MODEThe env default of the native-purchase-mode product flag: it answers only while that flag does not exist in PostHog. apps/api only, read per request and returned on billing.getSubscription (PRO-110). Decides how the native apps start a purchase: web (default, and any unknown value) opens /dashboard/billing in the in-app browser, checkout opens Stripe Checkout / the Customer Portal directly, hidden shows no link. App Store and Google Play payment policies for the Mexico storefronts forbid in-app links to non-store purchases, so leave it unset unless a store decision changes; flipping it needs no app release.
STRIPE_WEBHOOK_SIGNING_SECRETVerifies the webhook signature before any event is trusted. It is per endpoint, not per account, so a new endpoint means a new secret even in the same Stripe account.

Checkout is Stripe-hosted, so no publishable key and no Stripe.js reach the browser — which is also why nothing here changes the web CSP.

VariablePurpose
FACTURAPI_SECRET_KEYServer-only. Stamps CFDI 4.0 documents at the SAT through FacturAPI’s PAC. Unsetting it is the clean stop: the facturación card hides and the 15-minute cfdi-scan no-ops, leaving the rest of billing untouched. Live mode additionally needs CSD certificates uploaded in the FacturAPI dashboard — a live key with no certificates stamps nothing.
FACTURAPI_PRODUCT_KEY / FACTURAPI_UNIT_KEY / FACTURAPI_PAYMENT_FORMSAT catalog codes (c_ClaveProdServ, c_ClaveUnidad, c_FormaPago), not secrets. The defaults are defensible; which code actually applies is the issuer’s fiscal call and their contador’s to confirm.

PII_ENCRYPTION_KEY encrypts the fiscal identity both of these integrations exchange — see Settings → Secrets, because it is the one secret in the repo that cannot be re-issued.

VariablePurpose
ORIGINCanonical site origin used in OpenGraph tags + sitemap and the base of the web’s Stripe return URLs. Also read by apps/api and apps/worker to absolutize billing-email and account-deleted-email CTAs — unset in a deployed tier, those degrade to relative paths silently — and by apps/api to build the native apps’ Stripe return URLs (/billing/return?app=…, PRO-89): with it unset in production, billing.checkout / billing.portalSession refuse with stripe_unavailable; in dev they fall back to http://localhost:5173.
VariablePurpose
E2E_TEST_USER_EMAIL / E2E_TEST_USER_PASSWORDSeeded test account.
PLAYWRIGHT_BASE_URLTarget origin. http://localhost:5173 for local.
EnvWhere it lives
Workstation, against DEVDoppler project kottia-com, branch config dev_local, injected by doppler run -- (see Local setup). Its data-store URLs point at the deployed DEV tier (Postgres through a Railway TCP proxy). .env.local (gitignored) is only the fallback for a machine without a Doppler token.
Local container stackDoppler branch config dev_docker (loopback wiring + the third-party dev keys) plus the gitignored per-workspace deploy/local/.env (ports, generated secrets). bun run local exec -- … exports the workspace wiring and preserves it through doppler run -c dev_docker; bun run local doctor validates the key names. See Local environment (Compose).
Dev (deployed)Railway project kottia.com, environment development. Variables on svelte-web / api / worker are synced from Doppler (dev_web / dev_api / dev_worker, all inheriting dev), imgproxy from kottia-infra — see Secrets; internal wiring stays a Railway service reference. Declared Docker ARGs receive matching service variables during builds, including required PUBLIC_API_URL. Mobile builds point at https://api.dev.useast.kottia.com.
Staging + ProductionDoppler root configs stg / prd (same key set as dev, skeletons in place), delivered to Cloud Run on GCP us-central1 through the Doppler → Secret Manager sync. Own vendor key sets per tier, SENTRY_ENVIRONMENT=staging / production, QUEUE_SUFFIX=-stg on staging and empty on production, no BULL_BOARD_* on production. Decided, not provisioned yet — see Production landscape.

See Settings → Secrets for the policy on how secrets are stored and rotated.