floo.app.toml, and store secrets outside the repository. Your server connects to the database and decides which rows each signed-in user can access.
Declare the backend
floo.app.toml
Store secrets outside git, through stdin so the value stays out of shell history:
Scope rows to the signed-in user
The gateway has already checked the session. Your code reads who the user is from a header and scopes every query to them:app/orders.py
X-Floo-* header a caller sends, so the email comes from floo.
Why data stays private
- No database credentials in the browser. Only your server’s environment holds
DATABASE_URL. Variables prefixedNEXT_PUBLIC_,VITE_, orREACT_APP_are baked into the browser bundle, so never put a secret under those names. - Sign-in before your code. In
accountsmode, floo’s gateway validates the session on every request. Signed-in responses are markedprivate, so no shared cache serves one user’s page to another. - Separate data per environment. Dev and prod use separate databases with separate credentials. A preview gets its own database branch and never receives dev or prod credentials.
- Write-only secrets. A new env var is stored as a write-only secret, and
--jsonoutput redacts secret-shaped values, so an agent’s transcript does not capture them. - Scoped program access. An app API key opens only the routes and scopes you declare, and is revocable on its own. Removing a member revokes their sessions at once.
Next steps
Postgres
Injected variables, pgvector, migrations, and backups.
App sign-in
Identity headers, invites, app roles, and sign-out.
App API keys
Consumers, scopes, rate limits, and request history.
Cron jobs
Schedules, timeouts, manual runs, and failure handling.