OpenClaw / OpenClaw Core
Merged upstreamCorrectnessMerged Jul 29, 2026

Route Feishu DM replies through conversation chat_id

Fixed OpenClaw Feishu direct-message delivery so bot replies are sent to the inbound conversation chat_id instead of a sender open_id that can be rejected by Feishu.

openclaw/openclaw · #109637

Problem

Feishu could reject direct-message replies sent to a sender open_id with provider error 230101 even though the same response delivered through the existing inbound oc_ conversation. The agent completed its response, but the user saw no reply.

Approach

Introduced a reply target that uses chat:<chat_id> for real inbound oc_ direct-message conversations while preserving sender open_id for authorization, session identity, routing history, proactive messages, and synthetic menu/card-action fallbacks.

Impact and scope

  • Restores reliable direct-message delivery for Feishu users affected by open_id reply rejection.
  • Preserves group replies, thread metadata, proactive open_id delivery, account isolation, and sender-scoped session behavior.
  • Reduces message-loss risk in a P1 channel path where completed agent responses could otherwise disappear from the user's view.

Validation

  • Added focused bot regression coverage for real oc_ DM routing and synthetic p2p fallback behavior.
  • Added an HTTP loopback regression through the production Feishu send paths, official Lark SDK, tenant-token exchange, text/card/media delivery, group/thread controls, and error propagation.
  • Merged after remote Testbox validation, full changed checks, exact-head GitHub CI, and real-environment Feishu tenant proof from the reporter.