@kamuridesu/whatframework
Version:
A simple WhatsApp Bot Framework on top of Baileys
23 lines (22 loc) • 849 B
TypeScript
import { IMessageHandler, EntryPoint, IBot } from "../../@types/types.js";
import { ParticipantAction, WAMessage, WAMessageKey } from "baileys";
declare class WAMessageHandler implements IMessageHandler {
private isModule;
private entryPointHandler?;
constructor(entrypoint?: EntryPoint);
handle(message: WAMessage, bot: IBot): Promise<void>;
handleUpdate(key: WAMessageKey, updates: Partial<WAMessage>, bot: IBot): Promise<void>;
handleNewMember(data: {
id: string;
author: string;
participants: string[];
action: ParticipantAction;
}, bot: IBot): Promise<void>;
handleRemoveMember(data: {
id: string;
author: string;
participants: string[];
action: ParticipantAction;
}, bot: IBot): Promise<void>;
}
export { WAMessageHandler as MessageHandler };