Configure an HTTP callback URL to receive review status notifications for message templates.
Protocol specification
|
Item |
Description |
|
Protocol |
HTTP + JSON |
|
Encoding method |
UTF-8 |
Prerequisites
-
You have an Alibaba Cloud account and an AccessKey pair. For more information, see Create an AccessKey.
-
You have reviewed the overview and configuration of message receipts and understand their modes, types, and configuration process. Then, configure the message receipts accordingly.
Request
Multiple review reports may be pushed at a time.
Sample request
[
{
"WabaId": "9099999990****",
"TemplateCode": "744c4b5c79c9432497a075bdfca3****",
"Language": "en_US",
"AuditStatus": "unaudit",
"Reason": ""
},
{
"WabaId": "9099999990****",
"TemplateCode": "744c4b5c79c9432497a075bdfca*****",
"Language": "en_US",
"AuditStatus": "unaudit",
"Reason": ""
}
]
Request parameters
V1
Parameter | Type | Required | Description |
WabaId | String | Yes | The WhatsApp Business Account (WABA) ID. Note After you create a WABA, obtain the WABA ID on the Business Manager platform. |
TemplateCode | String | Yes | The template code. Note Obtain the template code on the Template Design page in the Chat App Message Service console or by calling the ListChatappTemplate operation. |
Language | String | Yes | The template language. |
AuditStatus | String | Yes | The review status of the message template. Valid values:
|
Reason | String | No | The reason for the review failure. Note A value is returned when the return value of AuditStatus is fail. |
V2
Use V2 when the independent software vendor (ISV) manages the WhatsApp Business accounts (WABAs) and phone numbers of their customers.
Parameter | Type | Required | Description |
WabaId | String | Yes | The WABA ID. Note After you create a WABA, obtain the WABA ID on the Business Manager platform. |
TemplateCode | String | Yes | The template code. Note Obtain the template code on the Template Design page in the Chat App Message Service console or by calling the ListChatappTemplate operation. |
Language | String | Yes | The template language. |
AuditStatus | String | Yes | The review status of the message template. Valid values:
|
Reason | String | No | The reason for the review failure. Note A value is returned when the return value of AuditStatus is fail. |
Type | String | Yes | The type of the notification. Valid values:
Note If the return value of Type is template, the parameters in the review report of V2 are the same as those in the review report of V1. |
PhoneNumber | String | No | The phone number. Note
|
Status | String | No | The status. Note
|
CurrentLimit | String | No | The maximum number of messages that the phone number can send in a day. Note
|
Response
Your endpoint must return an HTTP 200 status code within 3 seconds. The response body must be a JSON object in the following format. Otherwise, the system treats the push as failed and retries.
Sample response
{
"code" : 0,
"msg" : "Successful"
}
Response parameters
|
Parameter |
Type |
Required |
Description |
|
code |
Number |
Yes |
The response code. |
|
msg |
String |
No |
The description of the response code. |
Retries
If an initial push attempt fails, the service retries the request after 1 minute and again after 5 minutes. An attempt fails if your endpoint returns a non-200 HTTP status code or if the request times out. After three failed attempts, the service stops retrying.