Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add MetaAI (@bot) send/receive messages capability #1252

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

vphelipe
Copy link

@vphelipe vphelipe commented Feb 8, 2025

What this PR does
Adds capability to send messages to MetaAI (@bot) via Baileys
Implements message decryption from @bot addresses

To send messages:
sock.sendMessage("867051314767696@bot", { text: 'Hi meta ai!' });

Important: getMessage must be configured in the socket for proper decryption of MetaAI and @bot messages.

Message sending ✅
Message receiving and decryption ✅

🇧🇷

@whiskeysockets-bot
Copy link
Contributor

Thanks for your contribution.

The next step is to wait for review and approval to merge it to main repository

The community can help reacting with a thumb up (:thumbsup:) for approval and rocket (:rocket:) for who has tested it.

To test this PR you can run the following command below:

# NPM
npm install @whiskeysockets/baileys@vphelipe/Baileysbsb#master
# YARN v2
yarn add @whiskeysockets/baileys@vphelipe/Baileysbsb#master

@Skidy89
Copy link

Skidy89 commented Feb 8, 2025

this is good, but in whatsapp bussiness @bot is still a normal jid or sometimes a @c.us user

@Akkun3704
Copy link

Has anyone tried it? is it work?

@alequizao
Copy link

👍 👍 👍

Copy link
Collaborator

@purpshell purpshell left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  1. Remove the jid map
  2. add Usync protocol support (to get bot info)
  3. add a store for message secrets (hard until Storage format is released)
  4. type formatting, linting
  5. Eliminate the need for @s.whatsapp.net entirely (whatsapp bots do not need that)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants