docs(webhook): document --deliver-to and standing watches in the CLI help - #168
Conversation
…help `agent-box-webhook --help` predates the 0.9.0 dispatch shape: usage() showed neither --deliver-to nor --ignore-sender, and the setup hint offered only session delivery. The flags work — the wrapper execs webhook.py, which owns the parsing — so this is docs-only, but --help is the only description of the CLI an agent gets, so an undocumented flag is an unusable one. usage() now spells out both delivery shapes (session vs. subagent standing watch, with the pinned/shared/spawn semantics and the --ttl 0 caveat per shape) and --ignore-sender, and `setup` closes with the standing-watch form alongside the session one. tests/webhook.nix asserts --help keeps mentioning both, so it cannot silently stale again. Checks run (aarch64-linux): module-generated-up-to-date, module-single-file, webhook-route, multi-user. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01PsqGhkpjsb4kKAdVz25xKN
|
Reviewed by a dispatched hook session (this PR's Accuracy check (each statement in the new help vs.
The Checks run here (aarch64, natively): all pass, so the committed I also dedented and printed the generated heredoc: it wraps at ≤80 columns throughout. The one 86-column line ( Nits, none blocking:
|
Motivation
agent-box-webhook --helpis stale: it predates the 0.9.0 dispatch shape (#164).usage()documented neither--deliver-tonor--ignore-sender, and thesetuphint offered only session delivery — so the standing-watch shape was invisible to anyone reading the CLI rather than the guide.The flags themselves work: the wrapper
execswebhook.py, which owns flag parsing. This is docs-only. But--helpis the only description of the CLI an agent gets, and an undocumented flag is an unusable one.Changes
usage()now lists--deliver-to session|subagentin the synopsis (bothsubscribeandunsubscribe) and explains the two delivery shapes: session delivery (per session, 1h TTL,--ttl 0interrupts whatever session is active — avoid) vs. a subagent standing watch (spawns a freshhook-*session per batch, shared, pinned by default, shown underdispatchinls).--ignore-senderis documented too, including that CI-outcome events are delivered regardless.agent-box-webhook setupcloses with the standing-watch subscribe form next to the session one.tests/webhook.nixasserts--helpkeeps mentioning--deliver-to subagentand--ignore-sender, so it cannot silently stale again.modules/agent-box.nixregenerated vianix run .#assemble.User-visible / security effects
Help text only — no behavior, no new surface, no secrets touched. The wording steers agents away from pinning a session subscription (which hijacks the active session) and toward
--deliver-to subagentfor unowned events.Checks run
nix build -L .#checks.aarch64-linux.{module-generated-up-to-date,module-single-file,webhook-route,multi-user}— all pass locally. The x86_64-onlywebhookVM test (which the new assertions live in) runs in CI.🤖 Generated with Claude Code
https://claude.ai/code/session_01PsqGhkpjsb4kKAdVz25xKN