@fatihjr/wa-wrapper
Version:
Baileys WhatsApp Web API wrapper.
53 lines (52 loc) • 1.37 kB
TypeScript
/// <reference types="long" />
import { proto } from "@whiskeysockets/baileys";
interface MsgTemplate {
t?: number | Long;
id?: string;
from?: string;
fromMe?: boolean;
chatId?: string;
isGroupMsg?: boolean;
sender?: string;
fromName?: string;
timestamp?: number | Long;
isEphemeralMessage?: boolean;
pushname?: string;
type?: string;
messageContent?: any;
isMedia?: boolean;
body?: string;
argument?: string;
getMedia?: () => void;
reply?: (text: string) => Promise<proto.WebMessageInfo>;
selectedButtonId?: string;
selectedButtonIndex?: number;
selectedRowId?: string;
mimetype?: string;
mentionedJidList?: string;
}
export interface MessageType extends proto.IWebMessageInfo, MsgTemplate {
quotedMsg?: MsgTemplate & {
selectedDisplayText?: string;
description?: string;
contentText?: string;
singleSelectReply?: {
selectedRowId: string;
};
caption?: string;
conversation?: string;
text?: string;
mentions?: string[];
contextInfo: proto.IContextInfo;
};
}
export declare const mediaType: string[];
export interface DataBase {
chat: DataChat[];
}
export interface DataChat {
wa: string;
isGroup: boolean;
}
export declare const defaultData: DataBase;
export {};