Skip to main content
POST
whatsapp.template.create

Authorizations

Authorization
string
header
required

API key: sk_live_…

Headers

Idempotency-Key
string
required

Required: this capability has an external effect.

Maximum string length: 255
Pramaan-Max-Price-Micro
string

Optional. The most this request may be priced at, in micro-USD (a whole number above 0). It replaces the capability's own price ceiling for this request, lower or higher. Sources that could cost more are left out; when none is left the answer is 400 with the lowest limit that would work.

Pattern: ^[1-9]\d{0,14}$

Body

application/json
name
string
required

Template name, using lowercase letters, digits and underscores.

Required string length: 1 - 512
Pattern: ^[a-z0-9_]+$
language
string
required

Language code, such as en_US.

Required string length: 1 - 16
Pattern: ^[a-z]{2,3}(_[A-Za-z]{2,4})?$
category
enum<string>
required

What the template is for.

Available options:
marketing,
utility,
authentication
body
string
required

Template body, up to 1024 characters.

Required string length: 1 - 1024
example
string
required

Body example with variables filled in.

Required string length: 1 - 2048
accountId
string

The sending account, from social.accounts.list. Optional when only one is connected.

Required string length: 1 - 256
type
enum<string>
default:text

Template layout. Some layouts require additional media or catalog support.

Available options:
text,
image,
video,
document,
location,
catalog,
product,
carousel,
limited_offer,
gif
purpose
string

What this template is used for.

Required string length: 1 - 180
header
string

Text header.

Required string length: 1 - 60

Footer.

Required string length: 1 - 60
buttons
object[]

Template buttons. Contact requests must be the only button.

Maximum array length: 10

A template button.

headerExample
string

Example header with variables filled in.

Required string length: 1 - 60
parameterFormat
enum<string>

Variable marker style.

Available options:
positional,
named
securityRecommendation
boolean

Add a security reminder to an authentication template.

codeExpirationMinutes
integer

Code expiry, from 1 to 90 minutes.

Required range: 1 <= x <= 90
messageValiditySeconds
integer

Time to attempt delivery, in seconds; category limits apply.

Required range: 30 <= x <= 2592000
sampleFileId
string

Id of an uploaded file holding template sample media, in place of a public link.

Pattern: ^file_[0-9A-HJKMNP-TV-Z]{26}$
offer
object

Limited-time offer settings.

cards
object[]

Two to ten carousel cards, with up to 5 MB of samples in total.

Required array length: 2 - 10 elements

Response

The result

status
enum<string>
required

Template approval state.

Available options:
approved,
pending,
rejected,
paused,
disabled
ref
string

Reference to what this call created. Pass it as ref to whatsapp.template.get, whatsapp.template.update or whatsapp.template.delete.