> ## Documentation Index
> Fetch the complete documentation index at: https://doc.trackrev.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Command line (CLI)

> npm install -g trackrev: run your affiliate program from the terminal, plus channels, links, clicks and visitor journeys. Tables, TSV for pipes, JSON for jq.

The `trackrev` CLI puts your link analytics in the terminal: performance per channel, per link,
the raw click stream, and any single visitor's full journey. It is a thin, zero-dependency client
for the [Analytics API](https://doc.trackrev.io/developers/introduction.md), so every number matches the dashboard.

```bash theme={null}
npm install -g trackrev
trackrev channels --days 7 --ltv
```

```text theme={null}
channel     clicks  visitors  conversions   revenue       ltv
youtube      1,204       980        12.50  2,410.50  9,180.00
newsletter     310       287         9.00  1,890.00  7,240.00
affiliates     512       461         6.00  1,164.00  4,020.00
```

> [!NOTE]
>
> The CLI is free and MIT-licensed on [npm](https://www.npmjs.com/package/trackrev). Link and
> account commands work on **every plan**, including free, and respect the same limits as the
> dashboard (50 links on the free tier). The analytics commands — `channels`, `links perf`,
> `clicks`, `journey` — need a **paid plan**; on a free workspace they exit `3` with an upgrade
> message. Requires Node 20 or newer.

## Install

Install it once and you get a `trackrev` command on your PATH:

```bash npm theme={null}
npm install -g trackrev
```

```bash pnpm theme={null}
pnpm add -g trackrev
```

```bash yarn theme={null}
yarn global add trackrev
```

```bash bun theme={null}
bun add -g trackrev
```

Check it worked:

```bash theme={null}
trackrev --version
```

> [!NOTE]
>
> **Don't want to install it?** `npx` runs an npm package *without* installing it — it downloads the
> CLI into a temporary cache, runs one command, and leaves nothing on your PATH. Useful for a
> one-off check or a CI step:
>
> ```bash theme={null}
> npx trackrev channels
> ```
>
> Everything below assumes the global install, so commands read `trackrev channels`. With `npx`,
> prefix them: `npx trackrev channels`.

## Authenticate

**1. Create a secret key**

Go to **Settings → Developers** and create a **secret** key (`lk_…`). See
[Authentication](https://doc.trackrev.io/developers/authentication.md).

**2. Save it**

```bash theme={null}
trackrev login
```

The key is prompted for without echoing, verified against the API before anything is written,
and stored at `~/.config/trackrev/config.json` with mode `0600`. A typo fails here rather than
on your next command.

In CI, set the environment variable instead — it overrides any saved login:

```bash macOS / Linux theme={null}
export TRACKREV_KEY=lk_live_...
```

```powershell Windows (PowerShell) theme={null}
$env:TRACKREV_KEY = "lk_live_..."
```

**3. Check what you are pointed at**

```bash theme={null}
trackrev me
```

Prints the workspace, plan, current limits and which key is in use — the first thing to run
when a command returns something you did not expect.

The key is sent as a Bearer token over HTTPS. Keep several environments side by side with
`--profile`:

```bash theme={null}
trackrev login --profile staging --api-url https://staging.example.com/api/v1
trackrev links list --profile staging
```

| Variable | Meaning |
| - | - |
| `TRACKREV_KEY` | Secret API key from **Settings → Developers**. Overrides any saved login. |
| `TRACKREV_API_URL` | Override the API base (staging, self-hosted). Defaults to `https://app.trackrev.io/api/v1`. |

## Commands

*Generated from `apps/cli/src/registry.js` — edit there, then run `pnpm --filter trackrev sync-docs`.*

### Analytics

#### `trackrev channels`

performance per traffic source *(paid plan)*

```bash theme={null}
trackrev channels --days 7 --ltv
```

| flag | meaning |
| - | - |
| `--days N` | last N days (default 30, max 365) |
| `--from ISO` | explicit start, e.g. 2026-01-01; wins over --days |
| `--to ISO` | explicit end (defaults to now) |
| `--ltv` | add all-time lifetime value per channel |

conversions is a decimal on purpose — attribution splits credit, so one sale touched by two channels counts 0.5 on each.

#### `trackrev links perf`

performance per short link (bare `trackrev links` still works) *(paid plan)*

```bash theme={null}
trackrev links perf --limit 20
```

| flag | meaning |
| - | - |
| `--limit N` | rows to return (max 500) |
| `--days N` | last N days (default 30, max 365) |
| `--from ISO` | explicit start, e.g. 2026-01-01; wins over --days |
| `--to ISO` | explicit end (defaults to now) |
| `--settings` | attach each link's URL, expiry and password flag |

#### `trackrev clicks`

the raw click stream — newest first, bots excluded *(paid plan)*

```bash theme={null}
trackrev clicks --all --json
```

| flag | meaning |
| - | - |
| `--limit N` | page size (default 100, max 500) |
| `--all` | follow the cursor to the end of the stream |
| `--link ID` | one link only |
| `--bots` | include bot traffic |

\--all stops after 200 pages and says so on stderr, so a runaway cursor can never loop forever.

#### `trackrev visitors journey <visitor-id>`

one visitor's timeline — every click, identify event and order, in order *(paid plan)*

```bash theme={null}
trackrev journey <visitor-id>
```

The visitor caption goes to stderr, so the rows stay pipe-clean.

### Links

#### `trackrev links list`

the links themselves — newest first, no window

```bash theme={null}
trackrev links list --channel youtube
```

| flag | meaning |
| - | - |
| `--limit N` | page size (default 100, max 500) |
| `--all` | follow the cursor to the end |
| `--channel KEY` | one channel only |
| `--q TEXT` | slug contains this text |

#### `trackrev links create`

create a campaign: one link per channel, or one Smart Link

```bash theme={null}
trackrev links create --url https://acme.com/launch --name Launch --channel youtube --channel newsletter
```

| flag | meaning |
| - | - |
| `--url URL` | destination (required) |
| `--name TEXT` | campaign name (required) |
| `--channel KEY` | a channel; repeat for several |
| `--smart` | one link that infers its channel per click |
| `--tag TEXT` | a tag; repeat for several |
| `--folder ID` | put the campaign in this folder |
| `--external` | destination is a site you can't put the pixel on |
| `--slug SLUG` | custom slug (2–64 chars; lowercase, digits, hyphens) |
| `--campaign TEXT` | utm\_campaign (defaults to the name) |
| `--expires ISO` | expire at this time |
| `--max-clicks N` | expire after this many clicks |
| `--expired-url URL` | where to send visitors after expiry |
| `--password TEXT` | require this password before redirecting |
| `--mobile-url URL` | device targeting: send mobile here |
| `--desktop-url URL` | device targeting: send desktop here |
| `--retarget on\|off` | fire the workspace's ad pixels on click |

Prints one row per link created. Channels: facebook instagram youtube linkedin twitter tiktok newsletter website other.

#### `trackrev links get <id-or-slug>`

one link by id, slug or short code

```bash theme={null}
trackrev links get black-friday
```

#### `trackrev links update <id>`

change a link's slug, UTMs, expiry, password or targeting

```bash theme={null}
trackrev links update <id> --expires 2026-12-31T23:59:59Z --max-clicks 1000
```

| flag | meaning |
| - | - |
| `--term TEXT` | utm\_term |
| `--content TEXT` | utm\_content |
| `--clear-password` | remove the password |
| `--clear-expiry` | remove date and click-cap expiry |
| `--slug SLUG` | custom slug (2–64 chars; lowercase, digits, hyphens) |
| `--campaign TEXT` | utm\_campaign (defaults to the name) |
| `--expires ISO` | expire at this time |
| `--max-clicks N` | expire after this many clicks |
| `--expired-url URL` | where to send visitors after expiry |
| `--password TEXT` | require this password before redirecting |
| `--mobile-url URL` | device targeting: send mobile here |
| `--desktop-url URL` | device targeting: send desktop here |
| `--retarget on\|off` | fire the workspace's ad pixels on click |

#### `trackrev links delete <id>`

delete one link (its campaign and other channels stay) *(asks to confirm; `--yes` in scripts)*

```bash theme={null}
trackrev links delete <id> --yes
```

#### `trackrev links bulk`

create up to 500 links from a CSV

```bash theme={null}
trackrev links bulk --file links.csv
```

| flag | meaning |
| - | - |
| `--file PATH` | CSV with url, name, channel columns (- for stdin) |

Optional columns: utm\_campaign, utm\_term, utm\_content, tags, campaign\_id. Rows that fail are listed with the reason; the rest are created.

#### `trackrev links qr <id-or-slug>`

the link's QR code as SVG

```bash theme={null}
trackrev links qr black-friday --out black-friday.svg
```

| flag | meaning |
| - | - |
| `--out PATH` | write here instead of stdout |
| `--size N` | size in px (default 512, max 2048) |

### Developers

#### `trackrev keys list`

the workspace's API keys (prefixes only)

```bash theme={null}
trackrev keys list --revoked
```

| flag | meaning |
| - | - |
| `--revoked` | include revoked keys |

#### `trackrev keys create`

mint a key — the plaintext is shown once, never again

```bash theme={null}
trackrev keys create --label 'CI deploy'
```

| flag | meaning |
| - | - |
| `--scope SCOPE` | secret (servers, CLI) or public (browser) |
| `--label TEXT` | what this key is for |

The key goes to stdout and everything else to stderr, so `trackrev keys create > key.txt` captures only the key.

#### `trackrev keys revoke <id>`

revoke a key immediately *(asks to confirm; `--yes` in scripts)*

```bash theme={null}
trackrev keys revoke <id> --yes
```

#### `trackrev webhooks list`

outbound endpoints, with their last delivery status

```bash theme={null}
trackrev webhooks list
```

#### `trackrev webhooks events`

every event an endpoint can subscribe to

```bash theme={null}
trackrev webhooks events
```

#### `trackrev webhooks create`

add an endpoint — the signing secret is shown once

```bash theme={null}
trackrev webhooks create --url https://acme.com/hook --event sale.created
```

| flag | meaning |
| - | - |
| `--url URL` | https endpoint (required) |
| `--event NAME` | an event; repeat for several |

https only. Run `trackrev webhooks events` for the valid names.

#### `trackrev webhooks update <id>`

change the URL or events, or pause and resume delivery

```bash theme={null}
trackrev webhooks update <id> --pause
```

| flag | meaning |
| - | - |
| `--url URL` | new endpoint URL |
| `--event NAME` | replace the event list; repeat |
| `--pause` | stop delivering |
| `--resume` | start delivering again |

#### `trackrev webhooks delete <id>`

remove an endpoint *(asks to confirm; `--yes` in scripts)*

```bash theme={null}
trackrev webhooks delete <id> --yes
```

### Setup

#### `trackrev attribution get`

the model and lookback window this workspace uses

```bash theme={null}
trackrev attribution get --models
```

| flag | meaning |
| - | - |
| `--models` | list the three models and what each credits |

#### `trackrev attribution set`

change the model or the window

```bash theme={null}
trackrev attribution set --model linear --window 60
```

| flag | meaning |
| - | - |
| `--model NAME` | last\_touch, first\_touch or linear |
| `--window N` | lookback in days (1-365) |

Both settings apply retroactively — every past order is re-credited against them.

#### `trackrev folders list`

campaign folders, with how many campaigns each holds

```bash theme={null}
trackrev folders list
```

#### `trackrev folders create`

create a folder to group campaigns under

```bash theme={null}
trackrev folders create --name 'Q4 launch' --start 2026-10-01
```

| flag | meaning |
| - | - |
| `--name TEXT` | folder name (required) |
| `--description TEXT` | what it covers |
| `--start YYYY-MM-DD` | start date |
| `--end YYYY-MM-DD` | end date |

#### `trackrev folders update <id>`

rename a folder or change its dates

```bash theme={null}
trackrev folders update <id> --name 'Q1 launch'
```

| flag | meaning |
| - | - |
| `--name TEXT` | new name |
| `--description TEXT` | new description |
| `--start YYYY-MM-DD` | start date |
| `--end YYYY-MM-DD` | end date |

#### `trackrev folders delete <id>`

delete a folder — its campaigns become ungrouped, not deleted *(asks to confirm; `--yes` in scripts)*

```bash theme={null}
trackrev folders delete <id> --yes
```

#### `trackrev folders assign <destination-id>`

file a campaign under a folder, or un-file it

```bash theme={null}
trackrev folders assign <destination-id> --folder <folder-id>
```

| flag | meaning |
| - | - |
| `--folder ID` | folder to file under; omit to un-file |

The id is a CAMPAIGN (the destination behind a set of links), not a single link.

### Revenue

#### `trackrev revenue list`

connected payment providers and their last sync

```bash theme={null}
trackrev revenue list
```

#### `trackrev revenue providers`

what can be connected, and the credentials each needs

```bash theme={null}
trackrev revenue providers
```

Stripe is absent by design — its restricted key lives on the workspace, not here.

#### `trackrev revenue connect`

connect a provider — credentials are verified before saving

```bash theme={null}
trackrev revenue connect --provider polar --field api_key=polar_oat_…
```

| flag | meaning |
| - | - |
| `--provider NAME` | polar, lemonsqueezy, paddle, creem or dodo |
| `--field K=V` | credential as key=value; repeat per field |
| `--sandbox` | use the provider's sandbox host, where it has one |

#### `trackrev revenue sync`

pull charges now and attribute them *(paid plan)*

```bash theme={null}
trackrev revenue sync
```

| flag | meaning |
| - | - |
| `--connection ID` | one connection only; omit for all + Stripe |

Reports imported and attributed per provider. A provider that fails does not stop the others.

#### `trackrev revenue disconnect <id>`

disconnect a provider; imported orders are kept *(asks to confirm; `--yes` in scripts)*

```bash theme={null}
trackrev revenue disconnect <id> --yes
```

### Audience

#### `trackrev visitors list`

visitors, most recently seen first *(paid plan)*

```bash theme={null}
trackrev visitors list --email @acme.com
```

| flag | meaning |
| - | - |
| `--limit N` | page size (default 100, max 500) |
| `--all` | follow the cursor to the end |
| `--email TEXT` | email contains this text |

#### `trackrev visitors get <id>`

one visitor *(paid plan)*

```bash theme={null}
trackrev visitors get <id>
```

#### `trackrev orders list`

synced purchases, newest first

```bash theme={null}
trackrev orders list --status refunded
```

| flag | meaning |
| - | - |
| `--limit N` | page size (default 100, max 500) |
| `--all` | follow the cursor to the end |
| `--status NAME` | paid or refunded |
| `--email TEXT` | email contains this text |

amount is blank on the free plan, where revenue figures are hidden.

#### `trackrev export`

any dataset as CSV *(paid plan)*

```bash theme={null}
trackrev export --kind orders --days 90 --out orders.csv
```

| flag | meaning |
| - | - |
| `--kind NAME` | channels, links, orders or visitors |
| `--out PATH` | write here instead of stdout |
| `--days N` | last N days (default 30, max 365) |
| `--from ISO` | explicit start, e.g. 2026-01-01; wins over --days |
| `--to ISO` | explicit end (defaults to now) |

### Domains

#### `trackrev domains list`

branded short-link domains and their DNS status

```bash theme={null}
trackrev domains list
```

#### `trackrev domains add <domain>`

attach a domain — prints the DNS records to add

```bash theme={null}
trackrev domains add go.acme.com
```

#### `trackrev domains verify <domain-or-id>`

re-check DNS now; exits non-zero until it is active

```bash theme={null}
trackrev domains verify go.acme.com
```

Exits 1 while still pending, so a deploy script can poll until it passes.

#### `trackrev domains remove <domain-or-id>`

detach a domain; links keep working on the default host *(asks to confirm; `--yes` in scripts)*

```bash theme={null}
trackrev domains remove go.acme.com --yes
```

#### `trackrev retargeting list`

the ad pixels fired on opted-in link clicks

```bash theme={null}
trackrev retargeting list --providers
```

| flag | meaning |
| - | - |
| `--providers` | show what can be configured instead |

#### `trackrev retargeting set <provider>`

set a provider's pixel id

```bash theme={null}
trackrev retargeting set meta --id 1234567890123456
```

| flag | meaning |
| - | - |
| `--id ID` | the pixel/tag id (required) |

The id must match that provider's shape — only validated ids are ever put into a loader snippet.

#### `trackrev retargeting remove <provider>`

remove a provider's pixel *(asks to confirm; `--yes` in scripts)*

```bash theme={null}
trackrev retargeting remove meta --yes
```

### Affiliate

#### `trackrev programs list`

the workspace's affiliate programs and their terms

```bash theme={null}
trackrev programs list --archived
```

| flag | meaning |
| - | - |
| `--archived` | include archived programs |

#### `trackrev programs get <id>`

one program in full

```bash theme={null}
trackrev programs get <id>
```

#### `trackrev programs update <id>`

change commission terms, or pause and archive *(paid plan)*

```bash theme={null}
trackrev programs update <id> --rate 0.25 --status paused
```

| flag | meaning |
| - | - |
| `--name TEXT` | program name |
| `--landing-url URL` | where partner links point |
| `--type TYPE` | percent or flat |
| `--rate N` | 0-1 fraction for percent (0.25 = 25%), dollars for flat |
| `--recurring N` | months a commission keeps paying |
| `--cookie N` | attribution window in days |
| `--min-payout N` | minimum balance before a payout |
| `--auto-approve on\|off` | approve signups instantly |
| `--status NAME` | active, paused or archived |

Changes apply to NEW conversions; commissions already earned are untouched.

#### `trackrev partners list`

affiliates with their clicks, sales and earnings *(paid plan)*

```bash theme={null}
trackrev partners list --status pending
```

| flag | meaning |
| - | - |
| `--program ID` | one program only |
| `--status NAME` | pending, approved, rejected, banned or archived |

#### `trackrev partners approve <partner-id>`

approve a pending affiliate *(paid plan)*

```bash theme={null}
trackrev partners approve <partner-id> --program <program-id>
```

| flag | meaning |
| - | - |
| `--program ID` | the program id (required) |

Does NOT send the approval email the dashboard sends — a re-run would mail them again.

#### `trackrev partners reject <partner-id>`

reject an application *(paid plan)* *(asks to confirm; `--yes` in scripts)*

```bash theme={null}
trackrev partners reject <partner-id> --program <program-id> --yes
```

| flag | meaning |
| - | - |
| `--program ID` | the program id (required) |

#### `trackrev partners ban <partner-id>`

ban an affiliate *(paid plan)* *(asks to confirm; `--yes` in scripts)*

```bash theme={null}
trackrev partners ban <partner-id> --program <program-id> --yes
```

| flag | meaning |
| - | - |
| `--program ID` | the program id (required) |

#### `trackrev partners group <partner-id>`

move an affiliate into a group, or back to program terms *(paid plan)*

```bash theme={null}
trackrev partners group <partner-id> --program <program-id> --group <group-id>
```

| flag | meaning |
| - | - |
| `--program ID` | the program id (required) |
| `--group ID` | group to move them to; omit to clear |

#### `trackrev groups list <program-id>`

a program's tiers, showing the terms each one resolves to *(paid plan)*

```bash theme={null}
trackrev groups list <program-id>
```

### Money

#### `trackrev commissions list`

the commission ledger, newest first *(paid plan)*

```bash theme={null}
trackrev commissions list --status pending
```

| flag | meaning |
| - | - |
| `--limit N` | rows to return (max 500) |
| `--status NAME` | pending, eligible, paid, refunded, void or fraud |
| `--partner ID` | one affiliate only |

level 1 is the affiliate who sold; 2+ is an upline earning from their network.

#### `trackrev commissions add`

record an off-platform deal by hand *(paid plan)*

```bash theme={null}
trackrev commissions add --program <id> --partner <id> --amount 500 --earnings 100
```

| flag | meaning |
| - | - |
| `--program ID` | program id (required) |
| `--partner ID` | affiliate id (required) |
| `--amount N` | gross sale value (required) |
| `--earnings N` | the affiliate's cut (required) |
| `--currency CODE` | defaults to usd |
| `--notes TEXT` | why this was entered by hand |

Earnings is not derived — a manual commission exists because the normal rate did not apply.

#### `trackrev commissions void <id>`

void a commission entered in error *(paid plan)* *(asks to confirm; `--yes` in scripts)*

```bash theme={null}
trackrev commissions void <id> --yes
```

| flag | meaning |
| - | - |
| `--status NAME` | set another status instead of void |

Refused if it is already on a payout batch — cancel the payout first.

#### `trackrev payouts list`

payout batches, with open and all-time totals *(paid plan)*

```bash theme={null}
trackrev payouts list --status pending
```

| flag | meaning |
| - | - |
| `--status NAME` | pending, processing, paid, failed or canceled |
| `--limit N` | rows to return (max 500) |

Creating a batch stays in the dashboard: it applies per-group payout floors and platform fees, and a second implementation would eventually pay someone wrong.

#### `trackrev payouts mark-paid <id>`

settle a payout sent off-platform *(paid plan)* *(asks to confirm; `--yes` in scripts)*

```bash theme={null}
trackrev payouts mark-paid <id> --reference PAYPAL-BATCH-123 --yes
```

| flag | meaning |
| - | - |
| `--reference TEXT` | the rail's own id (PayPal batch, Wise transfer) |

Does NOT email the affiliate — the dashboard sends that, and a re-run would send it twice.

### Settings

#### `trackrev settings notifications`

every transactional email, and whether it is on

```bash theme={null}
trackrev settings notifications
```

default=yes means no override is stored and the catalogue default applies.

#### `trackrev settings notify <key>`

turn one transactional email on or off

```bash theme={null}
trackrev settings notify affiliate.approved --off
```

| flag | meaning |
| - | - |
| `--on` | enable it |
| `--off` | disable it |

#### `trackrev settings branding`

the white-label settings affiliates see

```bash theme={null}
trackrev settings branding
```

#### `trackrev settings set-branding`

set the partner-facing logo and accent colour

```bash theme={null}
trackrev settings set-branding --color '#e63e2e'
```

| flag | meaning |
| - | - |
| `--logo URL` | https logo URL |
| `--color HEX` | hex accent, e.g. #e63e2e |
| `--clear-logo` | back to the TrackRev logo |
| `--clear-color` | back to the TrackRev colour |

The affiliate subdomain is read-only here — claiming one is a namespace reservation and belongs in one place.

### Account

#### `trackrev me`

which workspace, plan, limits and key you're using

```bash theme={null}
trackrev me
```

#### `trackrev login`

save a secret key so you don't need TRACKREV\_KEY

```bash theme={null}
trackrev login --profile staging --api-url https://staging.example.com/api/v1
```

| flag | meaning |
| - | - |
| `--key lk_…` | the key (prompted, hidden, when omitted) |
| `--api-url URL` | API base for this profile |

Stored at \~/.config/trackrev/config.json with mode 0600. TRACKREV\_KEY in the environment always wins, for CI.

#### `trackrev logout`

forget a saved key

```bash theme={null}
trackrev logout
```

### Global flags

| flag | meaning |
| - | - |
| `--json` | print the API's JSON instead of a table |
| `--profile NAME` | use a saved login other than the current one |
| `--yes` | skip the confirmation on destructive commands |
| `--version` | print the version |
| `--help` | show help (also: trackrev \<command> --help) |

## Reporting window

`channels` and `links` accept:

| Flag | Meaning |
| - | - |
| `--days N` | Last N days (default 30, max 365) |
| `--from ISO` | Explicit start, e.g. `2026-01-01` |
| `--to ISO` | Explicit end (defaults to now) |

`--from` / `--to` win over `--days`.

## Output

The same data comes out three ways, so a command works both as something you read and as
something you pipe:

```bash theme={null}
trackrev channels                    # aligned table (a terminal)
trackrev channels > channels.tsv     # tab-separated, raw values (a pipe or file)
trackrev channels --json | jq .      # the API's own JSON body
```

Piped output is deliberately unformatted — `2410.5`, not `2,410.50` — so `cut` and `awk` see real
numbers. Warnings, errors and the `journey` caption always go to **stderr**, never into your pipe.

## Recipes

```bash theme={null}
# Just the revenue column
trackrev channels --days 7 | cut -f1,5

# Top five links by revenue (skip the header row, sort on column 6)
trackrev links --limit 100 | tail -n +2 | sort -t$'\t' -k6,6nr | head -5

# Every click from one country
trackrev clicks --all --json | jq '.clicks[] | select(.country == "BD")'

# Newest visitor → their whole journey
trackrev clicks --limit 1 | tail -1 | cut -f6 | xargs trackrev journey

# Nightly export, dated
trackrev clicks --all --json > "clicks-$(date +%F).json"

# Staging or self-hosted
TRACKREV_API_URL=https://staging.example.com/api/v1 trackrev links
```

## Exit codes

| Code | Meaning |
| - | - |
| `0` | Success |
| `1` | No API key, auth failure, network error, not found, API error |
| `2` | Usage error — unknown flag or command, bad value, missing argument, refused confirmation |
| `3` | Plan required — this command needs a paid plan |

A `401` names where the key came from; a `402` exits `3` with the upgrade link, so CI can tell
"wrong plan" apart from "the call broke"; an unknown flag is a one-line usage error rather than a
stack trace.

## All flags

The tables above are generated from the CLI's own command registry, so they list every flag
the binary accepts. `trackrev --help` prints the same set, and `trackrev <command> --help`
narrows it to one command.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.