Vault
The vault stores secrets that your runtimes use to authenticate into websites and services. Each entry holds a username, password, optional TOTP seed, and origin matching rules.
Access via bctrl.vault.
get(key)
Retrieve a credential from the vault.
Returns VaultCredential | null — null if not found.
The returned credential contains:
set(key, credential)
Store or update a credential.
delete(key)
Delete a credential from the vault.
list(prefix?)
List vault keys, optionally filtered by prefix.
Returns string[] — array of matching key paths.
list(options) — with metadata
List credentials with full metadata by passing meta: true.
Returns VaultCredentialMeta[]
totp(key)
Generate a current TOTP code from a stored credential’s TOTP seed.
Returns string — the current 6-digit TOTP code.
Usage with workspaces
Vault access is scoped by key prefix when mounted to a workspace. See Scopes & Inheritance.

