Create a WhatsApp template
Creates a WhatsApp template in one of your account’s WhatsApp Business Accounts, submits it for review, and returns the new template.
Every WhatsApp message you send uses a template, so new message content starts with a new template.
Behavior: Returns 201 with the new template. Poll whatsapp_templates_get for the review outcome. Returns 409 when the WhatsApp Business Account already has a template with the same name and language.
Requires: Your account must have WhatsApp and its templates capability enabled, must have a subscription plan, and must not be blocked or suspended. The WhatsApp Business Account must have a connected sender; when your account has more than one WhatsApp Business Account, specify waba_id or sender.
Authorizations
Wavix API key. Pass as Authorization: Bearer <api_key>. Keys support per-resource scopes (none / read / write). See Restricted keys and scopes.
Body
Attributes of the template to create.
Attributes of a new WhatsApp template. Consumed by whatsapp_templates_create.
Template name, made of lowercase letters, digits, and underscores, up to 512 characters.
"order_shipped"
Template language code, such as en or en_US.
"en_US"
Template category. Possible values:
marketing— Promotions, offers, and other marketing content.authentication— One-time passcodes for verifying a user.utility— Transactional updates about an order or an account.
marketing, authentication, utility "utility"
Structural components of the template. Each component type can appear once, exactly one body component is required, and type and format values must be lowercase.
1Text header of a new WhatsApp template. Requires text. Consumed by whatsapp_templates_create.
- WhatsAppTemplateTextHeaderComponentRequest
- WhatsAppTemplateMediaHeaderComponentRequest
- WhatsAppTemplateLocationHeaderComponentRequest
- WhatsAppTemplateBodyComponentRequest
- WhatsAppTemplateButtonsComponentRequest
ID of the WhatsApp Business Account that owns the template, as returned in waba.id by whatsapp_senders_list. Required when your account has more than one, unless sender is set. When both are set, sender must belong to this WhatsApp Business Account.
"102290129340398"
Phone number of a connected sender whose WhatsApp Business Account owns the template, as an alternative to waba_id. When both are set, the sender must belong to waba_id. The leading + is optional.
^\+?\d{6,20}$"14155550100"
Response
The created WhatsApp template.
Returned by whatsapp_templates_get and whatsapp_templates_create.
A WhatsApp message template with its review status and components. Returned by whatsapp_templates_list, whatsapp_templates_get, and whatsapp_templates_create.