Renato Alcara
313f304ddf
feat: add WebdPayload with E2E media support and features bitmask
...
Add webdPayload to WebInfo during connection with:
- supportsE2EImage/Video/Audio/Document = true
- supportsMediaRetry = true
- features bitmask with view-once capability flag
This may enable the WA server to deliver view-once media content
to Baileys companions instead of just <unavailable> placeholders.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-12 23:43:17 -03:00
Renato Alcara
a74fbb08a6
fix: request view-once content via PDO from primary phone
...
When receiving <unavailable type='view_once'/>, attempt to request
the actual media content from the primary phone via PDO
(Peer Data Operation / PLACEHOLDER_MESSAGE_RESEND).
If the phone responds, the full media (url, mediaKey, directPath)
arrives via messages.upsert, allowing consumers to display the image.
Falls back to placeholder if PDO fails or phone doesn't respond.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-12 22:21:02 -03:00
Renato Alcara
0e6bad72bb
fix: emit view-once placeholder from unavailable handler
...
The early unavailable handler at line ~2261 was intercepting
view_once stanzas and silently discarding them (sendMessageAck + return)
before the view_once_unavailable_fanout handler could emit them.
Now emits a viewOnceMessage placeholder with isViewOnce=true so
consumers receive the event in messages.upsert.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com >
2026-04-12 16:14:13 -03:00
Renato Alcara
90061dd6a1
fix: allow msmsg decryption and emit view-once unavailable fanout ( #355 )
...
Two issues found during view-once testing on linked devices:
1. msmsg block removal:
The "temporary fix" that discarded all msmsg-type encrypted messages
was also blocking legitimate view-once messages. On linked devices,
view-once arrives as msmsg encryption type. The block was originally
added to prevent crashes from missing messageSecret, but the existing
try/catch in the decrypt path already handles those errors gracefully
by marking the message as a CIPHERTEXT stub.
2. view_once_unavailable_fanout emission:
When a linked device receives a view-once, the WA server sends only
<unavailable type="view_once"/> (no <enc> with actual media content).
Previously this was silently acknowledged without emitting any event,
so consumers (zpro, astra-api, etc.) never knew a view-once arrived.
Now it emits the message as a CIPHERTEXT stub with key.isViewOnce=true
so consumers can display "view-once message received" in their UI.
Co-Authored-By: Renato Alcara
2026-04-12 11:46:42 -03:00
Renato Alcara
47b0940428
chore: update WhatsApp Web version to v2.3000.1037166441 ( #357 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-04-12 06:15:16 -03:00
github-actions[bot]
90937af374
chore: update proto/version to v2.3000.1037162330 ( #356 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-04-12 01:00:42 -03:00
Renato Alcara
703b5da554
chore: update WhatsApp Web version to v2.3000.1037137890 ( #354 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-04-11 06:13:10 -03:00
github-actions[bot]
8c61ce5f8e
chore: update proto/version to v2.3000.1037082622 ( #353 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-04-11 00:48:54 -03:00
Renato Alcara
000932accd
chore: update WhatsApp Web version to v2.3000.1037061899 ( #352 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-04-10 06:25:40 -03:00
github-actions[bot]
8df39c320e
chore: update proto/version to v2.3000.1037038379 ( #351 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-04-10 01:00:21 -03:00
Renato Alcara
22e758b1e6
chore: update WhatsApp Web version to v2.3000.1036978211 ( #350 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-04-09 06:26:10 -03:00
github-actions[bot]
f473484852
chore: update proto/version to v2.3000.1036961647 ( #349 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-04-09 00:55:22 -03:00
Renato Alcara
4dde4c5500
chore: update WhatsApp Web version to v2.3000.1036893687 ( #348 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-04-08 06:22:46 -03:00
github-actions[bot]
e3cf104b59
chore: update proto/version to v2.3000.1036861941 ( #347 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-04-08 00:56:53 -03:00
Renato Alcara
aa0a3c2b71
chore: update WhatsApp Web version to v2.3000.1036798793 ( #346 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-04-07 06:23:04 -03:00
github-actions[bot]
bdbad50074
chore: update proto/version to v2.3000.1036772203 ( #345 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-04-07 00:56:17 -03:00
Renato Alcara
45b322abac
chore: update WhatsApp Web version to v2.3000.1036709653 ( #344 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-04-06 06:25:21 -03:00
github-actions[bot]
3c3cf32027
chore: update proto/version to v2.3000.1036704126 ( #343 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-04-06 00:59:26 -03:00
Renato Alcara
99d85498fb
chore: update WhatsApp Web version to v2.3000.1036691526 ( #342 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-04-05 06:12:28 -03:00
github-actions[bot]
d6414f203b
chore: update proto/version to v2.3000.1036688876 ( #340 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-04-05 00:58:23 -03:00
Renato Alcara
b98df92d8c
chore: update WhatsApp Web version to v2.3000.1036673976 ( #341 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-04-04 06:11:52 -03:00
Renato Alcara
00a8113d47
chore: update WhatsApp Web version to v2.3000.1036606219 ( #339 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-04-03 06:17:29 -03:00
github-actions[bot]
670ac582f9
chore: update proto/version to v2.3000.1036588306 ( #338 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-04-03 00:54:16 -03:00
Renato Alcara
08910c61e1
chore: update WhatsApp Web version to v2.3000.1036512893 ( #337 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-04-02 06:20:16 -03:00
github-actions[bot]
cb5e42c46e
chore: update proto/version to v2.3000.1036469328 ( #336 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-04-02 00:53:53 -03:00
Renato Alcara
30e986ee67
chore: update WhatsApp Web version to v2.3000.1036420555 ( #335 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-04-01 06:24:15 -03:00
github-actions[bot]
60302d73d5
chore: update proto/version to v2.3000.1036375660 ( #334 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-04-01 01:01:11 -03:00
Renato Alcara
3baa494fad
chore: update WhatsApp Web version to v2.3000.1036326359 ( #333 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-03-31 06:54:53 -03:00
github-actions[bot]
59cad85544
chore: update proto/version to v2.3000.1036244875 ( #332 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-03-31 02:02:42 -03:00
Renato Alcara
ad53bc0982
chore: update WhatsApp Web version to v2.3000.1036229535 ( #331 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-03-30 07:06:44 -03:00
github-actions[bot]
fb8f51be52
chore: update proto/version to v2.3000.1036224280 ( #330 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-03-30 02:15:18 -03:00
Renato Alcara
9a7d43d4ba
chore: update WhatsApp Web version to v2.3000.1036208776 ( #329 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-03-29 06:27:46 -03:00
github-actions[bot]
578efe945f
chore: update proto/version to v2.3000.1036204984 ( #328 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-03-29 02:03:52 -03:00
Renato Alcara
e999fc1aa1
chore: update WhatsApp Web version to v2.3000.1036185592 ( #327 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-03-28 06:27:30 -03:00
github-actions[bot]
9fd88b533d
chore: update proto/version to v2.3000.1036173230 ( #326 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-03-28 01:46:40 -03:00
Renato Alcara
43f3525437
chore: update WhatsApp Web version to v2.3000.1036094556 ( #325 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-03-27 06:44:22 -03:00
github-actions[bot]
fdcbd3fc1d
chore: update proto/version to v2.3000.1036065881 ( #324 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-03-27 02:00:33 -03:00
Renato Alcara
cdc89316f0
chore: update WhatsApp Web version to v2.3000.1036016053 ( #323 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-03-26 06:53:02 -03:00
github-actions[bot]
3050c329c5
chore: update proto/version to v2.3000.1036000318 ( #319 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-03-26 01:59:23 -03:00
Renato Alcara
3ef7474842
fix: respect caller-provided waveform for PTT audio messages ( #322 )
...
* fix: respect caller-provided waveform for PTT audio messages
When sending PTT audio with an explicit waveform, Baileys unconditionally
overwrites it with getAudioWaveform() which returns undefined when
audio-decode is not installed — resulting in a flat line on WhatsApp.
Now only invokes getAudioWaveform() when no waveform is already provided,
matching the existing pattern used for jpegThumbnail (line 241).
Validated via CDP + Frida interception: WhatsApp waveform format is
64 bytes Uint8Array, values 0-99, byte-for-byte identical between
Android (audio_data table) and WA Web (model-storage IDB).
Ref: WhiskeySockets/Baileys#2443
Co-Authored-By: Renato Alcara
2026-03-25 15:51:52 -03:00
Renato Alcara
9dfd31d109
chore: update WhatsApp Web version to v2.3000.1035913242 ( #321 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-03-25 06:42:47 -03:00
Renato Alcara
e686c5a2e1
chore: update WhatsApp Web version to v2.3000.1035819858 ( #320 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-03-24 06:44:53 -03:00
Renato Alcara
466c14ff82
chore: update WhatsApp Web version to v2.3000.1035718650 ( #318 )
...
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-03-23 06:53:55 -03:00
Renato Alcara
03bc03b318
Merge branch 'master' of https://github.com/rsalcara/InfiniteAPI
2026-03-23 01:59:15 -03:00
Renato Alcara
d83971d15e
fix: remove duplicate isViewOnceMsg/viewOnceMeRecipients declarations
...
Merge duplicou o bloco — TS2451 Cannot redeclare block-scoped variable.
Mantida a versão correta (verifica viewOnceInner?.imageMessage?.viewOnce).
Co-Authored-By: Renato Alcara
2026-03-23 01:59:08 -03:00
github-actions[bot]
14f0321d7c
chore: update proto/version to v2.3000.1035715252 ( #317 )
...
Co-authored-by: rsalcara <rsalcara@users.noreply.github.com >
2026-03-23 01:56:01 -03:00
Renato Alcara
b65a8a334b
chore: resolve merge conflict in messages-send.ts (comment-only)
...
Conflict was between Portuguese and English comment for phash/DSM block.
Kept HEAD (our) version.
Co-Authored-By: Renato Alcara
2026-03-23 01:54:46 -03:00
Renato Alcara
28e9e5b912
feat: implement view-once message sending and receiving
...
- Add viewonce-image/video/audio to MEDIA_PATH_MAP and MEDIA_HKDF_KEY_MAPPING
- messages-send: use viewOnceMessageV2 wrapper, omit companion devices for DSM
(server auto-generates <unavailable type="view_once"/> for linked devices)
- messages-send: fix mediatype detection by unwrapping viewOnce before getMediaType
- messages-recv: handle <unavailable type="view_once"/> sync from primary device
- messages-recv: note — do NOT send view_once_read from linked device
Co-Authored-By: Renato Alcara
2026-03-23 01:53:55 -03:00
Renato Alcara
c6cb29fd80
feat: groups mention all + fix view-once upload path and wrapper
...
- Add mentionAll?: boolean to Mentionable type (upstream 6afde71691 )
- Set contextInfo.nonJidMentions=1 for @everyone group mentions
- Use viewOnceMessageV2 (field 55) wrapper instead of legacy viewOnceMessage (field 37)
- Set viewOnce=true on inner imageMessage/videoMessage/audioMessage
- Route view-once media uploads to /o1/mms/* CDN via mediaTypeOverride
Co-Authored-By: Renato Alcará
2026-03-23 01:52:43 -03:00
Renato Alcara
452df5d409
Feat/view once receive ( #316 )
...
* fix: detect view-once media (image/video/audio) on stanza 1 for linked devices
2026-03-23 00:38:05 -03:00