Documentation Index
Fetch the complete documentation index at: https://mintlify.com/Armur-Ai/Pentest-Swarm-AI/llms.txt
Use this file to discover all available pages before exploring further.
pentestswarm scan is the core command of Pentest Swarm AI. It deploys a coordinated swarm of AI agents against the specified target, running reconnaissance, vulnerability scanning, exploitation attempts, and report generation in a fully autonomous pipeline. The swarm works through a sequential five-phase runner by default, or the experimental stigmergic blackboard scheduler when --swarm is passed.
Synopsis
<target> is a domain name, IP address, or CIDR range (e.g. example.com, 10.0.0.1, 10.0.0.0/24). When --scope is omitted, the target itself becomes the scope — a conservative default that prevents accidentally reaching sibling domains.
Scan Modes
| Mode | Description |
|---|---|
manual | Default. General-purpose pentest, all techniques enabled. |
bugbounty | Bug-bounty optimized. Scope-enforced, dedup-ready output, publish threshold 0.5 (only confirmed findings). |
asm | Attack surface management. Continuous asset discovery, less aggressive exploitation. |
ctf | CTF-tuned heuristics. Prioritizes flag-capture patterns and common CTF vulnerability classes. |
Flags
The domain, IP, or CIDR to pentest. Positional first argument.
Comma-separated list of in-scope domains and CIDRs (e.g.
example.com,10.0.0.0/24). Defaults to the target when omitted.Natural-language description of what the swarm should find. Passed verbatim to the orchestrator’s system prompt.
Scan mode:
manual | bugbounty | asm | ctf.Override the LLM provider:
claude | ollama | lmstudio. Defaults to the value in config.yaml.Print the planned commands without executing any of them. No packets are sent, no exploitation occurs.
Directory where the finished report files are written.
Report output format:
md | html | json | sarif | all.Stream live event output to the terminal. Enabled automatically when running in an interactive terminal.
Abort on any LLM error instead of degrading to heuristic fallbacks. Useful for debugging.
Use the stigmergic blackboard scheduler (experimental). Agents deposit pheromones on the blackboard to guide each other. The default is the sequential five-phase runner.
Swarm pheromone scaling:
low (depth-first) | med | high (breadth-first). Only meaningful when --swarm is set.Include suspected-but-not-reproduced findings in the report (aggressive mode). Lowers the publish threshold from 0.5 to 0.1.
Print expected LLM spend in USD and exit without scanning. No network packets are sent. Works even without an API key configured.
Sizing hint for the
--estimate calculation: small (single subdomain, ≤20 endpoints) | medium (typical corporate site) | large (thousands of endpoints).Cap request-per-second rate and forbid destructive techniques. Intended for programs that explicitly disallow automated scanning.
Human-in-the-loop mode. The swarm pauses before every executed step and prompts
[y/N/a=approve-all] on stderr.Authorization token forwarded to HTTP requests as a Bearer header (for authenticated scanning).
Global flags (from pentestswarm --help)
Path to config file. Defaults to
./config.yaml.API server URL (used when
pentestswarm serve is running separately).Emit structured JSON output instead of human-readable text.
Suppress decorative output including the banner and event stream.
Enable debug-level logging.
Event output format
When--follow is active (or the terminal is interactive), each agent event is printed to stdout:
| Tag | Color | Meaning |
|---|---|---|
[think] | Cyan | Orchestrator reasoning step |
[>>] | Yellow | Tool invocation |
[<<] | Green | Tool result |
[!] | Red | Finding discovered |
[*] | Magenta | State change / phase transition |
[>] | Yellow | Step executed |
[ERR] | Red | Error event |
[DONE] | Green | Campaign milestone complete |
Cost estimation
Pass--estimate before any real scan to preview expected LLM spend. No packets are sent.
| Class | Input token range | Typical use case |
|---|---|---|
small | 20k – 80k | Single subdomain, ≤20 endpoints |
medium | 80k – 400k | Corporate site, 100–500 endpoints |
large | 400k – 1.5M | Bug-bounty-scale, thousands of endpoints |
API key resolution
The scan command resolves the API key in this order:config.yaml→orchestrator.api_key- Environment variable
PENTESTSWARM_ORCHESTRATOR_API_KEY - Environment variable
ANTHROPIC_API_KEY - OS keychain entry (set by
pentestswarm init) - Interactive prompt (first-run escape hatch, interactive terminals only)
Examples
campaign
Monitor and manage running campaigns launched by
scanreport
Polish and quality-gate generated report drafts before submission
playbook
Run structured community attack playbooks instead of freestyle scanning
doctor
Verify all dependencies and security tools are installed correctly