refactor(feishu): remove unused send helpers · openclaw/openclaw@b4e5aa1
vincentkoc
·
2026-06-18
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -715,31 +715,6 @@ export async function editMessageFeishu(params: {
|
715 | 715 | return { messageId, contentType: "post" }; |
716 | 716 | } |
717 | 717 | |
718 | | -export async function updateCardFeishu(params: { |
719 | | -cfg: ClawdbotConfig; |
720 | | -messageId: string; |
721 | | -card: Record<string, unknown>; |
722 | | -accountId?: string; |
723 | | -}): Promise<void> { |
724 | | -const { cfg, messageId, card, accountId } = params; |
725 | | -const account = resolveFeishuRuntimeAccount({ cfg, accountId }); |
726 | | -if (!account.configured) { |
727 | | -throw new Error(`Feishu account "${account.accountId}" not configured`); |
728 | | -} |
729 | | - |
730 | | -const client = createFeishuClient(account); |
731 | | -const content = JSON.stringify(card); |
732 | | - |
733 | | -const response = await client.im.message.patch({ |
734 | | -path: { message_id: messageId }, |
735 | | -data: { content }, |
736 | | -}); |
737 | | - |
738 | | -if (response.code !== 0) { |
739 | | -throw new Error(`Feishu card update failed: ${response.msg || `code ${response.code}`}`); |
740 | | -} |
741 | | -} |
742 | | - |
743 | 718 | /** |
744 | 719 | * Build a Feishu interactive card with markdown content. |
745 | 720 | * Cards render markdown properly (code blocks, tables, links, etc.) |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。