Puppeteer Page running web.whatsapp.com
the chat from which you want to subscribes to live location updates
callback that takes in a LiveLocationChangedEvent
boolean, if returns false then there were no valid live locations in the chat of chatId
Observable stream of participantChangedEvent
Observable stream of messages
Puppeteer Page running web.whatsapp.com
Add participant to Group
'0000000000-00000000@g.us'
'000000000000@c.us'
Load all messages in chat object from server.
contact detial as promise
Checks if a number is a valid whatsapp number
contact detial as promise
Sends a text message to given chat
Promise
{
status: 200,
gid: {
server: 'g.us',
user: '447777777777-1583678870',
_serialized: '447777777777-1583678870@g.us'
},
participants: [
{ '447777777777@c.us': [Object] },
{ '447444444444@c.us': [Object] }
]
}
Deletes message of given message id
The chat id from which to delete the message.
The specific message id of the message to be deleted
If it should only delete locally (message remains on the other recipienct's phone). Defaults to false.
nothing
Demote Admin of Group
'0000000000-00000000@g.us'
'000000000000@c.us'
Forward an array of messages to a specific chat using the message ids or Objects
'000000000000@c.us'
this can be any mixture of message ids or message objects
This indicates whether or not to skip your own messages from the array
Retrieves all chats
array of [Chat]
Retrieves all chats with messages
array of [Chat]
Retrieves all contacts
array of [Contact]
Retrieve all groups
array of groups
Retrieves all Messages in a chat
any
Retrieves all new Messages. where isNewMsg==true
list of messages
Retrieves all unread Messages. where ack==-1
list of messages
Retrieves Battery Level
Number
Find any product listings of the given number. Use this to query a catalog
id of buseinss profile (i.e the number with @c.us)
None
Retrieves chat object of given contact id
contact detial as promise
Retrieves chat object of given contact id
contact detial as promise
Returns the connecction state
Any of OPENING, PAIRING, UNPAIRED, UNPAIRED_IDLE, CONNECTED, TIMEOUT, CONFLICT, UNLAUNCHED, PROXYBLOCK, TOS_BLOCK, SMB_TOS_BLOCK, DEPRECATED_VERSION
Retrieves contact detail object of given contact id
contact detial as promise
Get the generated user agent, this is so you can send it to the decryption module.
String useragent of wa-web session
Get Admins of a Group
'0000000000-00000000@g.us'
Returns group members [Contact] objects
Retrieves group members as [Id] objects
group id
Returns an object with all of your host device details
Retrieves chat picture
Url of the chat picture or undefined if there is no picture for the chat.
Get the status of a contact
to '000000000000@c.us' returns: {id: string,status: string}
Retrieves all undread Messages
any
Retrieves if the phone is online. Please note that this may not be real time.
Boolean
Shuts down the page and browser
true
Removes the host device from the group
group id
Load all messages in chat object from server.
contact detial as promise
loads and Retrieves all Messages in a chat
any
Load more messages in chat object from server. Use this in a while loop
contact detial as promise
Promote Participant to Admin in Group
'0000000000-00000000@g.us'
'000000000000@c.us'
Remove participant of Group
'0000000000-00000000@g.us'
'000000000000@c.us'
string chatid
string reply text
string | Message the msg object or id to reply to.
Sends contact card to given chat id
'xxxx@c.us'
Sends a file to given chat, with caption or not, using base64. This is exactly the same as sendImage
chat id xxxxx@us.c
base64 data:image/xxx;base64,xxx
string xxxxx
string xxxxx
Sends a video to given chat as a gif by using a giphy link, with caption or not, using base64
chat id xxxxx@us.c
string xxxxx
Sends a image to given chat, with caption or not, using base64
chat id xxxxx@us.c
base64 data:image/xxx;base64,xxx
string xxxxx
string xxxxx
This function takes an image and sends it as a sticker to the recipient. This is helpful for sending semi-ephemeral things like QR codes. The advantage is that it will not show up in the recipients gallery. This function automatiicaly converts images to the required webp format.
Sends product with image to chat
string the caption you want to add to this message
string the @c.us number of the business account from which you want to grab the product
string the id of the product within the main catalog of the aforementioned business
Sends a location message to given chat
chat id: xxxxx@c.us
latitude: '51.5074'
longitude: '0.1278'
location text: 'LONDON!'
Sets a chat status to seen. Marks all messages as ack: 3
chat id: xxxxx@us.c
Sends a text message to given chat
chat id: xxxxx@us.c
text message
Sends a video to given chat as a gif, with caption or not, using base64
chat id xxxxx@us.c
base64 data:video/xxx;base64,xxx
string xxxxx
string xxxxx
Sets the chat state
The state you want to set for the chat. Can be TYPING (0), RECRDING (1) or PAUSED (2).
Set your profile name
String new name to set for your profile
set your about me
String new profile status
Simulate '...typing' in chat
'xxxx@c.us'
turn on similated typing, false to turn it off you need to manually turn this off.