CLI
Install the Rank CLI, run pentests from your terminal in the cloud or locally, and explore the interactive TUI.
The Rank CLI brings the platform to your terminal. It can drive the full pentest lifecycle in the cloud, or run the entire pentest on your own machine — using the Rank backend only to authenticate model calls and record operations. That local mode lifts the main limitation of the cloud flow: you can bring your own tools without waiting for them to ship on the server.
Install
The CLI is published on npm as @aleex-rank/cli and installs the rank binary. It requires Node.js
20.3 or newer.
npm install -g @aleex-rank/cli
rank --version
The rank binary
Every command is a subcommand of rank (for example rank pentest list or rank auth status).
The documentation is also embedded in the binary — run rank docs <topic> for a paginated,
terminal-formatted guide, or rank docs --list to see every topic.
Interactive TUI
Running rank with no arguments opens an interactive terminal UI (TUI) built with Ink, where you
can browse pentests and agents and launch runs without typing flags. During a pentest run the TUI
shows a live feed of agent activity.
Inside a running pentest, a command bar accepts slash-commands:
| Command | What it does |
|---|---|
/help (/?) | List the available commands. |
/list | Return to the agent list view. |
/global | Toggle between the streaming feed and a schematic overview of phases, agents, models, tools and findings. |
/cancel | Request cancellation of the active pentest. |
/clear | Clear the command-bar feedback. |
/note <text> | Add a local note to the feed (and to the /btw context). |
/btw <question> | Ask the agent a context-only question without interrupting the pentest. |
/deepen <instructions> | Local mode only: queue or apply deepening instructions for the current phase decision. |
For non-interactive environments (CI, containers without a TTY), pass --no-tui to commands like
rank pentest run and rank chat to get flat output on stdout instead.
60-second quickstart
Authenticate, create an automatic pentest, and run it in the cloud:
rank auth set rk_live_xxxxxxxxxxxxxxxx
rank pentest create -n "Demo" -u https://example.com -t web -m automatic
rank pentest run 1 To run the same pentest entirely on your machine, create it in guided mode, assign your own
agents, check your tools, and run with --local:
rank pentest create -n "Demo local" -u https://example.com -m guided
rank agents list --type pentest --phase 1
rank pentest assign 2 --agents 12 18 --phase 1
rank doctor --pentest 2
rank pentest run 2 --local Command groups
Store, check and remove your API token.
configPersistent CLI settings: API URLs, default mode, verbose.
envAPI keys for the tools that run locally.
pentestCreate, assign, run, monitor and triage pentests.
agentsCreate and manage pentest and general agents.
toolsLocal tool definitions and phase/agent assignment.
mcpsConnect MCP servers that expose extra tools.
modelsBrowse and assign the AI models your agents run on.
chatTalk to a general agent, in the cloud or locally.
usageInspect consumption and configure on-demand spend.
doctorCheck that the binaries your local tools need are installed.
docsRead the documentation embedded in the binary.
Next steps
- Authentication & config — set your token and configure the CLI.
- Command reference — every group, subcommand and flag.
- Local vs cloud — when to run on your machine and what it requires.
- Doctor — diagnose your local environment before a local run.