Skip to content

Install

motus needs Node 22.19 or newer. It reads ~/.config/motus/config.toml in both agents.

Install it globally:

Terminal window
pi install npm:@espadat/motus

pi install appends motus to the end of packages in ~/.pi/agent/settings.json. Move it to the top:

{
"packages": [
"npm:@espadat/motus",
"npm:other-extension"
]
}

Two rules matter, and motus can’t check either:

  • Install globally, never with --local. Subagent pi processes only load global extensions.
  • List motus first in packages of ~/.pi/agent/settings.json. Handlers run in load order, so an extension loaded earlier sees raw tool output and messages. pi can’t report handler order.

Without a config file every session starts degraded. See Configuration.

Commands inside pi:

Command Does
/motus status Shows loaded counts, failures and state
/motus continue Accepts partial protection for this session. Blocks still apply

There is no /motus off. Turning redaction off would send secrets to the model. Read secret values in your own terminal.

Install the package so motus-cc-hook is on your PATH:

Terminal window
npm install --global @espadat/motus

Then add the hook to ~/.claude/settings.json:

{
"hooks": {
"PreToolUse": [
{
"matcher": "Read|Bash",
"hooks": [{ "type": "command", "command": "motus-cc-hook" }]
}
]
}
}

Create ~/.config/motus/config.toml first. Without it the hook fails closed and denies every Read and Bash call.

The hook blocks only. It does not redact, and it does not cover ! shell mode. Read Claude Code before you rely on it.