Appearance
Create template
Create a new message template. Supports two modes:
Custom template: Provide components with your own content. Submitted to Meta for review (can take up to 24h).
Library template: Provide library_template_name instead of components to use a pre-built template from Meta's template library. Library templates are pre-approved (no review wait). You can optionally customize parameters and buttons via library_template_body_inputs and library_template_button_inputs.
Browse available library templates at:
POST /v1/whatsapp/templates
Create a new message template. Supports two modes:
Custom template: Provide components with your own content. Submitted to Meta for review (can take up to 24h).
Library template: Provide library_template_name instead of components to use a pre-built template from Meta's template library. Library templates are pre-approved (no review wait). You can optionally customize parameters and buttons via library_template_body_inputs and library_template_button_inputs.
Browse available library templates at: https://business.facebook.com/wa/manage/message-templates/
Request body
Content-Type: application/json
accountId(string) required — WhatsApp social account IDname(string) required — Template name (lowercase, letters/numbers/underscores, must start with a letter)category(string) required (enum: AUTHENTICATION, MARKETING, UTILITY) — Template categorylanguage(string) required — Template language code (e.g., en_US)components(array) — Template components (header, body, footer, buttons). Required for custom templates, omit when using library_template_name.library_template_name(string) — Name of a pre-built template from Meta's template library (e.g., "appointment_reminder", "auto_pay_reminder_1", "address_update"). When provided, the template is pre-approved by Meta with no review wa...library_template_body_inputs(object) — Optional body customizations for library templates. Available options depend on the template (e.g., add_contact_number, add_learn_more_link, add_security_recommendation, add_track_package_link, code_e...library_template_button_inputs(array) — Optional button customizations for library templates. Each item specifies button type and configuration (e.g., URL, phone number, quick reply).
Responses
200 — Template created (pre-approved for library templates, pending review for custom)
success(boolean)template(object)
400 — Validation error (invalid name format
401
404 — WhatsApp account not found