From 344717a2d52edbac61cef6c9359af3a20c0655a1 Mon Sep 17 00:00:00 2001 From: Vincent Koc Date: Fri, 3 Apr 2026 21:30:09 +0900 Subject: [PATCH] refactor(feishu): split comment handler seam --- extensions/feishu/src/comment-handler-runtime-api.ts | 3 +++ extensions/feishu/src/comment-handler.ts | 8 ++++---- 2 files changed, 7 insertions(+), 4 deletions(-) create mode 100644 extensions/feishu/src/comment-handler-runtime-api.ts diff --git a/extensions/feishu/src/comment-handler-runtime-api.ts b/extensions/feishu/src/comment-handler-runtime-api.ts new file mode 100644 index 00000000000..326f2cb7022 --- /dev/null +++ b/extensions/feishu/src/comment-handler-runtime-api.ts @@ -0,0 +1,3 @@ +export type { OpenClawConfig as ClawdbotConfig } from "openclaw/plugin-sdk/config-runtime"; +export type { RuntimeEnv } from "openclaw/plugin-sdk/runtime"; +export { createChannelPairingController } from "openclaw/plugin-sdk/channel-pairing"; diff --git a/extensions/feishu/src/comment-handler.ts b/extensions/feishu/src/comment-handler.ts index f5cc8eadda6..e92ed12c219 100644 --- a/extensions/feishu/src/comment-handler.ts +++ b/extensions/feishu/src/comment-handler.ts @@ -1,12 +1,12 @@ import type { ResolvedAgentRoute } from "openclaw/plugin-sdk/routing"; +import { resolveFeishuRuntimeAccount } from "./accounts.js"; +import { createFeishuClient } from "./client.js"; +import { createFeishuCommentReplyDispatcher } from "./comment-dispatcher.js"; import { createChannelPairingController, type ClawdbotConfig, type RuntimeEnv, -} from "../runtime-api.js"; -import { resolveFeishuRuntimeAccount } from "./accounts.js"; -import { createFeishuClient } from "./client.js"; -import { createFeishuCommentReplyDispatcher } from "./comment-dispatcher.js"; +} from "./comment-handler-runtime-api.js"; import { buildFeishuCommentTarget } from "./comment-target.js"; import { deliverCommentThreadText } from "./drive.js"; import { maybeCreateDynamicAgent } from "./dynamic-agent.js";