# Send WhatsApp notifications using the BotPenguin APIs

Before we start, Let's understand the basic workflow.

### Workflow for sending WhatsApp notifications <a href="#workflow-for-sending-whatsapp-notifications" id="workflow-for-sending-whatsapp-notifications"></a>

<figure><img src="https://help.botpenguin.com/~gitbook/image?url=https%3A%2F%2F1745791824-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FAPDb8cKQtGlIAfgHjcsQ%252Fuploads%252FZvGm35sl9foia6oHPQwl%252Ffile.excalidraw.svg%3Falt%3Dmedia%26token%3Db241d8f9-691c-4d3e-800c-c5f644ddab72&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=21e00b46&#x26;sv=2" alt=""><figcaption></figcaption></figure>

### Setting up WhatsApp Notifications <a href="#setting-up-whatsapp-notifications" id="setting-up-whatsapp-notifications"></a>

To create a notification bot with BotPenguin, follow these steps:

**Step 1: Get Your API Key**

* Start by obtaining your API key for integration. Refer to the below doc for more details

[📄WhatsApp Cloud API](https://help.botpenguin.com/~/changes/483/api-references/whatsapp-cloud-api)

**Step 2: Setup the WebHook Endpoint**

* Configure the WebHook endpoint where your bot will send and receive messages. Refer to the below doc for more details

[📄WhatsApp Cloud API](https://help.botpenguin.com/~/changes/483/api-references/whatsapp-cloud-api)

**Step 3: Create Notification Templates**

* Ensure you've created the required notification templates that your bot will use for messaging.

**Step 4: Retrieve Notification Templates**

* Call the "Get Template API" to retrieve all the templates you've created. Refer to the below doc for more details

[GET Templates List](https://help.botpenguin.com/~/changes/483/api-references/whatsapp-cloud-api/get-templates-list)

**Step 5: Send Messages**

* Utilize the "POST WhatsApp Template API" to send messages using the templates. Refer to the below doc for more details

[POST WhatsApp Template Message](https://help.botpenguin.com/~/changes/483/api-references/whatsapp-cloud-api/post-whatsapp-template-message)

**Step 6: Configure Webhook Handling**

* Implement the necessary code to handle the webhook on the configured endpoint. This is where your bot will receive and process incoming messages and notifications.

**Step 7: You're Done!**

* With these steps completed, your notification bot is ready to send and receive messages using your templates, ensuring efficient and effective communication with your audience.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.botpenguin.com/platform-guidelines-and-trainings/unlock-power-of-botpenguin/send-whatsapp-notifications-using-the-botpenguin-apis.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
