Free, open-source Python wrapper for the WhatsApp Cloud API.
Forked from Neurotech-HQ/heyoo
- Listening to events (messages, media, etc.)
- Sending messages
- Marking messages as read
- Sending Media (images, audio, video and documents)
- Sending location
- Sending interactive buttons
- Sending template messages
- Parsing messages and media received
Asynchronous app events are now available!
The docs are available in the wiki
Please test this feature out and leave feedbacks/report issues on GitHub!
NOTE: this feature is still in beta, so it may not work as expected. The FastAPI endpoint was not completely tested. Please report any issue you find or open a PR to fix it!
To install the library you can either use pip:
pip install whatsapp-python
or git:
git clone https://github.com/filipporomani/whatsapp.git
cd whatsapp
python3 setup.py install
The documentation for the library is available in the wiki
While using third-party API providers of the WhatsApp API may have some monthly fees, using the WhatsApp API provided directly by Facebook is way cheaper. The first 1000 chats created are free, then there is a pay-as-you-go fee that is paid for each conversation started.
All the prices are available in the WhatsApp API docs
Any version >1.1.2 is incompatible with the original heyoo
library! Be careful updating! Read the docs first!
Any version <=1.1.2 is fully compatible with the original heyoo
library and doesn't include any breaking change.
You can ignore this warning if it's your first time using the library.
Switching from heyoo to whatsapp-python doesn't require any change for versions up to 1.1.2: just uninstall the old, install the new and change the import name from heyoo
to whatsapp
.
For version which are GREATER THEN 1.1.2, messages have became objects, so you need to change your code to use the new methods.
Note: docs for version 1.1.2 are available in the dedicated wiki page.
If you are facing any issues or have any questions, please open an issue on the GitHub repository
This is an opensource project published under the MIT License
: LICENSE.