members: member-list-audit — Members list, never-empty first run, audit trail #42

Closed
opened 2026-07-25 04:55:25 +00:00 by ben · 1 comment
Owner

Parent

Feature spec: #19 (members).

What to build

The Members tab, mounted in shell's dashboard frame, is the resting surface that answers "who belongs and in what state?" Screen P6-S1 lists every member as a row carrying their name, komiti, role (member or operator), and a status pill for their lifecycle state — active, awaiting approval, hasn't signed in yet, or suspended — with a badge on the row of anyone designated kaitiaki. This slice builds that list surface reading over the member orchestrator (ADR 0077) and stands up the audit pipeline hook that every later lifecycle verb writes through.

The list is never a dead end. On a freshly founded community the first row is the founder — the operator's own person account, seeded by founding as runtime data — carrying the operator role, shown alongside a prominent "Invite people" panel. There is no empty Members screen; the never-empty rule (shell) makes row one the founder just as the Fleet list opens on the gateway.

Every identity action across the whole feature is audit-logged (ADR 0027): a structured entry lands in the standing log pipeline attributed to the acting operator, and member detail drills into that member's own trail, terminating in shell's logs viewer. This slice builds the audit-write seam and the list/detail drill-in entry point; the individual verbs that write to it arrive in their own slices.

Notes: the founder row, the auth-gate OIDC client, the default-open access matrix, and the hidden kaitiaki group are all seeded by founding as runtime data — a data annotation, not a build edge.

Acceptance criteria

  • (story 1) Given members exist in states active / awaiting approval / hasn't signed in yet / suspended, when I open Members, then each row shows name, komiti, role (member|operator), and its status pill, and kaitiaki show a badge on their row.
  • (story 2) Given a freshly founded community, when I open Members, then row one is the founder (me) with the operator role and a prominent "Invite people" panel is shown — never an empty screen.
  • (story 31) Given any lifecycle action (invite, approve, decline, create, reset, suspend, remove, fate verb, komiti/matrix change, designation, role change), then a structured entry lands in the standing log pipeline attributed to the acting operator, and member detail drills into that member's trail.

Blocked by

  • #29 — Members mounts in the dashboard frame

Task manifest

task: members:member-list-audit
implements_flow: p6-members
implements_edge: (the S1 list surface — no inbound verb; the audit pipeline hook spans all)
wireframe: docs/ux/wireframes/p6-members/p6-s1-members.html
interface: the `member` orchestrator (control plane, ADR 0077) — list members with role/komiti/status/kaitiaki; the audit-write hook (ADR 0027) every lifecycle verb records through, and member-detail drill-in over the trail
seam: "`member` orchestrator seam tests (control plane, Go) \u2014 fake `idp`, in-memory ledgers, audit sink"
acceptance:
  - given: members exist in states active / awaiting approval / hasn't signed in yet / suspended
    when: I open Members
    then: each row shows name, komiti, role (member|operator), and its status pill, and kaitiaki show a badge
  - given: a freshly founded community
    when: I open Members
    then: row one is the founder with the operator role plus a prominent "Invite people" panel — never empty
  - given: any lifecycle action
    when: it runs
    then: a structured entry lands in the standing log pipeline attributed to the acting operator, and member detail drills into that member's trail
