Compare commits

..

1 Commits

Author SHA1 Message Date
Renato Alcara 1afbfc71cd fix: use MACOS platform to resolve 405 connection failure
WhatsApp servers reject UserAgent.Platform.WEB (value 14) since
Feb 2026, causing 405 on new device pairing. MACOS (value 24)
matches current WhatsApp Web behavior. Ref: Baileys#2365, #2370.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-01 09:53:00 -03:00
2 changed files with 1 additions and 9 deletions
-8
View File
@@ -113,14 +113,6 @@ export const cleanMessage = (message: WAMessage, meId: string, meLid: string) =>
msgKey.remoteJid = message.key.remoteJid
// set participant of the message
msgKey.participant = msgKey.participant || message.key.participant
} else {
// fromMe reactions/polls: normalise remoteJid to match the chat JID
// ensures DM reaction keys are consistent with group behavior
msgKey.remoteJid = message.key.remoteJid
// in groups, normalise participant for own messages too
if (message.key.participant) {
msgKey.participant = msgKey.participant || message.key.participant
}
}
}
}
+1 -1
View File
@@ -20,7 +20,7 @@ const getUserAgent = (config: SocketConfig): proto.ClientPayload.IUserAgent => {
secondary: config.version[1],
tertiary: config.version[2]
},
platform: proto.ClientPayload.UserAgent.Platform.WEB,
platform: proto.ClientPayload.UserAgent.Platform.MACOS,
releaseChannel: proto.ClientPayload.UserAgent.ReleaseChannel.RELEASE,
osVersion: '0.1',
device: 'Desktop',