Skip to content

D97 · A team's leader delegates their approval permissions to members at their pool, with no user:write

Proposed · 2026-11-10 · zuki, in a CTO session reviewing v1's workflows; it binds when this page's pull request is merged · Applies to access (ACC), D94's preparation:approve and D96's gate approvals

Decision: each team's leader holds their team's approvals, and shares one with a member by delegating it. A grant override can already add one permission at one pool (R-ACC-05), but only a holder of user:write makes one (R-ACC-17), and that is super_admin. A leader such as admin_fleet, one person for a whole team, would wait on a super_admin for each.

  • Only a delegable permission is delegated. The catalogue marks it. The delegable ones are gate_debt:approve, gate_service:approve, gate_checkpoint:approve and gate_team:approve (D96), and preparation:approve (D94). A module that needs another marks it in its own decision.
  • Who delegates: a member holding a delegable permission at a pool through a role, to a member holding a role at that pool, with no user:write. A permission held only by delegation is never passed on, so a delegation is one step from a role.
  • Who revokes: the holder of that permission at that pool, through a role, whoever delegated it; a super_admin, any.
  • A delegation is a grant override marked delegated, with who gave it, a reason and an optional end, such as a holiday's cover. Past its end it gives nothing, because permissions are read on every query (R-ACC-49).
  • It is an access change like any other: it ends the member's sessions (R-ACC-08) and is audited. A super_admin can list every delegation in the organization; a leader, those of their own permissions at their pools.
  • Each refusal has its key (D10): the permission isn't delegable, the delegator doesn't hold it through a role there, or the member holds no role at that pool.

Why: zuki, 2026-11-10: admin_fleet may be one person, and needs to give some approvals to his team members to work effectively; each leader holds their own approvals and delegates. A delegable flag keeps delegation to the approvals that leaders share, not every permission they hold, and one step from a role keeps every delegation traceable to its leader. zuki took the CTO's defaults for the rest.

Consequences:

  • DOC (data phase, #595): the ACC rules for delegable codes, who delegates and revokes, the end, and the refusals; R-ACC-17's exception.
  • BE (data phase, #596): permissions.delegable; member_permission_overrides gains delegated and ends_at; the access helpers skip an ended override; the seed, the pgTAP tests, db-types. The access step loads every v1 override as not delegated, with no end, so TL-DP-04 needs no change.
  • M1: the functions to delegate and revoke, and a leader's page of their delegations.
  • The data phase's part rides slice #584 (timeline row 0o).