audit/bench
CLI

audit/bench, from your terminal

Same review engine as the web app — run it from a terminal, a pre-commit hook, or a pipeline step, and fail the build when a scan comes back do_not_ship.

npm install -g auditbench-cli
auditbench login

Install

Two ways to get it running, depending on your setup.

npm (global install)

Needs Node.js 20+. Puts auditbench on your PATH.

npm install -g auditbench-cli

Docker

No Node.js toolchain needed — good for pipelines that only have Docker available. Build it from source (see Docker below).

git clone https://github.com/noumanas/-audit-bench-cli.git
cd -audit-bench-cli && docker build -t auditbench-cli .

Commands

Five commands cover the whole workflow.

auditbench login
Log in and store an access token locally. Prompts for email/password.
auditbench logout
Clear the stored access token.
auditbench status
Show the current plan and today's/this month's AI-audit quota usage.
auditbench audit <file>
Run a single-file audit and print the verdict and findings.
auditbench scan <path>
Zip a directory (or point at an existing .zip) and run a full repository scan.

Flags (audit / scan)

--provider <name>
Choose the LLM provider for this run: anthropic, openai, or gemini.
--fail-on <level>
Exit non-zero when the verdict is at least this bad: do_not_ship (default — matches the PR merge-block threshold), needs_work (stricter), or never (report only, never fail the build).

Environment variables

AUDITBENCH_API_KEY
Long-lived credential for CI — skips auditbench login entirely.
AUDITBENCH_API_URL
Override the API base URL (self-hosting or local development).

Authentication

Two modes, depending on where the CLI runs.

Interactive login

For your own machine. Stores an access token in ~/.auditbench/config.json (mode 0600).

auditbench login

API key

For CI — no password ever touches the pipeline. Generate one from the dashboard: Repository scan → Integrations → CLI / CI-CD API key.

export AUDITBENCH_API_KEY="abk_..."
auditbench status

CI/CD — fail the build on bad findings

Both audit and scan exit non-zero once the verdict meets --fail-on — a failing review fails the build, the same threshold that blocks a PR merge.

GitHub Actions

.github/workflows/audit-bench.yml
name: audit-bench
on: [pull_request]
jobs:
  review:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
      - uses: actions/setup-node@v4
        with:
          node-version: 20
      - run: npm install -g auditbench-cli
      - run: auditbench scan . --fail-on do_not_ship
        env:
          AUDITBENCH_API_KEY: ${{ secrets.AUDITBENCH_API_KEY }}

GitLab CI

.gitlab-ci.yml
audit-bench:
  image: node:20
  script:
    - npm install -g auditbench-cli
    - auditbench scan . --fail-on do_not_ship
  variables:
    AUDITBENCH_API_KEY: $AUDITBENCH_API_KEY

Docker

No Node.js required on the runner. Build the image from source, then bind-mount the repo to scan at /workspace— the image's default working directory. Pass the API key as an env var: container state doesn't persist between runs, so auditbench login isn't an option here.

one-time build
git clone https://github.com/noumanas/-audit-bench-cli.git
cd -audit-bench-cli
docker build -t auditbench-cli .
run a scan
docker run --rm \
  -v "$(pwd)":/workspace \
  -e AUDITBENCH_API_KEY="$AUDITBENCH_API_KEY" \
  auditbench-cli scan . --fail-on do_not_ship

Wire it into your pipeline

Free plan includes the CLI — sign up, generate an API key, and drop the workflow above into your repo.