NanoClaw configuration is managed through environment variables, theDocumentation Index
Fetch the complete documentation index at: https://docs.nanoclaw.dev/llms.txt
Use this file to discover all available pages before exploring further.
.env file, and the src/config.ts module. In v2, some configuration has moved to container.json per agent group.
Environment variables
Configuration is read from.env file or process.env, with hardcoded fallbacks.
Name of the assistant. Used in trigger pattern and message routing.
Whether the assistant has its own phone number or dedicated account. Set to
"true" to enable.Docker image to use for agent containers. The default is scoped to the checkout path via
src/install-slug.ts so multiple NanoClaw installs can coexist on one host.Container timeout in milliseconds (default: 30 minutes).
Maximum container output size in bytes (default: 10 MB).
How long to keep container alive after last result in milliseconds (default: 30 minutes).
URL for the OneCLI Agent Vault that handles credential injection for containers.
API key for authenticating with the OneCLI Agent Vault. Optional — only needed if your OneCLI instance requires authentication.
Maximum number of messages sent to container agents per prompt.
Maximum number of concurrent agent containers.
Logging verbosity. Valid values:
debug, info, warn, error, fatal.Timezone for scheduled tasks (cron expressions). Resolved from
TZ env, .env file, then system default. Validated as a real IANA timezone identifier. Falls back to UTC if no valid timezone is found.Timezone configuration
The timezone is resolved through a priority chain:process.env.TZTZfrom.envfileIntl.DateTimeFormat().resolvedOptions().timeZone(system default)'UTC'(fallback)
Directory paths
All paths are absolute and resolved from the project root:{PROJECT_ROOT}/data — runtime data directory (central DB, sessions){PROJECT_ROOT}/data/v2.db — central database with entity model{PROJECT_ROOT}/data/v2-sessions/{agent_group_id}/{session_id}/ — per-session databases and files{PROJECT_ROOT}/groups — agent group folders and memory files~/.config/nanoclaw/mount-allowlist.json — mount security allowlist (never mounted into containers)Trigger pattern
The default trigger pattern is generated fromASSISTANT_NAME:
engage_mode and engage_pattern rather than a global trigger pattern.
Example .env file
With the OneCLI Agent Vault, API keys and OAuth tokens are no longer stored in
.env. Secrets are managed via onecli secrets create and injected by the vault at request time.Credential management
Credentials are managed externally via OneCLI — no credential environment variables are needed in.env.
Register secrets with OneCLI:
@onecli-sh/sdk package’s applyContainerConfig() configures each container’s network to route through the vault, injecting credentials at request time.
Security notes
- Secrets are never read by NanoClaw directly — OneCLI manages them externally
- The OneCLI Agent Vault injects credentials into container API traffic at request time
- Containers cannot extract real credentials from the vault
- Mount allowlist is stored outside the project root and never mounted into containers
- The
.envfile is read by the config module for NanoClaw settings only (not for API keys)