Connect via CLI
Audit your API collections and scan for security vulnerabilities directly from your terminal or CI/CD pipeline.
The RaksHex CLI is the easiest way to perform ad-hoc scans on your Postman collections, OpenAPI/Swagger specifications, or raw HAR files. It runs completely locally in memory and uploads only anonymized metadata and findings to your RaksHex portal.
Installation
The CLI requires Node.js v16+ to be installed on your system. You can execute it directly using npx or install it globally:
npm install -g @rakshex/cli
Run Your First Scan
To scan an export of your Postman collection or OpenAPI JSON, use the scan command. You will need your project API Key which is found in .insforge/project.json or under your project Settings page:
npx RaksHex scan ./collection.json --key ik_26f99572954998ec678ac9ecbf27031f
CLI Parameters
| Argument | Description | Default |
|---|---|---|
--key |
Your project API Key (or set via RAKSHEX_API_KEY env var). |
- |
--format |
Specify output format (json, csv, table). |
table |
--fail-on |
Fail the build (exit code 1) on findings of severity (Low, Medium, High, Critical). |
High |
💡 GitHub Action Integration: Add
npx RaksHex scan into your CI pipeline to block pull requests automatically when new security issues or undocumented shadow endpoints are introduced.
