{ "data": [ { "id": 45, "name": "appointment_reminder", "language": "en", "category": "utility", "status": "approved", "body_text": "Hi {{1}}, this is a reminder for your appointment on {{2}} at {{3}}. Reply YES to confirm or NO to reschedule.", "variables": ["1", "2", "3"], "has_variables": true, "header_format": "TEXT", "header_text": "Appointment reminder", "footer_text": null, "buttons": [ { "type": "QUICK_REPLY", "text": "YES" }, { "type": "QUICK_REPLY", "text": "NO" } ] }, { "id": 46, "name": "welcome_message", "language": "en", "category": "marketing", "status": "approved", "body_text": "Welcome to Acme Corp! We're excited to have you. How can we help you today?", "variables": [], "has_variables": false, "header_format": null, "header_text": null, "footer_text": null, "buttons": [] } ]}
{ "success": false, "error": "Sender not found", "error_code": "SENDER_NOT_FOUND"}
This endpoint returns all message templates associated with a specific WhatsApp sender. Templates are required for initiating conversations or messaging users outside the 24-hour messaging window.
Path Parameters
integer
required
The ID of the WhatsApp sender (obtained from the Get Senders endpoint)
Query Parameters
string
Filter templates by approval status. Default: approved. Use all to return all templates regardless of status.
Response Fields
array
Show Template object properties
integer
The unique identifier of the template. Use this when sending template messages.
string
The template name as registered with Meta (e.g., order_confirmation, appointment_reminder)
string
The template language code (e.g., en, es, pt_BR)
string
The template category: marketing, utility, or authentication
string
The approval status: approved, pending, or rejected
string
The template body text, with variable placeholders shown as {{1}}, {{2}}, etc.
array
The variable numbers the template needs when sending, as strings ("1", "2", …). They cover the header, body, link buttons and coupon code. Empty array if the template has no variables.
boolean
Whether this template requires variables to be provided when sending
string | null
TEXT, IMAGE, VIDEO or DOCUMENT, or null if the template has no header. Image, video and document headers send the file attached to the template.
string | null
The header text for TEXT headers, with its variable shown as {{N}}.
string | null
The footer text, if the template has one.
array
The template’s buttons in order. Each has a type (QUICK_REPLY, URL, PHONE_NUMBER, COPY_CODE or VOICE_CALL) and, depending on the type, text, url, phone_number or code. A link or coupon code that contains {{N}} takes that variable’s value when sending.
Error Responses
Show Error Response
boolean
false
string
Sender not found
string
SENDER_NOT_FOUND
curl -X GET "https://app.autocalls.ai/api/user/whatsapp/senders/12/templates" \ -H "Authorization: Bearer YOUR_API_KEY"
curl -X GET "https://app.autocalls.ai/api/user/whatsapp/senders/12/templates?status=all" \ -H "Authorization: Bearer YOUR_API_KEY"