Repository navigation
feat: user groups — mentionable member sets across relay, CLI, and desktop - #2791
LordMelkor wants to merge 11 commits into
Conversation
Part of block#2728. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Co-authored-by: Claude Code <noreply@anthropic.com> Ai-assisted: true Co-authored-by: Codex <noreply@openai.com>
Part of block#2728. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Co-authored-by: Claude Code <noreply@anthropic.com> Ai-assisted: true Co-authored-by: Codex <noreply@openai.com>
…-join Part of block#2728. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Co-authored-by: Claude Code <noreply@anthropic.com> Ai-assisted: true Co-authored-by: Codex <noreply@openai.com>
Part of block#2728. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Co-authored-by: Claude Code <noreply@anthropic.com> Ai-assisted: true Co-authored-by: Codex <noreply@openai.com>
Part of block#2728. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Co-authored-by: Claude Code <noreply@anthropic.com> Ai-assisted: true Co-authored-by: Codex <noreply@openai.com>
47000 validated member and channel arguments but never the actor, so any pubkey that passed transport auth could create groups. Route the creator through the same community-admission check as member arguments. Caught by e2e_user_groups against a live relay. Part of block#2728. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Co-authored-by: Claude Code <noreply@anthropic.com> Ai-assisted: true Co-authored-by: Codex <noreply@openai.com>
…shape - generated handles exceeded the 32-char limit (unique_handle helper) - open-relay admission checks the users table, so seed it alongside relay_members - the HTTP bridge maps relay rejections to 400 + error body, not 403 Suite passes 8/8 against a live relay. Part of block#2728. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Co-authored-by: Claude Code <noreply@anthropic.com> Ai-assisted: true Co-authored-by: Codex <noreply@openai.com>
Part of block#2728. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Co-authored-by: Claude Code <noreply@anthropic.com> Ai-assisted: true Co-authored-by: Codex <noreply@openai.com>
Part of block#2728. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Co-authored-by: Claude Code <noreply@anthropic.com> Ai-assisted: true Co-authored-by: Codex <noreply@openai.com>
Part of block#2728. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Co-authored-by: Claude Code <noreply@anthropic.com> Ai-assisted: true Co-authored-by: Codex <noreply@openai.com>
Matches the existing allow on build_message_with_client_tags directly below; group_tags pushed the thin wrapper to 8 args. Part of block#2728. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Co-authored-by: Claude Code <noreply@anthropic.com> Ai-assisted: true Co-authored-by: Codex <noreply@openai.com>
|
🤖 Closed (2026-11-17): kray asked me to close this. It dates from before the desktop app moved to block/buzz-app, and it hasn't changed since Aug 19, and it conflicts with main. Mention groups replace it: #9589 on the relay and block/buzz-app#3655 in the app. 🤖 Desktop screenshots (captured via the E2E mock bridge). Groups view
New group dialogName, Group mention pillA message carrying the |



User groups: mentionable member sets across relay, CLI, and desktop
Closes #2728.
Slack-parity user groups: named, community-shared sets of members — humans and agents alike — that can be @-mentioned in any channel and bulk-added to channels. A group carries default channels that new members automatically join.
Protocol design
Groups follow the established NIP-29-style pattern already used for channel membership (9000-series commands → 39002 snapshot): signed command events + relay side effects + relay-published state snapshot. Single-author NIP-33 objects were rejected because replacement is keyed by
(pubkey, kind, d)— incompatible with creator+admin editing.470004700147002470034700439100d= group idKey decisions:
ptags for (group members ∩ channel members), so every existing notification path (live subs, mention feed, mobile push, agent wake-up) works unchanged. A["group", <id>, <handle>]marker tag drives single-pill rendering.47003-only, by design. Creating a group with initial members does not auto-join them — membership → channel-access flows through exactly one path. Create a group (zero+ members) with default channels, then add members as they onboard.channel_add_policy, and skips-doesn't-fail on channels that became invalid.^[a-z0-9][a-z0-9_-]{1,31}$, unique among active groups per community.Surfaces
buzz-relay): ingest routing/scoping, validation + authz, atomic persistence, 39100 snapshot publication, default-channel auto-join via the shared membership path (handle_put_user-style), 39100 queryable without auth changes (p-gate unaffected).buzz-db, migration0025):user_groups,user_group_members,user_group_default_channels— community-id-led keys, soft delete with partial unique index on active handles.buzz-sdk):build_group_create/edit/delete/add_members/remove_members.buzz-cli):buzz groupssubcommand set,buzz channels add-group(reuses the add-member path, dedupes existing members, per-member results),@handleexpansion inmessages send./groupsroute + sidebar entry, GroupDialog (mixed people+agent picker, default-channels listbox), mention autocomplete + send-time expansion via the authoritative REST path, single group pill via remark plugin, Groups section in the channel invite card. Relay-backed React Query data layer with live 39100 subscription; community-switch resets wired.Security notes
The e2e suite caught a real authz gap during development:
47000create validated member/channel arguments but never the actor, so any transport-authenticated pubkey could create groups. Fixed by routing the creator through the same community-admission check as member arguments (dd5b6a6e).Testing
crates/buzz-test-client/tests/e2e_user_groups.rs— 8 scenarios, all passing against live relay + Postgres + Redis: create→snapshot shape, duplicate/invalid handle rejection, edit authz (creator/admin/unrelated), add/remove-member snapshot updates + default-channel auto-join (39002 verified), delete tombstone, private-channel-as-default rejection, non-member rejection.@groupmention expansion verified in stored event tags,channels add-groupbulk add.just cigreen (fmt, workspace + Tauri clippy, desktop biome/file-size/px-text, unit suites incl. 3494 desktop and 541 mobile tests); integration suite green.Out of scope / follow-ups
Screenshots
Desktop screenshots are in the first comment below (posted via
scripts/post-screenshots.sh).🤖 Generated with Claude Code