Secrets live here,
not in your repo.
Keep environment variables and secrets in one encrypted place per workspace. Your apps pull them with a single token, and a change reaches them without a rebuild.
acme-web
WHY A VAULT
Asecretpastedintoachat,aCIvariablenobodyowns,a.envfileonalaptop.Vaultgiveseveryworkspaceoneplacewherevaluesareencrypted,everychangeisrecorded,andyourappssimplyaskforwhattheyneed.
ONE CHANGE, EVERY APP
- 01
Change a value
Edit DATABASE_URL in the dashboard. The new value is encrypted before it is stored.
- 02
It is recorded and announced
The audit log keeps who and when, with checksums instead of values. Your webhook gets a signed event.
- 03
Your app picks it up
The webhook handler refreshes the cache, so the next getEnv() call reads the new value without a redeploy.
DATABASE_URL
Environment: prodpostgres://••••••@db-1/appold value
postgres://••••••@db-2/appnew value
Audit log
variable updatedDATABASE_URL
sha256:3f9a…c1 → sha256:c41e…7d
checksums only, never the value
Webhook delivery
vault.variable.changed
HMAC-SHA256 signed
Your app
cache is stalecache refreshedgetEnv("DATABASE_URL")
reads the new value
SECRETS
Projects, environments, variables.
Group variables by project, split them by environment, and mark the ones that are safe for a browser. Everything else stays server-side.
Environments per project
Keep dev, staging and prod apart, with the same keys and different values.
Public or private
Each variable carries a public flag. Only public ones can ever reach a client bundle.
Import a .env file
Paste or push a file. A comment line with @public marks the next variable as public.
DATABASE_URL
privateSTRIPE_SECRET_KEY
privateTURNSTILE_SITE_KEY
publicNEXT_PUBLIC_APP_URL
publicPart of your workspace: the people who can open it are the people you already invited.
ACCESS
A token for exactly one environment.
Apps authenticate with a vault token scoped to a project and an environment. Rotate or expire it without touching the rest of your Sentroy credentials.
Read or write
Tokens are read-only by default. Pushing from a CLI or CI needs a token created with write permission.
Optional expiry
Give a token an end date and it stops working on its own.
Shown once
Only a hash is stored. The plaintext token is displayed a single time, when you create it.
DEVELOPERS
Load it like any other config.
One bootstrap token in your deploy, everything else comes from the vault. Use the SDK on the server, a hook in React, or the CLI in CI.
- getEnv, getEnvOrThrow and preloadEnv for server code
- useEnv on the client, fed only with public variables
- sentroy env push, pull, list and diff from a terminal or CI
- Plain HTTP endpoints if you do not want the SDK
Endpoints
GET/api/env-vault/fetch
GET/api/env-vault/public
POST/api/env-vault/push
import { getEnv, getEnvOrThrow, preloadEnv } from "@sentroy-co/client-sdk/vault"
// SENTROY_ENV_API_KEY is the only variable set in your deploy.
await preloadEnv() // fail fast on a missing config
const dbUrl = await getEnv("DATABASE_URL") // undefined if missing
const stripeKey = await getEnvOrThrow("STRIPE_SECRET_KEY")Examples use the @sentroy-co/client-sdk package. Replace the token with one created for your own project and environment.
SECURITY
Built so a leak is hard.
Values are encrypted before they reach the database, and the places that could expose them are kept narrow.
Encrypted at rest
Every value is sealed with AES-256-GCM. The database holds ciphertext, never plaintext.
Audit without the secret
Each change records who, what and when. Before and after are stored as sha256 checksums, so a log leak reveals nothing.
Public means public
The public endpoint filters on the server. A private variable cannot be returned from it, whatever the client asks.
Signed webhooks
Deliveries carry an HMAC-SHA256 signature and a timestamp that the SDK handler checks, which blocks replays.
Questions
How is this different from a .env file?
A .env file lives on whichever machine has it. Vault keeps one encrypted copy per environment, records every change, and lets your apps read it with a scoped token instead of a file.
Do I need to rebuild when a value changes?
No. Apps cache values for five minutes by default. With a webhook configured, the cache is refreshed as soon as a variable changes.
What if a webhook delivery fails?
Deliveries are fire-and-forget with a five second timeout and are not retried automatically. The last status is shown in the dashboard, and the five minute cache expiry is the fallback.
Can I use values in the browser?
Only variables flagged public. The client hook and the public endpoint never return private ones.
Where is the encryption key?
The master key stays on the Sentroy side, outside the database. Losing it would make existing ciphertext unreadable, so it is backed up like any other root secret.
SENTROY VAULT
Give your secrets a home.
Open Vault from your workspace, create a project and load your first environment in a few minutes.