One template: status, rejection reason, what it needs
https://api.app2email.com/v1/{number}/templates/{name} Every language of the template. Not from a cache: a status that just changed shows. With every field Meta keeps (sub_category, previous_category, TTL, link tracking, library name).
Path
-
Your app2email WhatsApp number - the number the message is sent FROM. Full number with country code, digits only.
e.g.4976659348270 -
The template's name.
e.g.order_update
Responses
Fields
- success boolean
- request_id string
- name string
- versions object[]
One entry per language of the template.
18 item fields
- name string
- language string
- category stringe.g.
UTILITY - status string
APPROVED, PENDING, REJECTED, PAUSED, DISABLED ...
e.g.APPROVED - id string
WhatsApp's id of the template (in GET /templates/{name}).
- rejected_reason string
Why WhatsApp rejected it. Left out when there is none.
- quality_score string
WhatsApp's quality rating from the contacts' reactions. Left out when unknown. A RED template can be paused by WhatsApp.
GREENYELLOWRED - can_send boolean
Only APPROVED templates can be sent.
-
What values the template needs, in words.
- example_request object
A WhatsApp message in the format of WhatsApp Cloud API (Meta's exact body works unchanged): a template (type 'template', the default, any time), or within 24 hours of the contact's last message a free-form text, image, video, document, audio, sticker, location, contacts, reaction or interactive message. Meta's mark-read body {messaging_product, status: 'read', message_id, typing_indicator?} marks a message as read. Give 'to' or 'recipients' (templates only).
- sub_category string
- previous_category string
The category before Meta changed it.
- correct_category string
The category Meta says is right.
- parameter_format string
- message_send_ttl_seconds integer
- cta_url_link_tracking_opted_out boolean
- is_primary_device_delivery_only boolean
- library_template_name string
Set when the template came from the Template Library.
Errors
- 400 The request is malformed (missing or invalid fields, query parameters or times).
- 401 Missing, invalid, revoked or expired API key.
- 403 The key is valid but this call is not allowed: the key lacks the scope the call needs (insufficient_scope), the address is not allowed for the key (ip_not_allowed), the number or plan does not allow it, a recipient opted out or is not opted in, or a problem with the WhatsApp account.
- 404 The number, template, message, broadcast, webhook, delivery, opt-in, logged request, booking or Flow was not found.
- 429 A monthly plan limit, the number's own monthly cap, the key's daily cap, a WhatsApp rate limit, the API rate limit (rate_limited), or the webhook test limit (too_many_tests) was reached. Retry-After and error.retry_after_seconds say how long to wait.
- 500 Unexpected error on app2email's side.
- 502 WhatsApp (Meta) returned an error or could not be reached.