npm install -g failproofai. Run it with no arguments to open the local policy dashboard.
The package requires Node.js 20.9 or newer. Bun 1.3 or newer is supported for development and source installs. failproofai configure and failproofai setup are aliases for failproofai config. failproofai policy, failproofai pack and failproofai p are all spellings of failproofai policies — packs and single policies were three commands for one idea and are now one. The older spellings still work, with two exceptions: pack list <source> is now policies show <source>, and pack build is now publish.
Set up a machine
Install the CLI, then read the machine key into the shell.read -s takes it at a prompt that does not echo, so it never appears in a command:
failproofai config is the whole of setup: it installs the failproofaid service (root once — in a terminal it asks for your sudo password, and asks again if that expired before setup finished; with no terminal it uses sudo -n and never prompts), wires hooks into every agent CLI it finds, and connects to Cloud. With no terminal — CI, a container, an agent driving it — it applies rather than asking, and exits 1 if anything it was asked to do did not happen.
In a terminal, the Connect to cloud step on a machine that is not connected yet starts logging in to FailproofAI Cloud straight away; press Tab for the other options, Paste an API key or Use open source. Logging in opens a link — or prints it over SSH or with no display, to open on any device — where you sign up or sign in, pick or create an org, and authorize the machine; the terminal picks up the approval by itself and shows who approved it and for which org. The key is minted only when setup finishes, after the daemon is installed. On a machine that is already connected with a working key, the step is a menu with Keep current connection first, so re-running setup never opens a browser by itself; a saved key that no longer works starts logging in again straight away, and says why. Logging in again makes a new key and leaves the old one working until you revoke it. A Cloud from before browser login says so and offers the other options.
It chooses no policies. That is the second command’s job, and without it a freshly configured machine enforces nothing but the always-on guard.
Prefer the environment variable over --token: a command-line argument is readable from ps by every user on the box. That is all the variable protects against — a key typed into any command, export included, still lands in shell history, which is why it is read in with read -s above. In CI, set it from the secret store and keep shell tracing (set -x) off, or the trace prints it.
Run failproofai without arguments to open the local policy dashboard.
Configuration flags
Local pauses suspend builtin, custom, convention, and pack policies for one session. They always expire, at most 8 hours after the first pause in a run, and they do not disable Cloud-managed policies or
block-failproofai-commands, which is always on and cannot itself be disabled or paused. That guard refuses the direct ways an instrumented agent could pause itself: running failproofai config --pause, or writing the pause file under ~/.failproofai/state/sessions/. It reads commands, not what a script does when it runs, so a script the agent writes and then runs can still reach the same state. A pause file is checked for a bounded expiry and a start no more than a minute in the future, not for who wrote it.
Policy flags
Delivery and maintenance flags
Backfill per harness
backfill re-sends history the collector already read, on a machine connected to Cloud. --since sets the window for most harnesses, with two exceptions:
- Goose, OpenCode and Devin send their whole history, whatever
--sincesays: their history lives in a database the collector reads with no time window, so--dry-runreports them as all sessions. - Hermes history is not re-sent by
backfill.
failproofai update should be run after npm install -g failproofai@latest; it performs home-layout migrations, installs the matching daemon binary, and restarts the service. It then moves every Hermes profile that already uses FailproofAI to the linked native plugin and prints one line per profile. --no-daemon skips the daemon step. update exits non-zero when the daemon could not be replaced, a migration failed, or a Hermes profile could not be migrated (for example because the running daemon cannot serve the native plugin, in which case its shell hooks are left in place).
Harness paths
claude, codex, copilot, cursor, opencode, pi, hermes, openclaw, factory, devin, antigravity, and goose.
Labels namespace derived agent IDs when two roots contain copies of the same project. Overlapping roots and duplicate labels are rejected to prevent duplicate collection or cursor corruption. Extra-path configuration reloads without a daemon restart.
Container environments can replace file-configured extra paths with a comma-separated variable named FAILPROOFAI_<HARNESS>_EXTRA_PATHS, for example:
Environment variables
Use configuration files for persistent machine behavior. Environment variables are most useful for containers, tests, and one process.
Agent-specific home variables such as
CLAUDE_PROJECTS_PATH, CURSOR_HOME, HERMES_HOME, and OPENCLAW_HOME override where Failproof AI discovers local sessions for that harness.
Agent hook settings
Agents cannot edit the files their CLI loads failproofai’s hooks from: Claude Code’ssettings*.json in ~/.claude/ and in any project’s .claude/, Codex’s hooks.json and config.toml, and the hook and plugin files of the other supported agents, also when they reach them through a symlink. One line there can switch every policy off — in Claude Code, "disableAllHooks": true in the highest-precedence settings file that sets the key, though only managed settings can switch off hooks that managed settings install — so block-failproofai-commands refuses those writes, from file tools and from the shell alike. It judges a shell command by its text, so a script written earlier and run later is not seen. This guard does not restrict reading these files; if a read is denied, the opt-in block-read-outside-cwd policy denied it. Change them yourself, or with failproofai policies --install and --uninstall.
failproofai config --status reports a disableAllHooks that is switching failproofai’s Claude Code hooks off, and names the file that sets it.
Pause or remove a machine safely
failproofai <command> --help for version-specific details.

