For the full repository initialization guide (creating a test repo, running
npx checksumai init, folder structure, and configuration), see Repo & CLI Setup.Installation
The CLI is included as an npm dependency in your Checksum test repository. After cloning your test repo:Authentication
Download your project’s environment variables using your API key:.env file with your configured environment settings (environment URL, login URL, credentials, etc.). You can find your API key in Settings → Project Settings in the web app.
Running Tests
Run all tests
Run specific tests by name
Verify setup with the example test
Test Run Modes
| Mode | Description |
|---|---|
| Normal | Standard test execution — run all tests and report results |
| Auto-Heal | When a test fails, the CLI attempts to heal it in real time (see Auto-Recovery) |
Environment Variables
The CLI uses environment variables from the downloaded.env file. You can override any variable:
Configuration
Your test setup is configured inchecksum.config.ts inside the checksum/ directory. Key options include:
| Option | Description | Default |
|---|---|---|
apiKey | Your Checksum API key | Required |
environments | Test environments with URLs and credentials | Required |
options.useChecksumSelectors | Smart selector recovery | true |
options.useChecksumAI | AI-powered action/assertion recovery | { actions: true, assertions: false } |
options.hostReports | Upload reports to Checksum dashboard | true when CI=true |
options.autoHealPRs | Auto-create PRs with healed tests | true when CI=true |
.env file.
What the CLI Uploads
After each test run, the CLI uploads results to the Checksum dashboard whenhostReports is enabled in checksum.config.ts. By default, this is true when CI=true (which is set automatically by most CI providers). For local runs, reports are saved locally only unless you explicitly enable hostReports.
When uploading is enabled, the CLI sends:
- Test results — pass/fail/healed status for each test
- Videos — screen recordings of test execution
- Screenshots — captured at key points and on failures
- HAR files — network traffic recordings
- Playwright traces — detailed execution traces for debugging