Modifies a message template. Only templates that are not reviewed or not approved can be modified.
Operation Description
QPS limit
You can call this operation up to five times per second per account. If the number of the calls per second exceeds the limit, throttling is triggered. As a result, your business may be affected. We recommend that you take note of the limit when you call this operation.
Authorization information
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
Components | array | Yes | The list of components of the message template. | |
object | No | The component of the message template. | ||
Type | string | Yes | The type of the component. Valid values:
| BODY |
Text | string | No | The text of the message that is sent. | hello chatapp |
Format | string | No | The type of the media resources that are included in the message.
| TEXT |
Url | string | No | The URL of the material. | https://img.tukuppt.com/png_preview/00/10/24/1GygxVK3F4.jpg |
Caption | string | No | The description. NoteWhen the Type parameter is set to HEADER and the Format parameter is set to IMAGE, DOCUMENT, or VIDEO, you can specify the description. | This is a video. |
FileName | string | No | The name of the file NoteWhen the Type parameter is set to HEADER and the Format parameter is set to DOCUMENT, you can specify a name of the file. | Video |
Buttons | array | No | The list of buttons, which applies only to the BUTTONS component. | |
object | No | The definition of the button. | ||
Type | string | Yes | The type of the button.
| PHONE_NUMBER |
Text | string | No | The text of the message that is sent. | phone-button-text |
PhoneNumber | string | No | The phone number. | +8613888887889 |
Url | string | No | The URL to be visited after users click the button. | https://www.website.com/ |
UrlType | string | No | The type of the URL. Valid values:
| dynamic |
Language | string | Yes | The language that is used in the message template. For more information, see Language codes. | en |
Example | object | No | The examples of variables that are used when you create the message template. | |
string | No | The examples of variables. This parameter is specified when the original JSON structure is converted into a string. | {"textVariable":"text"} | |
CustWabaId | string | No | The ID of the WhatsApp Business account (WABA) under the ISV account. | 659216218162179 |
IsvCode | string | No | The ISV verification code, which is used to verify whether the user is authorized by ISV. | ksiekdki39ksks93939 |
TemplateCode | string | Yes | The code of the message template. | 8472929283883 |
CustSpaceId | string | No | The space ID of the user under the ISV account. | 28251486512358**** |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "90E63D28-E31D-1EB2-8939-A9486641****",
"Code": "OK",
"Message": "None\n",
"Data": {
"TemplateCode": "8472929283883",
"TemplateName": "hello_whatsapp"
}
}
Error codes
HTTP status code | Error code | Error message |
---|---|---|
400 | Product.Unsubscript | You have not subscribed to the specified product. |
400 | Ram.PermissionDeny | You are not authorized to perform the operation. |
400 | System.LimitControl | The system is under flow control. |
400 | Unknown.ResourceOwnerId | The resource does not belong to the current user. |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
2023-03-02 | The error codes of the API operation change.,The input parameters of the API operation change. | |||||||||||
| ||||||||||||
2022-09-29 | Add Operation |