
Security News
OWASP 2025 Top 10 Adds Software Supply Chain Failures, Ranked Top Community Concern
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.
whatsapp-wrapper
Advanced tools
Integration layer for WhatsApp Cloud API with Firestore for easy message storage and management.
Integration layer for WhatsApp Cloud API with Firestore for easy message storage and management.
The WhatsAppAPI Python package provides a comprehensive and easy-to-use interface for interacting with WhatsApp's API. This package enables developers to integrate WhatsApp messaging capabilities into their applications effortlessly. From sending texts, images, videos, and documents to handling media files and managing message databases, this package covers a wide range of functionalities to enhance communication solutions.
To install WhatsAppAPI, use pip:
pip install whatsappapi
To get started, import the WhatsAppAPI class from the package and configure it with your mobile ID and API token.
from whatsapp_wrapper import WhatsAppAPI
api = WhatsAppAPI(mobile_id='your_mobile_id', api_token='your_api_token')
Sending a text message is straightforward:
api.send_text(to='recipient_number', message='Hello, World!')
To send an image:
api.send_image(to='recipient_number', image_id_or_url='image_url', caption='Check this out!')
If you want to save messages to a Firestore database, you need to provide
a DatabaseConfig during initialization:
from whatsapp_wrapper.whatsapp_db import DatabaseConfig
db_config: DatabaseConfig = {
'credential_path': 'path/to/your/firestore/credential.json',
'backup_folder': 'path/to/backup/folder'
}
api = WhatsAppAPI(mobile_id='your_mobile_id', api_token='your_api_token', database_config=db_config)
Messages will then be automatically saved to the database.
You can provide a custom error handler function during initialization to handle API errors according to your application's requirements.
def custom_error_handler(response, data):
# Custom error handling logic
pass
api = WhatsAppAPI(mobile_id='your_mobile_id', api_token='your_api_token', error_handler=custom_error_handler)
For support, please open an issue on the project's GitHub page. Contributions are welcome! If you'd like to contribute, please fork the repository and submit a pull request.
This project is licensed under the MIT License - see the LICENSE file for details.
FAQs
Integration layer for WhatsApp Cloud API with Firestore for easy message storage and management.
We found that whatsapp-wrapper demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
OWASP’s 2025 Top 10 introduces Software Supply Chain Failures as a new category, reflecting rising concern over dependency and build system risks.

Research
/Security News
Socket researchers discovered nine malicious NuGet packages that use time-delayed payloads to crash applications and corrupt industrial control systems.

Security News
Socket CTO Ahmad Nassri discusses why supply chain attacks now target developer machines and what AI means for the future of enterprise security.