fix(feishu): pass card_msg_content_type to get full card content (fix… · openclaw/openclaw@1db8ab3
liuhao1024
·
2026-06-15
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -200,6 +200,10 @@ describe("getMessageFeishu", () => {
|
200 | 200 | messageId: "om_1", |
201 | 201 | }); |
202 | 202 | |
| 203 | +expect(mockClientGet).toHaveBeenCalledWith({ |
| 204 | +params: { card_msg_content_type: "user_card_content" }, |
| 205 | +path: { message_id: "om_1" }, |
| 206 | +}); |
203 | 207 | expect(result).toEqual({ |
204 | 208 | messageId: "om_1", |
205 | 209 | chatId: "oc_1", |
@@ -470,6 +474,15 @@ describe("getMessageFeishu", () => {
|
470 | 474 | rootMessageId: "om_root", |
471 | 475 | }); |
472 | 476 | |
| 477 | +expect(mockClientList).toHaveBeenCalledWith({ |
| 478 | +params: { |
| 479 | +container_id_type: "thread", |
| 480 | +container_id: "omt_1", |
| 481 | +sort_type: "ByCreateTimeDesc", |
| 482 | +page_size: 21, |
| 483 | +card_msg_content_type: "user_card_content", |
| 484 | +}, |
| 485 | +}); |
473 | 486 | expect(result).toEqual([ |
474 | 487 | { |
475 | 488 | messageId: "om_file", |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -414,6 +414,7 @@ export async function getMessageFeishu(params: {
|
414 | 414 | |
415 | 415 | try { |
416 | 416 | const response = (await client.im.message.get({ |
| 417 | +params: { card_msg_content_type: "user_card_content" }, |
417 | 418 | path: { message_id: messageId }, |
418 | 419 | })) as FeishuGetMessageResponse; |
419 | 420 | |
@@ -477,6 +478,7 @@ export async function listFeishuThreadMessages(params: {
|
477 | 478 | // Results are reversed below to restore chronological order. |
478 | 479 | sort_type: "ByCreateTimeDesc", |
479 | 480 | page_size: Math.min(limit + 1, 50), |
| 481 | +card_msg_content_type: "user_card_content", |
480 | 482 | }, |
481 | 483 | })) as { |
482 | 484 | code?: number; |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。