openclaw/extensions
挨踢小茶 406e7aba75
fix(feishu): guard against false-positive @mentions in multi-app groups (#30315)
* fix(feishu): guard against false-positive @mentions in multi-app groups

When multiple Feishu bot apps share a group chat, Feishu's WebSocket
event delivery remaps the open_id in mentions[] per-app. This causes
checkBotMentioned() to return true for ALL bots when only one was
actually @mentioned, making requireMention ineffective.

Add a botName guard: if the mention's open_id matches this bot but the
mention's display name differs from this bot's configured botName, treat
it as a false positive and skip.

botName is already available via account.config.botName (set during
onboarding).

Closes #24249

* fix(feishu): support @all mention in multi-bot groups

When a user sends @all (@_all in Feishu message content), treat it as
mentioning every bot so all agents respond when requireMention is true.

Feishu's @all does not populate the mentions[] array, so this needs
explicit content-level detection.

* fix(feishu): auto-fetch bot display name from API for reliable mention matching

Instead of relying on the manually configured botName (which may differ
from the actual Feishu bot display name), fetch the bot's display name
from the Feishu API at startup via probeFeishu().

This ensures checkBotMentioned() always compares against the correct
display name, even when the config botName doesn't match (e.g. config
says 'Wanda' but Feishu shows '绯红女巫').

Changes:
- monitor.ts: fetchBotOpenId → fetchBotInfo (returns both openId and name)
- monitor.ts: store botNames map, pass botName to handleFeishuMessage
- bot.ts: accept botName from params, prefer it over config fallback

* Changelog: note Feishu multi-app mention false-positive guard

---------

Co-authored-by: Teague Xiao <teaguexiao@TeaguedeMac-mini.local>
Co-authored-by: Tak Hoffman <781889+Takhoffman@users.noreply.github.com>
2026-03-02 22:27:35 -06:00
..
acpx feat(acp): add kimi harness support surfaces 2026-03-03 01:05:24 +00:00
bluebubbles test: fix strict runtime mock types in channel tests 2026-03-03 03:06:22 +00:00
copilot-proxy
device-pair feat(secrets): expand SecretRef coverage across user-supplied credentials (#29580) 2026-03-03 02:58:20 +00:00
diagnostics-otel
diffs test(perf): trim fixed waits in relay and startup tests 2026-03-02 17:30:33 +00:00
discord
feishu fix(feishu): guard against false-positive @mentions in multi-app groups (#30315) 2026-03-02 22:27:35 -06:00
google-gemini-cli-auth chore: remove unreachable "LINUX" from resolvePlatform return type 2026-03-03 02:36:01 +00:00
googlechat feat(secrets): expand SecretRef coverage across user-supplied credentials (#29580) 2026-03-03 02:58:20 +00:00
imessage
irc feat(secrets): expand SecretRef coverage across user-supplied credentials (#29580) 2026-03-03 02:58:20 +00:00
line test(perf): trim fixed waits in relay and startup tests 2026-03-02 17:30:33 +00:00
llm-task
lobster refactor(gateway): hard-break plugin wildcard http handlers 2026-03-02 16:24:06 +00:00
matrix feat(secrets): expand SecretRef coverage across user-supplied credentials (#29580) 2026-03-03 02:58:20 +00:00
mattermost feat(secrets): expand SecretRef coverage across user-supplied credentials (#29580) 2026-03-03 02:58:20 +00:00
memory-core ci: fix lint and audit regressions on main 2026-03-02 23:08:23 +00:00
memory-lancedb fix: add regression for memory-lancedb dimensions pass-through (#32036) (thanks @scotthuang) 2026-03-02 19:02:11 +00:00
minimax-portal-auth feat(models): support minimax highspeed across onboarding 2026-03-03 00:40:15 +00:00
msteams feat(secrets): expand SecretRef coverage across user-supplied credentials (#29580) 2026-03-03 02:58:20 +00:00
nextcloud-talk feat(secrets): expand SecretRef coverage across user-supplied credentials (#29580) 2026-03-03 02:58:20 +00:00
nostr refactor(gateway): hard-break plugin wildcard http handlers 2026-03-02 16:24:06 +00:00
open-prose
phone-control refactor(gateway): harden plugin http route contracts 2026-03-02 16:48:00 +00:00
qwen-portal-auth
shared
signal
slack
synology-chat fix(synology-chat): prevent restart loop in startAccount (#23074) 2026-03-02 20:06:16 +00:00
talk-voice feat(secrets): expand SecretRef coverage across user-supplied credentials (#29580) 2026-03-03 02:58:20 +00:00
telegram fix: add regression tests for telegram token guard (#31973) (thanks @ningding97) 2026-03-02 18:33:49 +00:00
test-utils fix: resolve pi-tools typing regressions 2026-03-03 02:27:59 +00:00
thread-ownership
tlon fix(security): pin tlon api source and secure hold music url 2026-03-03 01:45:24 +00:00
twitch
voice-call refactor(voice-call): unify runtime cleanup lifecycle 2026-03-03 02:51:17 +00:00
whatsapp
zalo feat(secrets): expand SecretRef coverage across user-supplied credentials (#29580) 2026-03-03 02:58:20 +00:00
zalouser fix: align gateway and zalouser typing imports 2026-03-02 22:29:18 +00:00