> ## Documentation Index
> Fetch the complete documentation index at: https://docs.connectly.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Templates Overview

> How WhatsApp message templates work — components, variable syntax, button types, categories, and the Meta approval process ⏭️

WhatsApp message templates are pre-approved message formats you manage through Connectly and Meta's WhatsApp Manager. Because Meta approves them in advance, templates can be sent to any customer at any time — including first-time contacts and those outside the 24-hour session window.

<Info>
  Once a template is approved, use it to send messages via [Send template message](https://docs.connectly.ai/messaging/template-messages).
</Info>

***

## Template categories

Every template must belong to one of three categories:

| Category                                         | Description                                                                     |
| ------------------------------------------------ | ------------------------------------------------------------------------------- |
| `MESSAGE_TEMPLATE_GROUP_CATEGORY_MARKETING`      | Promotional messages, offers, product launches.                                 |
| `MESSAGE_TEMPLATE_GROUP_CATEGORY_UTILITY`        | Transactional messages — order confirmations, shipping updates, account alerts. |
| `MESSAGE_TEMPLATE_GROUP_CATEGORY_AUTHENTICATION` | OTP and verification codes.                                                     |

***

## Template components

A template is built from `template_components` — an ordered list of component objects. Each component is one of: header, body, footer, or button.

### Header

Template headers support four types:

| Type            | Description                                                      |
| --------------- | ---------------------------------------------------------------- |
| `TYPE_IMAGE`    | Image header. Provide an example image URL to speed up approval. |
| `TYPE_VIDEO`    | Video header. Provide an example video URL.                      |
| `TYPE_DOCUMENT` | Document header. Provide an example document URL.                |
| `TYPE_TEXT`     | Text header. Supports one variable (`{{1}}`).                    |

### Body

The main text of the template. Supports variables using `{{N}}` syntax — `{{1}}`, `{{2}}`, `{{3}}`, etc., numbered sequentially from 1 to 15.

<Warning>
  Variables must be numbered sequentially from 1. You cannot skip numbers or use duplicates. For example, `{{1}}`, `{{2}}`, `{{3}}` is valid; `{{1}}`, `{{3}}` is not.
</Warning>

### Footer

Optional plain text displayed below the body. Does not support variables.

### Buttons

Up to 3 buttons per template. Three types are supported:

| Type          | Description                                                                                                                                                 |
| ------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `quickReply`  | Sends the button text as a message when tapped. Can trigger automated responses.                                                                            |
| `url`         | Opens a URL in the customer's browser. Supports one dynamic suffix variable. Do not use shortened URLs (e.g. bit.ly) — WhatsApp automatically rejects them. |
| `phoneNumber` | Dials a phone number directly.                                                                                                                              |

<Warning>
  You cannot mix Quick Reply and Call-to-Action buttons in the same template. Use up to 3 Quick Reply buttons **or** Call-to-Action buttons (URL and/or phone) — not both.
</Warning>

***

## Carousel templates

Carousel templates display multiple cards in a horizontally scrollable format. Each card has its own header image, body text, and buttons.

Create a carousel template by including a `carousel` component in `template_components`. See [Create template](https://docs.connectly.ai/api-reference/create-template) for the full payload structure.

***

## Approval process

After you submit a template via the [Create template](https://docs.connectly.ai/api-reference/create-template) endpoint, Meta reviews it automatically. Templates are typically approved within 5 minutes but can take up to 24 hours. The template status starts as `MESSAGE_TEMPLATE_STATUS_PENDING` and transitions to approved or rejected.

Check the current status of your templates at any time using [Get templates](https://docs.connectly.ai/api-reference/create-template).

<Note>
  Media size limits apply to template headers. See [Meta's media documentation](https://developers.facebook.com/docs/whatsapp/on-premises/reference/media#post-processing) for the full list of constraints.
</Note>

***

## Next steps

<CardGroup cols={2}>
  <Card title="Create template" icon="plus" href="/business-management/create-template">
    Submit a new template to Meta for review.
  </Card>

  <Card title="Send template message" icon="message" href="/message-api/send-template-message">
    Use an approved template to send a message.
  </Card>
</CardGroup>
