Skip to main content

SOAT CLI

@soat/cli exposes every SOAT REST API operation as a sub-command generated from the OpenAPI specs.

Installation​

npm install -g @soat/cli
# or
pnpm add -g @soat/cli

Authentication​

soat configure
PromptDescription
Base URLURL of your SOAT server (e.g. http://localhost:5047)
TokenJWT session token (from login-user) or sk_-prefixed API key (from create-api-key)
soat configure --profile prod

Profiles are stored in ~/.soat/config.json.

Global Options​

OptionDescription
-p, --profile <name>Use a named profile from ~/.soat/config.json
-V, --versionPrint the CLI version
-h, --helpDisplay help for any command

Environment Variables​

Take precedence over stored profiles.

VariableDescription
SOAT_BASE_URLServer base URL. When set together with SOAT_TOKEN, skips profile lookup entirely. When set alone, overrides the base URL of the resolved profile.
SOAT_TOKENBearer token — JWT session token or sk_-prefixed API key. Must be set together with SOAT_BASE_URL to skip profile lookup entirely.
SOAT_PROFILEName of the profile to use when no --profile flag is passed.

Available Commands​

CommandDescription
configureAdd or update a profile in ~/.soat/config.json
list-commandsPrint all available API commands
any operationCall the corresponding REST API operation

Complete list: Commands Reference.