CLI Quick Start
The Curviate CLI (curviate) gives you a terminal interface to the Curviate API, useful for scripting, exploring the API interactively, and building agent workflows without writing code. This guide covers installation, authentication, and the global flags available on every command.
Install
Node.js 18 or later is required.
# Install the CLI globally
npm install -g @curviate/cliVerify the installation:
curviate --versionThe binary name is curviate. Source code is on GitHub at github.com/curviate/curviate-cli.
Authenticate
Interactive login (recommended)
# Launches a masked TTY prompt — the key is never echoed to stdout
curviate loginThe login command saves your API key to the local config file. It performs no network call — the key is stored as-is and verified on the first real command you run.
Non-interactive login
# Pass the key directly (see warning below)
curviate login --api-key cvt_live_...
# Read the key from stdin — avoids process listing exposure
curviate login --api-key -Security note: Passing
--api-keyon the command line is visible to other processes viapsand is saved in shell history. Prefer theCURVIATE_API_KEYenvironment variable or the interactivecurviate loginprompt.
Find your API key
Your API key is available in the dashboard topbar settings chip. See Authentication & Accounts for the full setup walkthrough.
Manage profiles
The config subcommands let you manage multiple named profiles — useful when you work with several API keys or accounts.
# List all saved profiles (keys are redacted: prefix + last 4 chars only)
curviate config list
# Print the path to the config file
curviate config path
# Switch to a named profile
curviate config use <name>
# Rename a profile
curviate config rename <old> <new>
# Set the default account for the active profile
curviate config set-account <account_id>
# Override the API base URL for the active profile (omit <url> to see current)
curviate config set-base-url [<url>] [--reset]
# Reset a profile's stored settings
curviate config reset [--profile <name>] [--yes]First command
Once authenticated, try listing your linked accounts:
curviate account listAccount-scoped commands require --account. Set a default so you don't type it every time:
curviate config set-account acc_YOUR_ACCOUNT_ID
# Now account-scoped commands resolve the account automatically
curviate profile meGlobal flags
These flags are accepted by every command. Flags with defaults show them in the Default column.
| Flag | Type | Default | Description |
|---|---|---|---|
--api-key | string | — | API key (overrides env var and profile). Warning: visible to other processes via ps and saved in shell history — prefer CURVIATE_API_KEY env var or curviate login. |
--profile | string | — | Named profile to use from the config file. |
--account | string | — | Account ID for account-scoped commands. |
--base-url | string | — | Override the API base URL. |
--timeout | string | — | Request timeout in milliseconds. |
--json | boolean | false | Emit JSON output (automatic when stdout is not a TTY). |
--fields | string | — | Comma-separated dot-path field projection (e.g. id,name). |
--limit | string | — | Maximum items per page. |
--cursor | string | — | Pagination cursor (opaque token from a previous response). |
--all | boolean | false | Stream all pages as NDJSON. |
--max-pages | string | — | Maximum number of pages to fetch when --all is used. |
--preview | boolean | false | Print the request that would be sent without calling the API. |
--verbose | boolean | false | Reveal deeper fields on the small set of commands that carry them beyond their default view; a no-op on every other command, whose default is already the full response. |
By default, a read returns a sufficient view — the id plus the properties you need to triage the result and chain into the next command, not necessarily every field the API can return. --json forces the full machine-readable output (the default anyway when stdout isn't a TTY); --fields projects that down to exactly the field paths you name. --verbose is narrower still: only a handful of commands carry deep, high-volume detail behind their default view — for example connect sent/connect received, account get, company managed, message search, and groups list/groups get — and --verbose reveals it on those. On the rest of the surface, the default response already is the full shape, so --verbose has no effect.
Command-group articles note which flags each group supports. Write commands support --preview; read commands support --json and --fields; paginated commands additionally support --limit, --cursor, --all, and --max-pages.