QuerySmsTemplateList
Queries all templates under your account to help you view template details, including the review status, templatetype, and template content.
Operation description
This operation queries the details of all templates under your current account. If you need to query more information such as the template variable content and the file materials uploaded during the application, you can call the GetSmsTemplate operation to query the review details of a single template by template code.
You can also log on to the Template Management page in the Short Message Service (SMS) console to view the details of all templates under your current account.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
dysms:QuerySmsTemplateList |
get |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| PageIndex |
integer |
No |
The current page number. Default value: 1. |
1 |
| PageSize |
integer |
No |
The number of templates to return on each page. Valid values: 1 to 50. Default value: 10. |
10 |
| SkuCode |
string |
No |
The specification code of Short Message Service (SMS), which is used to filter templates. |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| RequestId |
string |
The ID of the request. It is a unique identifier generated by Alibaba Cloud for the request and can be used to troubleshoot and locate issues. |
819BE656-D2E0-4858-8B21-B2E47708**** |
| Code |
string |
The status code of the request.
|
OK |
| Message |
string |
The description of the status code. |
OK |
| SmsTemplateList |
array<object> |
The list of results. |
|
|
array<object> |
The details of a single template. |
||
| TemplateCode |
string |
The code of the SMS template. |
SMS_1525*** |
| TemplateName |
string |
The name of the SMS template. |
Verification code template |
| OuterTemplateType |
integer |
The templatetype for external use. Valid values:
|
0 |
| AuditStatus |
string |
The review status of the template. Valid values:
|
AUDIT_STATE_PASS |
| TemplateContent |
string |
The content of the template. |
Your verification code is ${code}. You are registering as a platform member. Thank you for your support! |
| CreateDate |
string |
The time when the template was created. The time is in the yyyy-MM-dd HH:mm:ss format. |
2020-06-04 11:42:17 |
| Reason |
object |
The review result. |
|
| RejectDate |
string |
The time when the template was rejected. The time is in the yyyy-MM-dd HH:mm:ss format. |
2020-06-04 16:01:17 |
| RejectInfo |
string |
The reason for rejection. |
Variables do not meet specifications |
| RejectSubInfo |
string |
The detailed description of the rejection reason. |
Variable attribute selection fault. Select an appropriate variable attribute based on your business Scenarios. |
| OrderId |
string |
The ticket ID. This parameter is used by reviewers when querying the review. You must provide this ticket ID when requesting an expedited review. |
2004983**** |
| TemplateType |
integer |
The templatetype. Valid values:
|
2 |
| SignatureName |
string |
The name of the associated signature. |
Alibaba Cloud |
| TrafficDriving |
string |
The JSON string of the traffic redirection information list. Important The value must be in JSON format. Convert it to a string before passing it. 1. Field description:{ "trafficDrivingType":"Traffic redirection type", "trafficDrivingContent":"Traffic redirection content", "variableName":"Variable name", "companyName":Enterprise or institution name, "organizationCode":Unified social credit code, "icpNo":ICP filing number or license number, "icpPicOssKey":OSS key of the ICP filing screenshot, "companyDifferentFromSignQuaReason":Reason why the enterprise or institution name is different from the signature qualification } 2. Precautions:
3. Enum values for trafficDrivingType:
|
[{"trafficDrivingType":"DOMAIN","trafficDrivingContent":"aliyun.com","companyName":"Alibaba Cloud Computing Co., Ltd.","organizationCode":"91330****73959654P","icpNo":"浙B2-20****01-4","icpPicOssKey":"db7784d8-cb0c-498f-****-295f1ad6d665_mf29l7nf.png","companyDifferentFromSignQuaReason":"This is a description text"},{"trafficDrivingType":"1_PHONE","trafficDrivingContent":"1**86","variableName":"my1Phone","companyName":"Alibaba Cloud Computing Co., Ltd.","organizationCode":"91330****73959654P","companyDifferentFromSignQuaReason":"This is a description text"}] |
| SaleSkuCode |
string |
The specification code of Short Message Service (SMS). |
|
| SkuName |
string |
The specification name of Short Message Service (SMS). |
Verification code - Standard |
| TotalCount |
integer |
The total number of templates queried in this request. |
100 |
| CurrentPage |
integer |
The current page number. Default value: 1. |
1 |
| PageSize |
integer |
The number of templates to return on each page. Valid values: 1 to 50. |
10 |
Examples
Success response
JSON format
{
"RequestId": "819BE656-D2E0-4858-8B21-B2E47708****",
"Code": "OK",
"Message": "OK",
"SmsTemplateList": [
{
"TemplateCode": "SMS_1525***",
"TemplateName": "Verification code template",
"OuterTemplateType": 0,
"AuditStatus": "AUDIT_STATE_PASS",
"TemplateContent": "Your verification code is ${code}. You are registering as a member. Thank you for your support!",
"CreateDate": "2020-06-04 11:42:17",
"Reason": {
"RejectDate": "2020-06-04 16:01:17",
"RejectInfo": "The variable does not comply with the specifications",
"RejectSubInfo": "The variable attribute selection is a fault.\nSelect a variable attribute that is suitable for your business scenarios."
},
"OrderId": "2004983****",
"TemplateType": 2,
"SignatureName": "阿里云",
"TrafficDriving": "[{\"trafficDrivingType\":\"DOMAIN\",\"trafficDrivingContent\":\"aliyun.com\",\"companyName\":\"Alibaba Cloud Computing Co., Ltd.\",\"organizationCode\":\"91330****73959654P\",\"icpNo\":\"ZheB2-20****01-4\",\"icpPicOssKey\":\"db7784d8-cb0c-498f-****-295f1ad6d665_mf29l7nf.png\",\"companyDifferentFromSignQuaReason\":\"This is a description\"},{\"trafficDrivingType\":\"1_PHONE\",\"trafficDrivingContent\":\"1**86\",\"variableName\":\"my1Phone\",\"companyName\":\"Alibaba Cloud Computing Co., Ltd.\",\"organizationCode\":\"91330****73959654P\",\"companyDifferentFromSignQuaReason\":\"This is a description\"}]",
"SaleSkuCode": "",
"SkuName": "验证码-标准"
}
],
"TotalCount": 100,
"CurrentPage": 1,
"PageSize": 10
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.