Config 1.x is a release candidate. npm's latest tag still installs 0.x, so install these docs' version from the rc tag:
npm i @adonis-agora/config@rc
node ace configure @adonis-agora/configThe same goes for every @adonis-agora/* package these docs install: add @rc, and where a page says node ace add, install with @rc first and then run node ace configure. On 0.x? Read the 0.x docs.
CLI
Everything the console does from node ace — with --json and --force.
The commands call the same ConfigAdmin service the console and the MCP tools use: same validation,
same masking, same versions, and cli:<os user> as the audit actor.
node ace config:entry:list --app=streaming --environment=production
node ace config:entry:get db.host --app=streaming
node ace config:entry:set checkout.timeoutMs 3000 --reloadable --message="tune checkout"
node ace config:entry:unset legacy.flag --force
node ace config:history --app=streaming
node ace config:version:show 4 --app=streaming
node ace config:diff --from=3 --to=4 --app=streaming
node ace config:rollback --to=4 --force --message="revert the pool change"
node ace config:audit --app=streaming --action=reveal
node ace config:env --app=streaming
node ace config:pull --app=streaming --write=.env.local
node ace config:crypto:reseal --dry-run
node ace config:tenant:key --rotate| Command | |
|---|---|
config:entry:list | entries, with --search, --secret, --reloadable, --browser, --page, --size |
config:entry:get <key> | one entry; --secrets reveals a secret (audited) |
config:entry:set <key> <value> | JSON or text; --vault, --secret, --sealed (control plane cannot read it), --reloadable, --browser (the app's pages may read it), --description, --message, --string |
config:entry:unset <key> | removes it; asks unless --force |
config:history | versions, newest first (--oldest, --page, --size) |
config:version:show <version> | one version exactly as it was (--secrets) |
config:diff --from=<v> --to=<v> | added/removed/changed keys between two versions (--secrets) |
config:audit | the trail, filtered by --key / --action |
config:rollback --to=<version> | writes a new version from a past one; asks unless --force |
config:env | the resolved values as KEY=value, for eval/pipes; --secrets (audited), --prefix |
config:pull | writes the managed .env.local block (or prints without --write); --url, --token, authkit flags, --secrets (audited) |
config:crypto:reseal | re-seals values with the active key; --all (after rotating config/encryption.ts), --dry-run, --json |
config:tenant:key | the tenant's X25519 key for sealed secrets: show, --rotate, --reseal, --dry-run; on a server, list an app's public keys with --app |
Every command takes --app, --environment and --label (defaults: the app in the
runtime, the process environment, main) and --json. A failure sets exit code 1 and writes the
reason to stderr.
Values
The value argument is read like the console reads the editor: valid JSON is stored as JSON
(3000, true, {"a":1}), anything else as a string. --string keeps even JSON-looking text a
string. A value that will be a secret is encrypted at rest:
node ace config:entry:set stripe.secret sk_live_… --secret
node ace config:entry:set stripe.secret --vault='vault://aws/prod/streaming#stripe'Importing an environment
config:import turns env variables into entries in one version. The input is a .env, a JSON
object, or stdin. Use it to move an app's existing environment into the config server:
node ace config:import --app=shop --file=.env.production --dry-run # what would be imported
node ace config:import --app=shop --file=.env.production --skip='^VITE_'
printenv | node ace config:import --app=shop --message='from the PaaS'RESEND_API_KEYbecomes the keyresend.api.key.importRemoteConfigmaps keys back to env names the same way.- Values are stored as text, exactly as the environment had them.
- Names matching
--secretsare stored as secrets: encrypted at rest and readable only withconfig:secrets:read. The default pattern catches*_SECRET,*_PASSWORD,*_TOKEN,*_API_KEY,*_KEY,*_KEY_ID, DSNs, webhooks and the like. --skipleaves names out, for example build-time variables such asVITE_*.- The command prints names and counts, never a value.
Scripting
--json prints one object to stdout, nothing else:
node ace config:entry:list --app=streaming --json | jq '.data[].key'
node ace config:history --app=streaming --json | jq '.meta.total'config:env mirrors sail:info --env, so a shell can export the whole scope:
eval "$(node ace config:env --app=streaming)"In a worktree
config:env reads the same values the app would (tenant.localEnv included on a tenant), so a Sail
worktree prints its own ports rather than the server's. See Sail.