Commit Graph

1 Commits

Author SHA1 Message Date
rcourtman
b161c42e31 Admit attention lifecycle POSTs on the mutation scope
/api/ai/patrol/attention/ is one prefix for reads, lifecycle mutations
(acknowledge, unacknowledge, suppress, unsuppress) and action planning.
Its outer gate used the read-detail scope set for every method, so a
token holding only monitoring:write was refused before the mutation
handler's own monitoring:write check ran. The pinned capability inventory
already says POST .../{item_id}/{mutation} needs monitoring:write.

The outer gate now follows the handler's dispatch: a lifecycle mutation
is admitted by the mutation scope set, everything else by the read set.
Read tokens still cannot mutate, a write-only token still cannot read,
and action planning keeps its read-side gate plus its own authorization.

Contract-Neutral: Behavioural fix that makes the route match its pinned capability inventory; no new API surface or contract.
2026-10-11 16:05:31 +01:00