Variables
Const addAllNewMessagesListener
addAllNewMessagesListener: (callback: Function) => void
Type declaration
-
- (callback: Function): void
Const addParticipant
addParticipant: (groupId: string, contactId: string) => void
Type declaration
-
- (groupId: string, contactId: string): void
-
Parameters
-
groupId: string
-
contactId: string
Returns void
Const asyncLoadAllEarlierMessages
asyncLoadAllEarlierMessages: (contactId: string) => void
Type declaration
-
- (contactId: string): void
Const checkNumberStatus
checkNumberStatus: (contactId: string) => any
Const createGroup
createGroup: (groupName: string, contactId: string | string[]) => Promise<any>
Type declaration
-
- (groupName: string, contactId: string | string[]): Promise<any>
-
Parameters
-
groupName: string
-
contactId: string | string[]
Returns Promise<any>
Const demoteParticipant
demoteParticipant: (groupId: string, contactId: string) => void
Type declaration
-
- (groupId: string, contactId: string): void
-
Parameters
-
groupId: string
-
contactId: string
Returns void
Const forwardMessages
forward
Messages: (to: string, messages: string | (string | Message)[], skipMyMessages: boolean) => any
Type declaration
-
- (to: string, messages: string | (string | Message)[], skipMyMessages: boolean): any
-
Parameters
-
to: string
-
messages: string | (string | Message)[]
-
skipMyMessages: boolean
Returns any
Const getAllChatIds
getAllChatIds: () => string[]
Const getAllChats
getAllChats: () => any
Const getAllChatsWithMessages
getAllChatsWithMessages: (withNewMessageOnly?: boolean) => any
Type declaration
-
- (withNewMessageOnly?: boolean): any
-
Parameters
-
Optional withNewMessageOnly: boolean
Returns any
Const getAllChatsWithNewMsg
get
AllChatsWithNewMsg: () => Chat[]
Const getAllGroups
get
AllGroups: () => Chat[]
Const getAllMessagesInChat
get
AllMessagesInChat: (chatId: string, includeMe: boolean, includeNotifications: boolean) => [Message]
Type declaration
-
- (chatId: string, includeMe: boolean, includeNotifications: boolean): [Message]
-
Parameters
-
chatId: string
-
includeMe: boolean
-
includeNotifications: boolean
Const getAllNewMessages
getAllNewMessages: () => any
Const getAllUnreadMessages
getAllUnreadMessages: () => any
Const getBatteryLevel
getBatteryLevel: () => Number
Const getBusinessProfilesProducts
getBusinessProfilesProducts: (to: string) => any
Const getChat
get
Chat: (contactId: string) => Chat
Type declaration
-
- (contactId: string): Chat
Const getChatById
get
ChatById: (contactId: string) => Chat
Type declaration
-
- (contactId: string): Chat
Const getContact
get
Contact: (contactId: string) => Contact
Const getGeneratedUserAgent
getGeneratedUserAgent: (userAgent?: string) => string
Type declaration
-
- (userAgent?: string): string
-
Parameters
-
Optional userAgent: string
Returns string
Const getGroupAdmins
get
GroupAdmins: (groupId: string) => Contact[]
Const getGroupParticipantIDs
get
GroupParticipantIDs: (groupId: string) => Id[]
Const getMe
getMe: () => any
Const getProfilePicFromServer
getProfilePicFromServer: (chatId: string) => any
Const getStatus
getStatus: (contactId: string) => void
Type declaration
-
- (contactId: string): void
Const getUnreadMessages
getUnreadMessages: (includeMe: boolean, includeNotifications: boolean, use_unread_count: boolean) => any
Type declaration
-
- (includeMe: boolean, includeNotifications: boolean, use_unread_count: boolean): any
-
Parameters
-
includeMe: boolean
-
includeNotifications: boolean
-
use_unread_count: boolean
Returns any
Const getWAVersion
getWAVersion: () => String
Const isConnected
isConnected: () => Boolean
Const leaveGroup
leaveGroup: (groupId: string) => any
Const loadAllEarlierMessages
loadAllEarlierMessages: (contactId: string) => void
Type declaration
-
- (contactId: string): void
Const loadAndGetAllMessagesInChat
load
AndGetAllMessagesInChat: (chatId: string, includeMe: boolean, includeNotifications: boolean) => [Message]
Type declaration
-
- (chatId: string, includeMe: boolean, includeNotifications: boolean): [Message]
-
Parameters
-
chatId: string
-
includeMe: boolean
-
includeNotifications: boolean
Const loadEarlierMessages
load
EarlierMessages: (contactId: string) => Message[]
Const onAddedToGroup
onAddedToGroup: (callback: Function) => any
Type declaration
-
- (callback: Function): any
Const onLiveLocation
onLiveLocation: (chatId: string, callback: Function) => any
Type declaration
-
- (chatId: string, callback: Function): any
-
Parameters
-
chatId: string
-
callback: Function
Returns any
Const onParticipantsChanged
onParticipantsChanged: (groupId: string, callback: Function) => any
Type declaration
-
- (groupId: string, callback: Function): any
-
Parameters
-
groupId: string
-
callback: Function
Returns any
Const onStateChanged
onStateChanged: (callback: Function) => void
Type declaration
-
- (callback: Function): void
Const promoteParticipant
promoteParticipant: (groupId: string, contactId: string) => void
Type declaration
-
- (groupId: string, contactId: string): void
-
Parameters
-
groupId: string
-
contactId: string
Returns void
Const removeParticipant
removeParticipant: (groupId: string, contactId: string) => void
Type declaration
-
- (groupId: string, contactId: string): void
-
Parameters
-
groupId: string
-
contactId: string
Returns void
Const reply
reply
: (to
: string, content
: string, quotedMsg
: string | Message) => void
Type declaration
-
- (to: string, content: string, quotedMsg: string | Message): void
-
Parameters
-
to: string
-
content: string
-
quotedMsg: string | Message
Returns void
Const sendContact
sendContact: (to: string, contact: string | string[]) => any
Type declaration
-
- (to: string, contact: string | string[]): any
-
Parameters
-
to: string
-
contact: string | string[]
Returns any
Const sendFile
sendFile: (base64: string, to: string, filename: string, caption: string) => void
Type declaration
-
- (base64: string, to: string, filename: string, caption: string): void
-
Parameters
-
base64: string
-
to: string
-
filename: string
-
caption: string
Returns void
Const sendImage
sendImage: (base64: string, to: string, filename: string, caption: string) => void
Type declaration
-
- (base64: string, to: string, filename: string, caption: string): void
-
Parameters
-
base64: string
-
to: string
-
filename: string
-
caption: string
Returns void
Const sendImageAsSticker
sendImageAsSticker: (webpBase64: string, to: string, metadata?: any) => void
Type declaration
-
- (webpBase64: string, to: string, metadata?: any): void
-
Parameters
-
webpBase64: string
-
to: string
-
Optional metadata: any
Returns void
Const sendImageWithProduct
sendImageWithProduct: (base64: string, to: string, caption: string, bizNumber: string, productId: string) => any
Type declaration
-
- (base64: string, to: string, caption: string, bizNumber: string, productId: string): any
-
Parameters
-
base64: string
-
to: string
-
caption: string
-
bizNumber: string
-
productId: string
Returns any
Const sendLocation
sendLocation: (to: string, lat: any, lng: any, loc: string) => void
Type declaration
-
- (to: string, lat: any, lng: any, loc: string): void
-
Parameters
-
to: string
-
lat: any
-
lng: any
-
loc: string
Returns void
Const sendMessage
sendMessage: (to: string, content: string) => string
Type declaration
-
- (to: string, content: string): string
-
Parameters
-
to: string
-
content: string
Returns string
Const sendMessageWithThumb
sendMessageWithThumb: (thumb: string, url: string, title: string, description: string, chatId: string) => void
Type declaration
-
- (thumb: string, url: string, title: string, description: string, chatId: string): void
-
Parameters
-
thumb: string
-
url: string
-
title: string
-
description: string
-
chatId: string
Returns void
Const sendSeen
sendSeen: (to: string) => void
Const sendVideoAsGif
sendVideoAsGif: (base64: string, to: string, filename: string, caption: string) => void
Type declaration
-
- (base64: string, to: string, filename: string, caption: string): void
-
Parameters
-
base64: string
-
to: string
-
filename: string
-
caption: string
Returns void
Const setChatState
set
ChatState: (chatState: ChatState, chatId: string) => void
Const setMyName
setMyName: (newName: string) => void
Const setMyStatus
setMyStatus: (newStatus: string) => void
Type declaration
-
- (newStatus: string): void
Const simulateTyping
simulateTyping: (to: string, on: boolean) => void
Type declaration
-
- (to: string, on: boolean): void
Const smartDeleteMessages
smartDeleteMessages: (contactId: string, messageId: string[] | string, onlyLocal: boolean) => any
Type declaration
-
- (contactId: string, messageId: string[] | string, onlyLocal: boolean): any
-
Parameters
-
contactId: string
-
messageId: string[] | string
-
onlyLocal: boolean
Returns any
Const waitNewMessages
waitNewMessages: (rmCallback: boolean, callback: Function) => void
Type declaration
-
- (rmCallback: boolean, callback: Function): void
-
Parameters
-
rmCallback: boolean
-
callback: Function
Returns void