Skip to main content
Message templates are pre-approved message structures required by WhatsApp for any outbound message sent outside a 24-hour customer service window. Zexa lets you create, submit, and manage templates from the dashboard or API, and use them directly in campaigns and individual messages.

Why templates are required

WhatsApp Business API policy distinguishes between two types of conversations:
  • Session messages — replies sent within 24 hours of the customer’s last inbound message. These do not require a template.
  • Outbound proactive messages — notifications, alerts, OTPs, and marketing messages sent outside an active 24-hour session. These must use a pre-approved template.
Using templates ensures your messages meet WhatsApp’s content policies before they reach recipients. Attempting to send a freeform outbound message outside a session window will result in an API error.

Template components

A WhatsApp template is built from up to four components:
ComponentRequiredDescription
HeaderNoA title displayed above the body. Can be text, an image, or a document.
BodyYesThe main message text. Supports dynamic variables using {{1}}, {{2}}, etc.
FooterNoA short line of small text below the body, typically used for disclaimers or opt-out instructions.
ButtonsNoUp to two interactive buttons: Call to Action (e.g. visit URL, call number) or Quick Reply.

Create a template

1

Open New Template

In the Zexa dashboard, go to Messaging > Templates > New Template.
2

Name your template

Enter a template name using only lowercase letters, digits, and underscores — no spaces. For example: order_confirmation or shipping_update_v2.
3

Select a category

Choose the category that best describes your template:
  • Marketing — promotions, offers, product announcements
  • Utility — transactional notifications such as order confirmations and delivery updates
  • Authentication — OTP and verification codes
4

Write the body text

Type your message body. Insert dynamic variables using double curly braces and a sequential number: {{1}}, {{2}}, and so on. For example:
Your order {1} has been shipped and will arrive by {2}. Track it here: {3}
5

Add optional components

Optionally add a header (text or media), a footer (short text), and up to two buttons (call-to-action or quick reply).
6

Submit for approval

Review your template and click Submit for Approval. WhatsApp will review the content against its policies.

Using a template in a message

Once a template is approved, reference it by name when sending a message via the API. Pass runtime values for each variable in the variables array, in the same order as {{1}}, {{2}}, etc.
curl --request POST \
  --url https://api.zexa.ao/v1/messages \
  --header "Authorization: Bearer <api_key>" \
  --header "Content-Type: application/json" \
  --data '{
    "channel": "whatsapp",
    "to": "+244912345678",
    "from": "MYSENDER",
    "template": {
      "name": "order_confirmation",
      "language": "pt",
      "variables": ["#1234", "24 June 2026"]
    }
  }'
The language field accepts an IETF BCP 47 language tag (e.g. pt for Portuguese, en for English). Zexa will use the language variant of your template that matches the code you supply.

Template approval times

After submission, WhatsApp reviews the template content against its messaging policies. The typical review time is 1–2 business days. You can monitor the current status at any time under Messaging > Templates in the dashboard.

Template statuses

StatusDescription
pendingSubmitted and awaiting review by WhatsApp.
approvedApproved and ready to use in messages and campaigns.
rejectedNot approved. The dashboard shows the rejection reason. Revise and resubmit.
Use specific, concrete variable placeholders and provide example values when submitting your template. Templates are frequently rejected when reviewers cannot determine what a variable like {{1}} will contain. For example, annotate your submission with examples: {{1}} = "#1234", {{2}} = "24 June 2026".
Modifying an approved template — even minor wording changes — requires you to re-submit it for approval. The existing approved version remains active until the revised version is reviewed. Plan template updates ahead of any scheduled campaigns that depend on them.

Campaigns

Use approved templates to power WhatsApp broadcast campaigns.

Contacts

Manage the contact lists your template messages are sent to.

Sender IDs

Register a WhatsApp Sender ID to pair with your approved templates.