CLI Overview
The wh CLI is the primary human interface for interacting with WarmHub. It covers all operations — creating repos, writing data, querying state, and bootstrapping agent context.
Installation
Section titled “Installation”The CLI requires Node 22+.
npm install -g @warmhub/cliwh --versionAfter installing, wh is available everywhere. See the Quickstart for the full walkthrough.
Everyday Use
Section titled “Everyday Use”Use wh use to set the repo for a working directory, pass --repo org/name when a script should be explicit, and add --json when another tool needs structured output. Most commands accept a repo from the current .wh file, the active profile, or a flag.
Command Pattern
Section titled “Command Pattern”All commands follow the wh <domain> <verb> pattern:
wh org create myorgwh repo list myorgwh thing list --shape Locationwh commit submit --ops '[...]'Domains: org, repo, shape, graph, thing, assertion, commit, use, init, doctor, sub, auth, token, credential, component, prime, notifications, channel
See the full command reference for every domain, verb, flag, and alias.
Configuration
Section titled “Configuration”Default Repo (.wh file)
Section titled “Default Repo (.wh file)”The easiest way to set a default repo is wh use, which writes a .wh file in the current directory:
wh use myorg/worldwh thing list # targets myorg/worldThe CLI resolves the target repo using this priority:
--repoflag (per-command override)WARMHUB_REPOenvironment variable.whfile in the current directory
Environment Variables
Section titled “Environment Variables”The CLI reads WH_TOKEN (authentication), WARMHUB_REPO / WARMHUB_ORG (default repo target), WARMHUB_API_URL (backend URL), and WH_PROFILE (auth profile), plus a few behavior toggles. See Environment Variables for the full list, accepted values, and precedence rules.
Per-Command Override
Section titled “Per-Command Override”wh thing list --repo myorg/other-repoOutput Formats
Section titled “Output Formats”Default (Human-Readable)
Section titled “Default (Human-Readable)”Colored, formatted text output:
wh thing listStructured output for scripts and agents:
wh thing list --jsonLive (Reactive)
Section titled “Live (Reactive)”Live updates by polling — re-runs the query periodically and auto-refreshes as data changes:
wh thing list --liveErgonomics
Section titled “Ergonomics”Prefix expansion. Flag prefixes expand to the full name if unambiguous:
wh repo create myorg/repo --desc "My repo"# expands to --descriptionFuzzy matching. Typos in domains, verbs, and flags get “did you mean?” suggestions.
Verb aliases. A handful of verbs accept an alias — for example, wh auth whoami resolves to wh auth status. There is no general show/get aliasing; use the canonical verb shown in the command reference. A mistyped verb returns a “did you mean?” suggestion rather than silently resolving.
Getting Help
Section titled “Getting Help”wh help # full help overviewwh <domain> # list verbs for a domainwh <domain> <verb> --help # verb details with flags and exampleswh help --format json # structured CLI spec as JSONwh doctor # verify environment and connectivityNext steps
Section titled “Next steps”| Need | Page |
|---|---|
| Every domain, verb, flag, and alias | Command Reference |
| Build and submit a multi-operation write | commit submit deep dive |
| Install the CLI as part of first-run setup | Quickstart |
Hit a problem or have a question? Get in touch.