This project sets up the WAHA (WhatsApp HTTP API) using Docker. WAHA allows you to interact with WhatsApp through an HTTP API.
- Docker
- Docker Compose
-
Clone the repository or download the files.
-
Create a
.envfile from the example:cp env.example .env
-
Configure your
.envfile:Open the
.envfile and fill in the required environment variables, such asWAHA_API_KEY,WAHA_DASHBOARD_USERNAME, andWAHA_DASHBOARD_PASSWORD. You can generate strong random values for these. -
Review the
docker-compose.ymlfile:The
docker-compose.ymlfile is configured to use the variables from your.envfile. You can customize the services and volumes as needed.
-
Start the services:
docker-compose up -d
-
Access the WAHA Dashboard:
Open your browser and navigate to
http://localhost:3000(or theWAHA_BASE_URLyou configured). You should see the WAHA dashboard. -
Access the Swagger UI:
The Swagger UI for the WhatsApp API is available at
http://localhost:3000/swagger.
The main configuration is done through the .env file. Here are some of the key variables:
WAHA_API_KEY: Your API key for securing the WAHA API.WAHA_DASHBOARD_USERNAME: Username for the WAHA dashboard.WAHA_DASHBOARD_PASSWORD: Password for the WAHA dashboard.WHATSAPP_DEFAULT_ENGINE: The WhatsApp engine to use (e.g.,WEBJS,GOWS).WAHA_BASE_URL: The base URL for the API.WHATSAPP_HOOK_URL: The URL for webhook notifications.
For more detailed configuration options, please refer to the official WAHA documentation.
To stop the services, run:
docker-compose down- Sessions: Session data is stored in the
sessionsdirectory, mounted as a volume. - Media: Media files are stored in the
mediadirectory, mounted as a volume.