Paradaux

PAR-84

0

Per-team Discord channel routing for activity posts

DoneUnassignedTesksFeature

Limitation: DiscordActivitySink.onActivity posts every workspace event to all of a guild's configured channels — there's no team filter, and ActivityEvent doesn't even carry the issue's team. So a single channel receives the firehose (all teams), which is why cross-team noise lands in one channel.

Proposed fix (per-team routing):

  1. Add the issue's team (key/id) to ActivityEvent — one extra join in ActivityDispatcher's poll query.
  2. Scope a channel to a team: new nullable team_id on guild_channel (null = catch-all, gets everything).
  3. DiscordActivitySink: post an event to a channel only if the channel's team_id is null or matches the event's team.

Then you can map #mcn-issues → MCN, #par-issues → PAR, and leave a channel unscoped for the full feed. UI: the channel inputs in the new Discord integration card gain an optional team picker.

Not a priority right now — logged for later. Distinct from the default-team creation fix (PAR-83); this is about where posts are delivered.

Resources

Comments

tesks · Jun 16, 2026, 8:11 PM

Verified LIVE (commit b780375). V26 adds nullable guild_channel.team_id; ActivityDispatcher joins the issue's team into ActivityEvent (teamId); DiscordActivitySink delivers an event to a channel only when its team_id is null (catch-all) or matches the event's team. Acceptance met.

Activity

  • tesks changed status to Status → Done
  • tesks commented
  • tesks changed status to Status → Pending Release
  • ParadauxIO linked a commit — Commit b780375 — Per-team Discord channel routing (PAR-84)
  • tesks created the issue