# Send WhatsApp message templates

You can send WhatsApp message templates directly from Chat Flow using the [Send Template](/flow/action-nodes/send-template.md) node. You can use this node in any of your workflows, but it is typically used in [dynamic API flows ](/flow/workflow-management/create-new-flow/add-a-workflow.md)to initiate WhatsApp conversations with customers.&#x20;

{% hint style="success" %}
These WhatsApp template types are supported:

* Plain text templates.
* [Interactive templates with buttons](https://clickatell.gitbook.io/whatsapp-user-guide/channel-capabilities/whatsapp-message-templates/use-interactive-buttons-in-message-templates).
* [Media templates](https://guides.clickatell.com/whatsapp-channel/channel-capabilities/whatsapp-message-templates/use-media-in-message-templates).
  {% endhint %}

## **How to send WhatsApp message templates in Chat Flow**

Clickatell assists you in building out a [**dynamic API workflow**](/flow/workflow-management/create-new-flow/dynamic-api-workflows.md). This workflow is not user-facing and gets triggered by an incoming payload. It allows you to initiate engagement with your customers by sending a pre-approved WhatsApp template (using the [*Send Template*](/flow/action-nodes/send-template.md) node), prompting them to take action and trigger a standard workflow.

<figure><img src="/files/TEcctkNMlJMs3q0g0weo" alt=""><figcaption></figcaption></figure>

## Alternative method

You can also send WhatsApp message templates using the [*API Integration* node](/flow/action-nodes/action-nodes-api-integration.md). This is a more technical and roundabout way of sending templates, and therefore we recommend using the method [above](#how-to-send-whatsapp-message-templates-in-chat-flow).

{% hint style="success" %}
These WhatsApp template types are supported:

* Plain text template.
* [Interactive template with buttons](https://clickatell.gitbook.io/whatsapp-user-guide/channel-capabilities/whatsapp-message-templates/use-interactive-buttons-in-message-templates).
  {% endhint %}

### Message template configuration

To configure the API integration for message templates:

1. In the *Configuration* section of the navigation, click *API Integration -> + N*ew *API*.

<figure><img src="/files/pJcPYmrPwmUAriOCDcs3" alt=""><figcaption></figcaption></figure>

2. Complete the fields to [set up an API integration](/flow/configuration/api-integration.md):
   * Add a *Name* for your endpoint.
   * Enter the following *URL*: <https://platform.clickatell.com/v1/message>
   * Add the *Element Validation*, for example: HTTP\_Response\_Code.
   * Select "POST" as the *Method,* and *"*&#x61;pplication/json" as both the *Request Content-Type* and *Response Content-Type*.
   * Enter "Authorization" as the header *Key* (i.e., the API key for your integration that can be found by navigating to *My Workspaces ->API Integrations* in the Clickatell Portal), then enter the associated *Value*.

<figure><img src="/files/ADvS0f8NQ7J5OAjAwyFe" alt=""><figcaption></figcaption></figure>

3. Save your changes.

{% hint style="info" %}
Once configured, your API integration will be available for selection from the *Name* drop-down when [adding an API Integration node](/flow/action-nodes/action-nodes-api-integration.md).&#x20;
{% endhint %}

### API Integration node configuration

The images below show what the configuration of the *API Integration* node should look like for plain text and interactive templates.

#### **Plain text template**

<figure><img src="/files/m1Dt7ZjnmWmkk9TAZZlY" alt=""><figcaption></figcaption></figure>

#### Plain text template body&#x20;

```json
{
  "messages": [
    {
      "to": "2799900001",
      "channel": "whatsapp",
      "template": {
        "templateName": "welcome_notification_demo",
        "body": {
          "parameters": {
            "1": "Parameter 1",
            "2": "Parameter 2"
          }
        }
      }
    }
  ]
}
```

#### Interactive template

<figure><img src="/files/XIMlpnE9IaLufDWhHo9E" alt=""><figcaption></figcaption></figure>

#### Interactive template body

```json
{
  "messages": [
    {
      "to": "2710000000",
      "channel": "whatsapp",
      "template": {
        "templateName": "welcome_text_button",
        "body": {
          "parameters": {
            "1": "Keanan"
          }
        },
        "buttons": {
          "suggestedResponse": {
              "postbackData": {
                "1": "{\"buttonPressed\":\"menu\"}"
              }
            }
        }
      }
    }
  ]
}
```

{% hint style="info" %}
When using interactive templates, remember to [**add the correct keyword**](/flow/configuration/using-keywords.md) in the *Keywords* section. The keyword must be the same as the button shown on the interactive template, e.g., "buttonPressed":"menu".
{% endhint %}

### Workflow example

The example below displays a workflow in which:

1. The *Text Display* node is used to display a welcome message to the customer.&#x20;
2. An API call is then made to send the WhatsApp message template to the customer.
3. In response to the call, another *Text Display* node is used to inform the customer that the template was sent successfully.

<figure><img src="/files/aQeb2jFu3CT8j67i96HL" alt=""><figcaption></figcaption></figure>


---

# 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://guides.clickatell.com/flow/channel-capabilities/use-whatsapp-with-chat-flow/send-whatsapp-message-templates.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.
