CLI reference
Below is the full CLI command reference. For the workflows behind the commands, get setup with install, and the understand the Sectr dev loop.
Authenticating the CLI
Section titled “Authenticating the CLI”sectr auth login
Section titled “sectr auth login”Validate and store the platform key (the server base is stored too)
Usage: sectr auth login [OPTIONS]
Options: --api <API> The server base URL. Default: the public endpoint --key <KEY> Platform API key (`skp_…`). Omitted for `login`: prompted with hidden input -h, --help Print helpsectr auth whoami
Section titled “sectr auth whoami”Print the stored identity (org + server) after re-validating
Usage: sectr auth whoami [OPTIONS]
Options: --api <API> The server base URL. Default: the public endpoint --key <KEY> Platform API key (`skp_…`). Omitted for `login`: prompted with hidden input -h, --help Print helpsectr auth logout
Section titled “sectr auth logout”Forget the stored key
Usage: sectr auth logout [OPTIONS]
Options: --api <API> The server base URL. Default: the public endpoint --key <KEY> Platform API key (`skp_…`). Omitted for `login`: prompted with hidden input -h, --help Print helpProject Setup
Section titled “Project Setup”sectr init
Section titled “sectr init”Scaffold a new agent project: template picker (or --template), file emission, `uv sync`, and a smoke inspect. See `init --help`
Usage: sectr init [OPTIONS] [NAME]
Arguments: [NAME] Project directory name (created if missing; refused if non-empty unless --force)
Options: --template <TEMPLATE> Template to scaffold. Given → fully non-interactive (docs/CI). Omitted → interactive picker (needs a terminal) --force Scaffold into a non-empty directory anyway -h, --help Print helpLocal Dev Server
Section titled “Local Dev Server”sectr dev
Section titled “sectr dev”Run the app locally end-to-end: SQLite journal, subprocess runner, gateway for clients. See `dev --help`
Usage: sectr dev [OPTIONS]
Options: --path <PATH> Project directory (must contain sectr.toml) [default: .] --config <CONFIG> Config file path (relative to --path) [default: sectr.toml] --no-open Don't open the dashboard (CI / containers) --dashboard <DASHBOARD> Dashboard to open (the deployed console by default; point it at a local `next dev` when working on the dashboard itself) [env: SECTR_DASHBOARD_URL=] [default: https://app.sectr.dev] -h, --help Print helpSectr Cloud Secrets Management
Section titled “Sectr Cloud Secrets Management”sectr secrets set
Section titled “sectr secrets set”Store a secret (prompt hides input when `=VALUE` is omitted — avoiding both shell history and terminal echo)
Usage: sectr secrets set [OPTIONS] <KEY_VALUE>
Arguments: <KEY_VALUE>
Options: --path <PATH> Project directory (must contain sectr.toml — the app is identified by its slug, exactly as `sectr deploy` creates it) [default: .] --config <CONFIG> sectr.toml location relative to the project [default: sectr.toml] --api <API> The server base URL (`http(s)://host[:port]`). Defaults through `sectr auth login` (or SECTR_API_URL) --key <KEY> Platform API key (`skp_…`). Defaults through `sectr auth login` (or SECTR_PLATFORM_KEY) -h, --help Print helpsectr secrets list
Section titled “sectr secrets list”List secret NAMES for the app (values are write-only)
Usage: sectr secrets list [OPTIONS]
Options: --path <PATH> Project directory (must contain sectr.toml — the app is identified by its slug, exactly as `sectr deploy` creates it) [default: .] --config <CONFIG> sectr.toml location relative to the project [default: sectr.toml] --api <API> The server base URL (`http(s)://host[:port]`). Defaults through `sectr auth login` (or SECTR_API_URL) --key <KEY> Platform API key (`skp_…`). Defaults through `sectr auth login` (or SECTR_PLATFORM_KEY) -h, --help Print helpsectr secrets rm
Section titled “sectr secrets rm”Remove a secret (idempotent)
Usage: sectr secrets rm [OPTIONS] <KEY>
Arguments: <KEY>
Options: --path <PATH> Project directory (must contain sectr.toml — the app is identified by its slug, exactly as `sectr deploy` creates it) [default: .] --config <CONFIG> sectr.toml location relative to the project [default: sectr.toml] --api <API> The server base URL (`http(s)://host[:port]`). Defaults through `sectr auth login` (or SECTR_API_URL) -h, --help Print helpDeploy to Sectr Cloud
Section titled “Deploy to Sectr Cloud”sectr deploy
Section titled “sectr deploy”Ship the project to a server: package → upload → the server builds and activates. See `deploy --help`
Usage: sectr deploy [OPTIONS]
Options: --path <PATH> Project directory (must contain sectr.toml) [default: .] --config <CONFIG> sectr.toml location relative to the project [default: sectr.toml] --api <API> The server base URL (`http(s)://host[:port]`). Defaults through `sectr auth login` (or SECTR_API_URL) --key <KEY> Platform API key (`skp_…`). Defaults through `sectr auth login` (or SECTR_PLATFORM_KEY) --timeout-secs <TIMEOUT_SECS> How long to wait for the server-side build to resolve, in seconds [default: 600] -h, --help Print help