CLI Reference

Manage your experiments from the terminal. Install in one command — no Node.js required.

Installation

Install the latest release for macOS or Linux (Apple Silicon or Intel/x64):

curl -fsSL https://app.runbandit.com/api/install.sh | bash

The installer detects your platform, downloads the matching binary, and installs it to /usr/local/bin/bandit. Windows is not currently supported.

Authentication

Log in through your browser. The CLI opens an OAuth flow and stores your session locally.

bandit login
bandit loginAuthenticate via the browser.
bandit logoutLog out and clear stored credentials.

Project setup

bandit initInitialize the Bandit SDK in the current project.

Experiments

bandit experiments listList all experiments.
bandit experiments get <id>Get experiment details.
bandit experiments createCreate a new experiment.
bandit experiments update <id>Update an experiment.
bandit experiments start <id>Start an experiment (set status to active).
bandit experiments pause <id>Pause an experiment.

Treatments

bandit treatments list <experimentId>List treatments for an experiment.
bandit treatments create <experimentId>Create a new treatment.
bandit treatments update <id>Update a treatment.

Account

bandit whoamiShow the current user and company.
bandit switchSwitch the active company.

Configuration

Credentials and the active company are stored at ~/.bandit/config.json. Delete this file or run bandit logout to remove them.