Skip to content

Commit c3e2ca3

Browse files
committed
fix(feishu): configure websocket ping timeout
1 parent 48b0f4e commit c3e2ca3

2 files changed

Lines changed: 3 additions & 8 deletions

File tree

‎extensions/feishu/src/client.test.ts‎

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -469,8 +469,7 @@ describe("createFeishuWSClient proxy handling", () => {
469469

470470
const options = firstWsClientOptions();
471471
expect(options.wsConfig).toEqual({
472-
PingInterval: 30,
473-
PingTimeout: 3,
472+
pingTimeout: 3,
474473
});
475474
});
476475

@@ -493,8 +492,7 @@ describe("createFeishuWSClient proxy handling", () => {
493492
expect(options.onReconnected).toBe(onReconnected);
494493
expect(options.onReconnecting).toBe(onReconnecting);
495494
expect(options.wsConfig).toEqual({
496-
PingInterval: 30,
497-
PingTimeout: 3,
495+
pingTimeout: 3,
498496
});
499497
});
500498

‎extensions/feishu/src/client.ts‎

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,7 @@ const FEISHU_USER_AGENT = `openclaw-feishu-builtin/${pluginVersion}/${process.pl
2323
export { FEISHU_USER_AGENT };
2424

2525
const FEISHU_WS_CONFIG = {
26-
PingInterval: 30,
27-
PingTimeout: 3,
26+
pingTimeout: 3,
2827
} as const;
2928

3029
/** User-Agent header value for all Feishu API requests. */
@@ -228,8 +227,6 @@ export async function createFeishuWSClient(
228227
loggerLevel: feishuClientSdk.LoggerLevel.info,
229228
wsConfig: FEISHU_WS_CONFIG,
230229
...(agent ? { agent } : {}),
231-
} as ConstructorParameters<typeof feishuClientSdk.WSClient>[0] & {
232-
wsConfig: typeof FEISHU_WS_CONFIG;
233230
});
234231
}
235232

0 commit comments

Comments
 (0)