Add implementation plan for sendMessage raw proto mode (raw: true) - #74
Open
innovatorssoft with Copilot wants to merge 5 commits into
Open
Add implementation plan for sendMessage raw proto mode (raw: true)#74innovatorssoft with Copilot wants to merge 5 commits into
sendMessage raw proto mode (raw: true)#74innovatorssoft with Copilot wants to merge 5 commits into
Conversation
Co-authored-by: innovatorssoft <113409822+innovatorssoft@users.noreply.github.com>
Copilot
AI
changed the title
Plan: add raw message sendMessage support
Add implementation plan for Aug 11, 2026
sendMessage raw proto mode (raw: true)
Copilot created this pull request from a session on behalf of
innovatorssoft
August 11, 2026 16:11
View session
Contributor
|
Thanks for opening this pull request and contributing to the project! The next step is for the maintainers to review your changes. If everything looks good, it will be approved and merged into the main branch. In the meantime, anyone in the community is encouraged to test this pull request and provide feedback. ✅ How to confirm it worksIf you’ve tested this PR, please comment below with: This helps us speed up the review and merge process. 📦 To test this PR locally:If you encounter any issues or have feedback, feel free to comment as well. |
Co-authored-by: innovatorssoft <113409822+innovatorssoft@users.noreply.github.com>
Co-authored-by: innovatorssoft <113409822+innovatorssoft@users.noreply.github.com>
innovatorssoft
approved these changes
Aug 11, 2026
Co-authored-by: innovatorssoft <113409822+innovatorssoft@users.noreply.github.com>
innovatorssoft
approved these changes
Aug 11, 2026
Co-authored-by: devin-ai-integration[bot] <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR addresses the request to support raw WhatsApp proto-shaped payloads in
sendMessage(for cases likeextendedTextMessage.contextInfo.externalAdReply) and to formalize how that mode should behave. It contributes a detailed implementation plan and PR scaffolding for the raw-message method branch.Scope
raw: true.AnyMessageContenttyping,generateWAMessageContent,generateWAMessageFromContent, andsendMessagerelay path).Planned implementation breakdown
Branch/PR setup
Summary by cubic
Adds opt-in raw proto mode to
sendMessagefor advanced WhatsApp messages. Previously only helper-shaped content was accepted; now withraw: true, we acceptWAProto.IMessagetop-level keys and build aWAProto.Messagedirectly, leaving default behavior unchanged.Validates raw payloads: disallows helper fields, requires only valid
proto.Messagekeys, rejects inherited/proto-function keys (e.g.,toJSON), and requires at least one top-level key. Proto keys that overlap helper names are allowed.Preserves quoting:
generateWAMessagemerges quoted metadata into rawcontextInfowithout changing the send pipeline.Types: adds
RawMessageContent(gated byraw: true) toAnyMessageContent.Implementation: new
buildRawMessageContentpath ingenerateWAMessageContentusingWAProto.Message.fromObject; definesMESSAGE_PROTO_KEYSand a helper-key denylist.Docs/tests: README and examples document raw mode; tests cover fidelity, key validation, mixed-field errors, proto-function keys, and quoted behavior.
Required usage: To send raw payloads, pass
raw: trueand only proto message keys; do not mix helper fields; payload must be non-empty.Written for commit 18a16a6. Summary will update on new commits.