Using the command line
How to drive Kortix from a terminal with the kortix CLI.
The kortix CLI does everything the dashboard does, from a terminal. It's optional — if you're not technical, use the dashboard instead.
Install and log in
Install the CLI
curl -fsSL https://kortix.com/install | bashThe mental model
The CLI controls the same things as the dashboard: projects, sessions, secrets, triggers, and change requests. It's the control plane, not a replacement for git.
The most useful commands
Start a session, optionally with a first prompt:
kortix sessions new --prompt "Audit the auth module and propose a fix"
kortix sessions lsManage secrets:
kortix secrets set OPENAI_API_KEY=sk-...
kortix secrets lsPush a local .env's values up as secrets, or pull a names-only skeleton down:
kortix env push --from .env
kortix env pullWork with triggers:
kortix triggers ls
kortix triggers fire daily-digestReview and merge change requests:
kortix cr ls
kortix cr show 3
kortix cr merge 3Inside a session sandbox
Inside a session's environment the CLI is already authenticated for that project — no login needed. A project-scoped token is injected automatically, so commands like kortix secrets ls or kortix cr open work right away. This is how an agent opens its own change request.
Under the hood
On your laptop the CLI uses a user-scoped token (saved at ~/.config/kortix/config.json) that can see every project on accounts you belong to. Inside a sandbox, KORTIX_TOKEN is pre-injected and scoped to that one project. The CLI resolves "which project" from a flag, an env var, or a linked directory, in that order.