Skip to content

CLI configuration reference


Configure Atoi CLI paths, endpoints, credentials, runtime overrides, installer behavior, and machine-readable errors.

Use these settings only when the defaults in the CLI reference do not fit your environment. Prefer CLI flags for one command and environment variables for one process. Keep credentials out of shell history, logs, and checked-in files.

#Configuration files

The CLI uses ~/.atoi by default. Set ATOI_HOME to move the entire directory.

PathHolds
~/.atoi/config.jsonNon-secret CLI settings, endpoint overrides, local runtime state, credential metadata
macOS Keychain service atoi-cliOperator, host, provider, and channel credentials when Keychain is available
~/.atoi/secrets.jsonThe same secrets when Keychain is unavailable or disabled

The config file is read as JSON, and a missing or unreadable file counts as empty. Keychain is the preferred secret store, one atoi-cli:<account> entry per credential. The secrets file is written with mode 0600 and removed when its last secret goes.

Inspect the active home without printing secrets:

bash
ATOI_HOME=/absolute/path/to/atoi-home atoi status --json

#Runtime environment

VariableDefaultEffect
ATOI_HOME~/.atoiMove config.json, the fallback secret file, and other CLI-owned state.
ATOI_CONVEX_SITE_URLProduction Atoi HTTP endpointOverride the convex.site URL used for HTTP routes.
CONVEX_SITE_URLNot setSupply the HTTP endpoint when ATOI_CONVEX_SITE_URL is absent.
ATOI_CONVEX_URLProduction Atoi Convex endpointOverride the convex.cloud URL.
CONVEX_URLDerived or production endpointSupply the Convex endpoint when ATOI_CONVEX_URL is absent.
ATOI_WEB_URLhttps://atoi.appOverride the web app used for browser-owned flows.
ATOI_DISABLE_KEYCHAINNot setSet to 1 to use the mode-restricted secret file on macOS.
ATOI_RUNTIME_BINAuto-detectedRun this Atoi runtime binary for durable code work.
ATOI_REPO_PATHAuto-detectedPin the Atoi checkout used for development fallbacks and settings discovery.
ATOI_TUI_BINAuto-detectedRun this TUI binary for atoi tui.
ATOI_DEBUGNot setSet to 1 or true to include optional connect diagnostics.
ATOI_TOKENStored operator credentialSupply a one-process operator token. Prefer atoi account login for durable use.
ATOI_HOST_TOKENStored host credentialSupply a one-process host token for host-backed commands. Prefer atoi login for durable use.

Use Atoi-specific endpoint names in scripts. The unprefixed Convex names are compatibility fallbacks and have lower precedence.

#Installer environment

The installer reads these values only while it runs. Export them before piping the script.

VariableDefaultEffect
ATOI_INSTALL_CHANNELtarballtarball needs no token; npm installs from the public registry and falls back to the tarball; registry installs from GitHub Packages and needs NPM_TOKEN.
NPM_TOKENNot setRequired only by the registry channel; written to a temporary 0600 npm config that the installer removes on exit.
ATOI_CLI_TARBALLhttps://atoi.app/cli/atoi-cli.tgzTarball path or URL for the tarball channel.
ATOI_NPM_REGISTRYhttps://registry.npmjs.orgRegistry for the npm channel.
ATOI_CLI_PACKAGE@creative-int/atoi-cliPackage for the npm and registry channels.
ATOI_MIN_NODE_MAJOR20Set the minimum accepted Node.js major version.
ATOI_INSTALL_PMAuto-detectedPrefer npm, pnpm, or bun.
ATOI_INSTALL_DRY_RUN0Set to 1 to print planned installer steps without executing them.
ATOI_INSTALL_FORCE_PM0Set to 1 to require the selected package manager.
ATOI_INSTALL_SKIP_IF_PRESENT0Set to 1 to preserve an already complete atoi command.
ATOI_PACKAGE_REGISTRYhttps://npm.pkg.github.comRegistry for the registry channel.
ATOI_INSTALL_NO_ANIMATIONNot setSet to 1 to print the banner without its animation.
ATOI_INSTALL_ANIMATION_DEMONot setSeconds to show the banner and its install animation, then exit without installing.
ATOI_WEB_URLhttps://atoi.appOverride links back to the web app.

ATOI_MIN_NODE_MAJOR controls only the installer's preflight. The current CLI package still requires Node.js 22 or newer.

Read the installer before you run it in a restricted environment:

bash
curl -fsSL https://atoi.app/install.sh -o /tmp/atoi-install.sh
less /tmp/atoi-install.sh
bash /tmp/atoi-install.sh

#Machine output

Pass --json or --format json for one canonical JSON envelope. Pass --ndjson when a command emits multiple records. Pass --json-errors when a command supports human output but your caller needs structured failures.

bash
atoi doctor --json
atoi project list --ndjson

#Error classes

The source defines five stable error codes. They currently share the CLI core general nonzero exit class, so branch on the error code rather than assigning different meanings to exit numbers.

CodeMeaning
ATOI_USAGE_ERRORThe command, positional arguments, or flag combination is invalid
ATOI_VALIDATION_ERRORA supplied value or requested transition failed validation
ATOI_CONFIG_ERRORRequired local configuration is absent or inconsistent
ATOI_RUNTIME_ERRORA required runtime, credential backend, or execution dependency failed
ATOI_CLI_ERRORAn unclassified error reached the CLI boundary

A usage error wants --help and a corrected invocation. A validation error names the exact target; fix the input and retry. A config error points at ATOI_HOME, endpoint overrides, or the relevant config command. A runtime error is what atoi doctor --json repairs. For anything unclassified, keep the machine envelope and reproduce it with the smallest command.

Do not treat a receipt as proof outside its stated boundary.

Read Troubleshooting when the command is valid but the backend, runtime, or client stays unavailable.

Was this useful?