depends_on: [shell:ui-kit-mount-slot-contract]
out_of_scope: [invites' minting and ledger (invites slice), the lifecycle verbs themselves (invites/join-approval/by-hand-creation/member-detail-reset/suspend/removal-fates/komiti-matrix-roles), a member self-service account page]
needs_human_decision: []
## Parent Feature spec: #19 (members). ## What to build The Members tab, mounted in shell's dashboard frame, is the resting surface that answers "who belongs and in what state?" Screen P6-S1 lists every member as a row carrying their name, komiti, role (member or operator), and a status pill for their lifecycle state — active, awaiting approval, hasn't signed in yet, or suspended — with a badge on the row of anyone designated kaitiaki. This slice builds that list surface reading over the `member` orchestrator (ADR 0077) and stands up the audit pipeline hook that every later lifecycle verb writes through. The list is never a dead end. On a freshly founded community the first row is the founder — the operator's own person account, seeded by founding as runtime data — carrying the operator role, shown alongside a prominent "Invite people" panel. There is no empty Members screen; the never-empty rule (shell) makes row one the founder just as the Fleet list opens on the gateway. Every identity action across the whole feature is audit-logged (ADR 0027): a structured entry lands in the standing log pipeline attributed to the acting operator, and member detail drills into that member's own trail, terminating in shell's logs viewer. This slice builds the audit-write seam and the list/detail drill-in entry point; the individual verbs that write to it arrive in their own slices. Notes: the founder row, the auth-gate OIDC client, the default-open access matrix, and the hidden kaitiaki group are all seeded by founding as runtime data — a data annotation, not a build edge. ## Acceptance criteria - [ ] (story 1) Given members exist in states active / awaiting approval / hasn't signed in yet / suspended, when I open Members, then each row shows name, komiti, role (member|operator), and its status pill, and kaitiaki show a badge on their row. - [ ] (story 2) Given a freshly founded community, when I open Members, then row one is the founder (me) with the operator role and a prominent "Invite people" panel is shown — never an empty screen. - [ ] (story 31) Given any lifecycle action (invite, approve, decline, create, reset, suspend, remove, fate verb, komiti/matrix change, designation, role change), then a structured entry lands in the standing log pipeline attributed to the acting operator, and member detail drills into that member's trail. ## Blocked by - #29 — Members mounts in the dashboard frame ## Task manifest ```yaml task: members:member-list-audit implements_flow: p6-members implements_edge: (the S1 list surface — no inbound verb; the audit pipeline hook spans all) wireframe: docs/ux/wireframes/p6-members/p6-s1-members.html interface: the `member` orchestrator (control plane, ADR 0077) — list members with role/komiti/status/kaitiaki; the audit-write hook (ADR 0027) every lifecycle verb records through, and member-detail drill-in over the trail seam: "`member` orchestrator seam tests (control plane, Go) \u2014 fake `idp`, in-memory ledgers, audit sink" acceptance: - given: members exist in states active / awaiting approval / hasn't signed in yet / suspended when: I open Members then: each row shows name, komiti, role (member|operator), and its status pill, and kaitiaki show a badge - given: a freshly founded community when: I open Members then: row one is the founder with the operator role plus a prominent "Invite people" panel — never empty - given: any lifecycle action when: it runs then: a structured entry lands in the standing log pipeline attributed to the acting operator, and member detail drills into that member's trail depends_on: [shell:ui-kit-mount-slot-contract] out_of_scope: [invites' minting and ledger (invites slice), the lifecycle verbs themselves (invites/join-approval/by-hand-creation/member-detail-reset/suspend/removal-fates/komiti-matrix-roles), a member self-service account page] needs_human_decision: [] ```
Author
Owner

Done in commit ba6921e (sandcastle: members:member-list-audit #42).

The member control-plane orchestrator lands in internal/member/ (ADR 0077 — members single seam), with two faces:

  • Members list (P6-S1) — Members() joins name/komiti read through the IDP port (kanidm runtime people + groups) with role/status/kaitiaki from the members-owned record Ledger. Each row carries name · komiti · role (member|operator) · a status pill (active / awaiting approval / hasn't signed in yet / suspended) · the kaitiaki badge. The never-empty rule (shell/DDR 0095): a founded community opens on the founder as row one (operator role, seeded by founding as runtime data) with a prominent "Invite people" panel while they are still alone — never a blank screen; a member missing from the idp falls back to the id (never a dead end).
  • Audit-write hook (ADR 0027) — Audit(actor, action, subject, detail) stamps a structured, operator-attributed entry into the standing-log AuditSink (unattributed entries refused with ErrNoActor, so no lifecycle action lands anonymously); Trail(subject) is the member-detail drill-in (newest-first) that terminates in shell's logs viewer.

Acceptance: story 1 (rows across all four states + kaitiaki badge), story 2 (fresh community → founder row one + prominent invite panel, never empty), story 31 (structured operator-attributed audit entry + member trail drill-in) — each is a Given/When/Then seam test.

Evidence: 5 seam tests in internal/member/member_test.go over a fake IDP + in-memory Ledger + MemoryAuditSink + fake clock; go build/go vet/gofmt/golangci-lint all clean. STATUS.md updated in the same commit.

Out of scope (own slices): the lifecycle verbs themselves, the invite ledger, a member self-service account page.

Done in commit `ba6921e` (`sandcastle: members:member-list-audit #42`). The `member` control-plane orchestrator lands in `internal/member/` (ADR 0077 — members single seam), with two faces: - **Members list (P6-S1)** — `Members()` joins name/komiti read through the `IDP` port (kanidm runtime people + groups) with role/status/kaitiaki from the members-owned record `Ledger`. Each row carries **name · komiti · role (member|operator) · a status pill** (active / awaiting approval / hasn't signed in yet / suspended) **· the kaitiaki badge**. The **never-empty rule** (shell/DDR 0095): a founded community opens on the founder as row one (operator role, seeded by founding as runtime data) with a prominent "Invite people" panel while they are still alone — never a blank screen; a member missing from the idp falls back to the id (never a dead end). - **Audit-write hook (ADR 0027)** — `Audit(actor, action, subject, detail)` stamps a structured, operator-**attributed** entry into the standing-log `AuditSink` (unattributed entries refused with `ErrNoActor`, so no lifecycle action lands anonymously); `Trail(subject)` is the member-detail drill-in (newest-first) that terminates in shell's logs viewer. **Acceptance:** story 1 (rows across all four states + kaitiaki badge), story 2 (fresh community → founder row one + prominent invite panel, never empty), story 31 (structured operator-attributed audit entry + member trail drill-in) — each is a Given/When/Then seam test. **Evidence:** 5 seam tests in `internal/member/member_test.go` over a fake `IDP` + in-memory `Ledger` + `MemoryAuditSink` + fake clock; `go build`/`go vet`/`gofmt`/`golangci-lint` all clean. STATUS.md updated in the same commit. **Out of scope (own slices):** the lifecycle verbs themselves, the invite ledger, a member self-service account page.
ben closed this issue 2026-07-25 07:46:14 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Reference
Matou/idss#42
No description provided.