egg_server/test/getChatHistory.ts
zhaoyingbo b992ee0b21
Some checks failed
Egg Server MIflow / build-image (push) Failing after 5m7s
feat(group-agent): 新增支持群组问答
2024-09-25 09:14:10 +00:00

15 lines
382 B
TypeScript

import { LarkService } from "../services"
const service = new LarkService("egg", "")
const currentTime = Math.floor(new Date().getTime() / 1000)
const yesterdayTime = currentTime - 24 * 60 * 60
const res = await service.message.getHistory(
"oc_c83f627bde3da39b01bbbfb026a00111",
yesterdayTime.toString(),
currentTime.toString()
)
console.log(JSON.stringify(res, null, 2))