Create WhatsApp Template
Create a WhatsApp template. Created template will be submitted for WhatsApp's review and approval. Once approved, template can be sent to end-users. Refer to template guidelines for additional info.
Authorizations:
Scopes:
Request rate limit:
path Parameters
sender required | string Example: 447796344125 Registered WhatsApp sender number. Must be in international format. |
Request Body schema:
application/jsonname required | string Template name. Must only contain lowercase alphanumeric characters and underscores. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
language required | string Enum: "af" "sq" "ar" "az" "bn" "bg" "ca" "zh_CN" "zh_HK" "zh_TW" "hr" "cs" "da" "nl" "en" "en_GB" "en_US" "et" "fil" "fi" "fr" "ka" "de" "el" "gu" "ha" "he" "hi" "hu" "id" "ga" "it" "ja" "kn" "kk" "rw_RW" "ko" "ky_KG" "lo" "lv" "lt" "mk" "ms" "ml" "mr" "nb" "fa" "pl" "pt_BR" "pt_PT" "pa" "ro" "ru" "sr" "sk" "sl" "es" "es_AR" "es_ES" "es_MX" "sw" "sv" "ta" "te" "th" "tr" "uk" "ur" "uz" "vi" "zu" "unknown" Template language, one template with same name can have multiple transliterations. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
category required | string Category of the template. Mind that each category has different fields available for the endpoint. If you're sending traffic in India, for MARKETING | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
allowCategoryChange | boolean Default: false If set to true, Meta will be able to assign category based on their template guidelines. If omitted, template will not be auto-assigned a category and may get rejected if determined to be miscategorized. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
structure required | object Structure of the created template. Can consist of body (mandatory), header, footer, buttons, carousel, limited time offer and shortening options. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
platform | object Platform options. For more details, see documentation. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Responses
Template created.
Bad Request
Unauthorized
Forbidden
Not Found.
Too Many Requests
Internal Server Error
Request samples
- Payload
- cURL
- Java
- C#
- Go
- Python
- PHP
- JavaScript
- NodeJs
- Ruby
{- "name": "text_template",
- "language": "en",
- "category": "MARKETING",
- "allowCategoryChange": false,
- "structure": {
- "body": {
- "text": "body {{1}} content",
- "examples": [
- "example"
]
}, - "type": "TEXT"
}
}
Response samples
- 201
- 400
- 401
- 403
- 404
- 429
- 500
{- "id": "111",
- "businessAccountId": 222,
- "name": "media_template",
- "language": "en",
- "status": "APPROVED",
- "category": "MARKETING",
- "structure": {
- "header": {
- "format": "IMAGE"
}, - "body": {
- "text": "example {{1}} body"
}, - "footer": {
- "text": "exampleFooter"
}, - "type": "MEDIA"
}, - "quality": "HIGH",
- "platform": {
- "entityId": "entityId",
- "applicationId": "applicationId"
}, - "createdAt": "2024-01-01T00:00:00.000+0000",
- "lastUpdatedAt": "2024-01-01T00:00:00.000+0000"
}
Need assistance
Encountering issues
What's new? Check out
Unsure about a term? See