#22973: fix(discord): pass accountId to ack reaction handlers
channel: discord
size: XS
Cluster:
Signal and Discord Fixes
## Summary
- Passes the already-available `accountId` to `reactMessageDiscord()` and `removeReactionDiscord()` in the status reaction adapter
- Without `accountId`, `createDiscordClient` falls back to `"default"`, which fails when only named accounts are configured (e.g. `channels.discord.accounts.coach_claw`)
- The failure was completely silent at debug log level — only visible with `--verbose`
Fixes #22938
## Local Validation
- [x] `accountId` is already destructured from params (line 62) and used elsewhere in the same function
- [x] `DiscordReactOpts` type already accepts `accountId?: string`
- [x] No other reaction call sites in the same handler need updating
## Scope
XS — 2-line addition in one file (adding `accountId` to two opts objects)
## AI Assistance
Used Claude Code for issue investigation and fix implementation.
## Author
@miloudbelarebia
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
<!-- greptile_comment -->
<h3>Greptile Summary</h3>
Fixes Discord reaction failures when using named accounts by passing `accountId` to reaction handlers. Without this parameter, the Discord client falls back to `"default"` account lookup, which fails silently when only named accounts (e.g., `channels.discord.accounts.coach_claw`) are configured. The `accountId` is already available in scope and the types already support it - this change ensures named Discord accounts work correctly with status reactions.
<h3>Confidence Score: 5/5</h3>
- This PR is safe to merge with no risk
- The fix is minimal (2 lines), passes a parameter that's already in scope to functions that already accept it. The change follows existing patterns in the codebase (other call sites already pass accountId when available), fixes a real bug where named Discord accounts fail silently, and has no edge cases or potential side effects.
- No files require special attention
<sub>Last reviewed commit: 991c2d9</sub>
<!-- greptile_other_comments_section -->
<!-- /greptile_comment -->
Most Similar PRs
#22965: fix(discord): pass accountId to ack reaction calls for named accounts
by arosstale · 2026-02-21
90.8%
#19615: fix(discord): include default account when sub-accounts are configured
by prue-starfield · 2026-02-18
75.6%
#22557: fix(discord): coerce exec approval approver IDs to string to preven...
by zwffff · 2026-02-21
73.9%
#17395: fix(discord): default dm config for sub-accounts to prevent silent ...
by deggertsen · 2026-02-15
73.2%
#19917: feat(discord): allow disabling intermediate status reactions
by Gitjay11 · 2026-02-18
73.2%
#17254: fix(discord): intercept text-based slash commands instead of forwar...
by robbyczgw-cla · 2026-02-15
71.8%
#20967: fix(discord): report connected state so health-monitor can restart ...
by who96 · 2026-02-19
71.5%
#17316: fix: ack reaction not removed when block streaming is enabled (Tele...
by czmathew · 2026-02-15
71.4%
#8357: fix(gateway): preserve accountId across gateway restarts
by alfredo-feat-volky · 2026-02-03
71.2%
#20009: fix(discord): immediately defer interactions to prevent timeouts
by Gitjay11 · 2026-02-18
70.0%