Skip to main content
POST
Send a WhatsApp template
Send an approved template to one recipient and record the send under an existing broadcast. This request does not start the broadcast or send to its saved contact list. The recipient and delivery status appear in that broadcast’s recipient history. This API accepts template messages only. To reply with a free-form message during an open WhatsApp conversation, use Conversations in the dashboard.

End-to-end setup

  1. Connect a WhatsApp number to the project.
  2. Create a WhatsApp broadcast, select its sender, attach an approved template, and save it. The broadcast can stay in draft; this API call does not launch it.
  3. Note the names of the variables in the attached template. Pass their values in data.
  4. Create a project API key with the whatsapp:create scope. Keep the key on your server.
  5. Copy the organization, project, and broadcast IDs into the request below.
The broadcast supplies the WhatsApp channel, sender, and template. The API key must belong to the organization and project in the URL.

Authentication

Send the project API key as a Bearer token. See API authentication.
Required scope: whatsapp:create

Path parameters

string
required
Organization that owns the project and API key.
string
required
Project containing the broadcast and connected WhatsApp number.
string
required
Existing broadcast used to track this send. Its saved contact list is not sent.

Request body

string
required
Recipient phone number in international format, such as +14155552671. Spaces, parentheses, periods, and hyphens are removed.
object
Named values for variables in the broadcast’s attached template. Keys must match the template variables. Use header_media_url for a dynamic image, video, or document header, and header_location for a location header. Omit data or pass an empty object if the template has no variables.
Fields such as type and payload are not accepted. The template must be attached to the broadcast; callers cannot select a different template in the request.

Example 1: send a template with named body variables

Suppose the broadcast’s approved template has the variables first_name and order_id.

Example 2: send a template with a dynamic image header

For a template with an image header and a first_name body variable, pass a public HTTPS URL in header_media_url.
Meta must be able to fetch the HTTPS media URL without signing in. This API does not upload files.

Example 3: send a template with no variables

Idempotent retries

You can send an Idempotency-Key header of 1–255 characters. If the original request included the header, retry a timeout with the same key and request body. For 24 hours, repeating the same key and request returns the saved result instead of sending again. Reusing a key with a different request returns 409 Conflict. If the provider outcome is still being resolved, the API returns 202 Accepted while it waits for a delivery status update. Without an idempotency key on the original request, a timeout retry may send a duplicate.

Response

When Meta accepts the request, the API returns the internal message ID, broadcast ID, recipient, status, and Meta message ID when available. Acceptance does not mean the recipient has received or read the message; delivery updates appear in the broadcast recipient history.

Limits and errors

An active plan, available WhatsApp template-send quota, a connected sender, and recipient messaging eligibility are required. Meta acceptance consumes one WhatsApp template send. A definite Meta rejection releases the reserved send. An uncertain provider outcome remains reserved while the API resolves its status webhook. Retry uncertain requests with the same idempotency key.