@openclaw/feishu 2026.5.5-beta.1 → 2026.5.5-beta.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/api.js CHANGED
@@ -2,7 +2,7 @@ import { a as parseFeishuTargetId, i as parseFeishuDirectConversationId, n as bu
2
2
  import { n as createFeishuThreadBindingManager, r as getFeishuThreadBindingManager, t as __testing } from "./thread-bindings-BmS6TLes.js";
3
3
  import { n as handleFeishuSubagentEnded, r as handleFeishuSubagentSpawning, t as handleFeishuSubagentDeliveryTarget } from "./subagent-hooks-C3UhPVLV.js";
4
4
  import { r as listEnabledFeishuAccounts } from "./accounts-Ba3-WP1z.js";
5
- import { a as setFeishuNamedAccountEnabled, i as feishuSetupAdapter, n as feishuSetupWizard, r as runFeishuLogin, t as feishuPlugin } from "./channel-BOejZIqb.js";
5
+ import { a as setFeishuNamedAccountEnabled, i as feishuSetupAdapter, n as feishuSetupWizard, r as runFeishuLogin, t as feishuPlugin } from "./channel-BegH3cJm.js";
6
6
  import { t as getFeishuRuntime } from "./runtime-CG0DuRCy.js";
7
7
  import { a as jsonToolResult, d as registerFeishuChatTools, f as createFeishuToolClient, m as resolveFeishuToolAccount, n as registerFeishuDriveTools, o as toolExecutionErrorResult, p as resolveAnyEnabledFeishuToolsConfig, s as unknownToolActionResult } from "./drive-C5eJLJr7.js";
8
8
  import { normalizeLowercaseStringOrEmpty, normalizeOptionalString, readStringValue } from "openclaw/plugin-sdk/text-runtime";
@@ -1601,7 +1601,7 @@ const feishuPlugin = createChatChannelPlugin({
1601
1601
  })
1602
1602
  }),
