MCP tools
The tools exposed by dazai mcp (rei). Each maps to one verb of the socket protocol or to a panic signal. All run over the standard MCP stdio transport.
dazai_status()
Round-trips STATUS. Never fails — a dead daemon is a valid, expected answer.
{ "alive": true, "armed": true, "grace_seconds": 5, "registered_pids": 1 }
dazai_register(pid)
Registers a PID for session-bound protection (REGISTER pid=<pid>). The PID is SIGKILLed by the daemon on any armed trigger.
{ "ok": true, "message": "registered" }
Returns ok: false if the PID is invalid or the registry is full (32).
dazai_unregister(pid)
Drops a registration (UNREGISTER pid=<pid>).
{ "ok": true, "message": "unregistered" }
dazai_arm()
Arms the daemon at runtime (ARM). Idempotent — arming an already-armed daemon is fine.
{ "armed": true, "message": "armed" }
dazai_panic()
Sends SIGUSR1 to the daemon — a graceful panic that honors the grace window when armed.
{ "triggered": true }
dazai_hard_panic()
Sends SIGUSR2 to the daemon — a hard panic that bypasses the grace window and runs the kill sequence immediately.
{ "triggered": true }