PreToolUse hooks cannot tell whether a human approved the call
We run a PreToolUse hook that gates git push. It sometimes has to ask the engineer for a final confirmation, and sometimes should stay quiet because the engineer just answered an equivalent question a moment earlier. The hook cannot tell the two apart: its payload never says how the current tool call cleared permissions — a person clicking, a permissions.allow rule matching, or the auto-mode classifier deciding.
Please add a decidedBy field to hook payloads (user, rule, classifier, hook), at least for PreToolUse and PostToolUse, naming how the call cleared or will clear permissions.
A gate could then skip a confirmation the engineer has already given instead of asking twice, and an audit hook could record which actions a person actually saw. Today both are guesswork.
This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