1603
1603
  gateway: { startAccount: async (ctx) => {
1604
- const { monitorFeishuProvider } = await import("./monitor-k9pu1IUn.js");
1604
+ const { monitorFeishuProvider } = await import("./monitor-BVR-x39Q.js");
1605
1605
  const account = resolveFeishuRuntimeAccount({
1606
1606
  cfg: ctx.cfg,
1607
1607
  accountId: ctx.accountId
@@ -1,2 +1,2 @@
1
- import { t as feishuPlugin } from "./channel-BOejZIqb.js";
1
+ import { t as feishuPlugin } from "./channel-BegH3cJm.js";
2
2
  export { feishuPlugin };
@@ -3,7 +3,7 @@ import { l as fetchBotIdentityForMonitor } from "./monitor.state-DYM02ipp.js";
3
3
  //#region extensions/feishu/src/monitor.ts
4
4
  let monitorAccountRuntimePromise;
5
5
  async function loadMonitorAccountRuntime() {
6
- monitorAccountRuntimePromise ??= import("./monitor.account-DoDo7TZX.js");
6
+ monitorAccountRuntimePromise ??= import("./monitor.account-CUZxYkjE.js");
7
7
  return await monitorAccountRuntimePromise;
8
8
  }
9
9
  async function monitorFeishuProvider(opts = {}) {
@@ -1580,6 +1580,13 @@ const PERMISSION_ERROR_COOLDOWN_MS = 300 * 1e3;
1580
1580
  const groupNameCache = /* @__PURE__ */ new Map();
1581
1581
  const GROUP_NAME_CACHE_TTL_MS = 1800 * 1e3;
1582
1582
  const GROUP_NAME_CACHE_MAX_SIZE = 500;
1583
+ function resolveConfiguredFeishuGroupSessionScope(params) {
1584
+ const legacyTopicSessionMode = params.groupConfig?.topicSessionMode ?? params.feishuCfg?.topicSessionMode ?? "disabled";
1585
+ return params.groupConfig?.groupSessionScope ?? params.feishuCfg?.groupSessionScope ?? (legacyTopicSessionMode === "enabled" ? "group_topic" : "group");
1586
+ }
1587
+ function isFeishuTopicSessionScope(scope) {
1588
+ return scope === "group_topic" || scope === "group_topic_sender";
1589
+ }
1583
1590
  function evictGroupNameCache() {
1584
1591
  const now = Date.now();
1585
1592
  for (const [key, val] of groupNameCache) if (val.expiresAt <= now) groupNameCache.delete(key);
@@ -1830,13 +1837,35 @@ async function handleFeishuMessage(params) {
1830
1837
  cfg: feishuCfg,
1831
1838
  groupId: ctx.chatId
1832
1839
  }) : void 0;
1840
+ const groupSessionScope = isGroup ? resolveConfiguredFeishuGroupSessionScope({
1841
+ groupConfig,
1842
+ feishuCfg
1843
+ }) : null;
1844
+ let effectiveThreadId = ctx.threadId;
1845
+ if (isGroup && ctx.chatType === "topic_group" && !effectiveThreadId && isFeishuTopicSessionScope(groupSessionScope ?? "group")) try {
1846
+ const hydratedThreadId = (await getMessageFeishu({
1847
+ cfg,
1848
+ accountId: account.accountId,
1849
+ messageId: ctx.messageId
1850
+ }))?.threadId?.trim();
1851
+ if (hydratedThreadId) {
1852
+ ctx = {
1853
+ ...ctx,
1854
+ threadId: hydratedThreadId
1855
+ };
1856
+ effectiveThreadId = hydratedThreadId;
1857
+ log(`feishu[${account.accountId}]: hydrated topic thread_id=${hydratedThreadId} for message=${ctx.messageId}`);
1858
+ }
1859
+ } catch (err) {
1860
+ log(`feishu[${account.accountId}]: failed to hydrate topic thread_id for message=${ctx.messageId}: ${String(err)}`);
1861
+ }
1833
1862
  const effectiveGroupSenderAllowFrom = isGroup ? (groupConfig?.allowFrom?.length ?? 0) > 0 ? groupConfig?.allowFrom ?? [] : feishuCfg?.groupSenderAllowFrom ?? [] : [];
1834
1863
  const groupSession = isGroup ? resolveFeishuGroupSession({
1835
1864
  chatId: ctx.chatId,
1836
1865
  senderOpenId: ctx.senderOpenId,
1837
1866
  messageId: ctx.messageId,
1838
1867
  rootId: ctx.rootId,
1839
- threadId: ctx.threadId,
1868
+ threadId: effectiveThreadId,
1840
1869
  chatType: ctx.chatType,
1841
1870
  groupConfig,
1842
1871
  feishuCfg
package/dist/setup-api.js CHANGED
@@ -1,2 +1,2 @@
1
- import { i as feishuSetupAdapter, n as feishuSetupWizard, t as feishuPlugin } from "./channel-BOejZIqb.js";
1
+ import { i as feishuSetupAdapter, n as feishuSetupWizard, t as feishuPlugin } from "./channel-BegH3cJm.js";
2
2
  export { feishuPlugin, feishuSetupAdapter, feishuSetupWizard };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openclaw/feishu",
3
- "version": "2026.5.5-beta.1",
3
+ "version": "2026.5.5-beta.2",
4
4
  "description": "OpenClaw Feishu/Lark channel plugin (community maintained by @m1heng)",
5
5
  "repository": {
6
6
  "type": "git",
@@ -16,7 +16,7 @@
16
16
  "openclaw": "workspace:*"
17
17
  },
18
18
  "peerDependencies": {
19
- "openclaw": ">=2026.5.5-beta.1"
19
+ "openclaw": ">=2026.5.5-beta.2"
20
20
  },
21
21
  "peerDependenciesMeta": {
22
22
  "openclaw": {
@@ -47,10 +47,10 @@
47
47
  "minHostVersion": ">=2026.4.25"
48
48
  },
49
49
  "compat": {
50
- "pluginApi": ">=2026.5.5-beta.1"
50
+ "pluginApi": ">=2026.5.5-beta.2"
51
51
  },
52
52
  "build": {
53
- "openclawVersion": "2026.5.5-beta.1"
53
+ "openclawVersion": "2026.5.5-beta.2"
54
54
  },
55
55
  "release": {
56
56
  "publishToClawHub": true,