aahnik / wappdriver

Wondering how to send WhatsApp messages using Python using only 3 lines of code? You have come to the right place!
https://aahnik.github.io/wappdriver/
MIT License
46 stars 3 forks source link

Ability to add contacts to a broadcast list or groupchat #41

Closed technowhizz closed 3 years ago

technowhizz commented 3 years ago

Hi,

This is a great project and makes sending messages from python really really simple. However I was wondering if it was possible to add a way to add new contacts specified in a list to a broadcast list on WhatsApp or to a group on WhatsApp. The reason being is that I was planning on setting up a free service where subscribers can enter their WhatsApp number on a form which would the fire up a webhook and run a python program passing the parameters from the webhook through and then be automatically added to the relevant broadcast list.

Is this something that would be possible to add in the future?

Many thanks

aahnik commented 3 years ago

Hi @technowhizz , this is a fantastic idea. But i have some suggestions.

There are some constraints to your plan.

  1. This code cant be easily deployed to server, because of QR code hassle and some other obstacles
  2. WhatsApp's Official Business API is a paid service ( Facebook charges for it ). Zuckerberg may disable all unofficial scripts like wappdriver by simply putting some form of captcha and not allowing web automation.
  3. This script needs occasional updating of selectors, which is a manual and tedious process
  4. Hard to deploy this in Heroku, due to custom requirements of Chrome and ChromeDriver
  5. Lots of hassles about version matching

Thus, the best thing is to use Telegram.

Plus, in recent times, due to WhatsApp's policies, many people are leaving WhatsApp. In last few weeks, the users of telegram has surged up exponentially.

I will be leaving WhatsApp after August 2021, and after that wappdriver will not be maintained.

technowhizz commented 3 years ago

Hi Aahink, thanks for getting back to me so quick. I actually do have it deployed to a server as I copy over the session files and therefore it works perfectly headlessly. And yes I do realise that it could easily be stopped by a captcha.

I also aim to use telegram in addition to what'sapp. I just wanted to cater to as large of an audience as possible.

Thank you for having considered this however.

:)

All the best

On Wed, 20 Jan 2021, 6:43 am Aahnik Daw, notifications@github.com wrote:

Hi @technowhizz https://github.com/technowhizz , this is a fantastic idea. But i have some suggestions.

There are some constraints to your plan.

  1. This code cant be easily deployed to server, because of QR code hassle and some other obstacles
  2. WhatsApp's Official Business API is a paid service ( Facebook charges for it ). Zuckerberg may disable all unofficial scripts like wappdriver by simply putting some form of captcha and not allowing web automation.
  3. This script needs occasional updating of selectors, which is a manual and tedious process
  4. Hard to deploy this in Heroku, due to custom requirements of Chrome and ChromeDriver
  5. Lots of hassles about version matching

Thus, the best thing is to use Telegram.

  • it has free official bot api ( and as promised by Durov, it is going to stay free )
  • you can easily make channels with unlimited members, while WhatsApp Brodcast list has limited members
  • you dont need to save a contact, to send them message.
  • You could directly give link to telegram channel/group in the form. ( no need of webhook and hassle )
  • there are lots of free bots, for automating stuff in telegram

Plus, in recent times, due to WhatsApp's policies, many people are leaving WhatsApp. In last few weeks, the users of telegram has surged up exponentially.

I will be leaving WhatsApp after August 2021, and after that wappdriver will not be maintained.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/aahnik/wappdriver/issues/41#issuecomment-763376602, or unsubscribe https://github.com/notifications/unsubscribe-auth/AB2VE55RADOVG5UTIHSXXC3S2Z3QDANCNFSM4WKE56OA .

aahnik commented 3 years ago

@technowhizz , for headless did you make any change to the code ?

and, to which cloud server did you deploy ?

could you please describe how did you deploy ?

i have never run wappdriver outside of my computer.