Releases: pedroslopez/whatsapp-web.js
v1.5.0 - Session takeover, link previews, send online status
Reconnect timeout on conflict
Two new options have been added to be able to reconnect the client when a conflict occurs due to another browser opening WhatsApp Web:
takeoverOnConflict
- (default false) If true will take control of the session after "takeoverTimeoutMs". If false, has same functionality as before where the client will disconnect.takeoverTimeoutMs
- (default 0) indicates how long it will wait before trying to takeover. By default it takes over right away (0), but you can set for example 10000 to takeover after 10 seconds.
Presence
You can now indicate the client is online by using client.sendPresenceAvailable
. This only lasts for a couple seconds.
Link previews
By default, link previews will now be included. This means that when a link is present in a message, it will look like this:
If you don't want this, you can disable it by sending linkPreview: false
as an option when sending a message.
Changelog
044f622 - feat: link previews
2b3c3e9 - docs: add new param to jsdoc for getProfilePicUrl
8528d9b - feat: get profile pic url by user ID
7eb7fa8 - feat: send online status
478f713 - feat: takeover on conflict
20bbe3d - readme: add discord logo to shield
33db17e - add discord link
v1.4.1 - Fix sending media
A change occurred in WhatsApp Web that broke sending media functionality. This patch fixes this issue.
Changelog
97e488b - chore: update supported WhatsApp Web version to 2.2013.7
8e011e0 - feat: get current whatsapp web version
470c7ae - feat: added MediaKey in order to see which sticker has been sent (#146)
f92f1ec - Fix uploadMedia arguments after origin code change (#153)
702a0ab - Update jsdoc to version 3.6.4 (#144)
v1.4.0 - Create groups, listen for battery changes
Highlights
- Create groups with the new
client.createGroup()
function - "change_battery" event will allow you to listen for whenever the battery changes
- Group events (join, leave, etc) were not working. This release fixes the issue.
Raw changelog
93a6173 - feat: battery percentage changed event (#126)
1780436 - fix: make pupBrowser and pupPage available sooner (#137)
7acbd3d - fix: properly set chatId
67435b2 - fix: group events were not being triggered
743ac93 - feat: allow setting timeouts via options
0a7412c - feat: create groups
v1.3.1
v1.3.0
This release includes a couple minor improvements:
- new utility function on Client that can be used to check if a certain ID is a valid whatsapp user
client.isRegisteredUser("[email protected]")
will return a promise that resolves to a boolean - new event
media_uploaded
to get when media has been successfully uploaded for a message - new option
restartOnAuthFail
that will automatically restart if an authentication failure has occurred when trying to sign in with a preexisting session
Raw changelog
9d0b58a - chore: mark version v1.3.0
842c4f0 - feat: check if ID is a valid whatsapp user
2dddc78 - fix: initialize takes no params
d8cd2d1 - chore: updated whatsapp web version
80d5783 - feat: new event for when media is uploaded
cb54487 - feat: add ack to message model
d08b343 - Added "restartOnAuthFail" as an option (#112)
ec1a80d - chore: bump version to v1.2.5-post
v1.2.5 - Fix for error thrown when trying to download nonexistent media
When attempting to download media file that has been deleted and cannot be downloaded anymore, undefined
is now returned from message.downloadMedia()
.
25b9637 - fix: properly handle unresolved media
5934ec5 - fix: return undefined when attempting to download nonexistent media
65542f6 - chore/fix: update requires for new moduleraid package
00c603e - chore: use published moduleraid
v1.2.4 - Fix for downloading old media messages
Fixes an issue that occurred when attempting to download media for old messages, where action from the user is required to initiate the process.
8599a6d - fix: properly download media if it has not been loaded
v1.2.3 - Performance issue fix part 2
The same fix applied to the add message listener has now been applied to all event handlers.
4fe7fa9 - fix: delegate all event handlers
v1.2.2 - Performance issue fix
When starting up the client with lots of chats and messages, the way the event handler for getting new messages worked was creating a performance issue that caused WhatsApp Web to lag and act very slow, meaning the time it took to be able to respond to new messages was greatly increased.
Raw changelog
8bdecad - fix: don't call event handler for new messages directly to puppeteer