WhatsApp Business enables businesses to send notifications, alerts, and transactional messages to customers through WhatsApp. Enbbox integrates with the Meta Cloud API for WhatsApp Business.
[!IMPORTANT]
WhatsApp Business requires a Meta Business account, a verified phone number, and approval for message templates before you can send notifications. Setup takes 15-30 minutes.
Enbbox automatically uses the subscriber's phone field for WhatsApp delivery — no extra credentials needed in most cases:
import { SubscribersApi, Configuration } from "@enbbox/api";const config = new Configuration({ accessToken: "your-api-key" });const subscribersApi = new SubscribersApi(config);// Just set the phone when creating or updating the subscriberawait subscribersApi.createSubscriber({ subscriberId: "subscriber-123", phone: "+1234567890", // E.164 format — used for WhatsApp and SMS});
[!TIP]
If a subscriber's WhatsApp number differs from their primary phone, you can override it with provider-specific credentials:
import { SubscriberCredentialsApi, Configuration } from "@enbbox/api";const config = new Configuration({ accessToken: "your-api-key" });const credentialsApi = new SubscriberCredentialsApi(config);await credentialsApi.setCredentials("subscriber-123", "whatsapp-business", { credentials: { phone_number: "+0987654321" },});