12 lines
299 B
JavaScript
12 lines
299 B
JavaScript
import { listMessages } from "../../2-identity/db/repo.js";
|
|
|
|
export async function handleListMessages({ tenantId, chat_id, limit = "200" }) {
|
|
if (!chat_id) return [];
|
|
return listMessages({
|
|
tenant_id: tenantId,
|
|
wa_chat_id: String(chat_id),
|
|
limit: parseInt(limit, 10) || 200,
|
|
});
|
|
}
|
|
|