CreateDigitalSmsTemplate

更新时间:
复制 MD 格式

Creates a digital SMS template.

Operation description

Use this operation to create a reusable template for your digital SMS messages.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request parameters

Parameter

Type

Required

Description

Example

TemplateName

string

Yes

The template name. The name can contain up to 20 characters.

****模板

Remark

string

Yes

The application description. Describe your business use case for the template.

***业务需要

TemplateContents

array<object>

Yes

An array of objects that define the template content.

object

No

The template content.

FileContents

string

No

The file content, converted to a Base64 string. The file must be UTF-8 encoded before the Base64 conversion.

字符

FileSuffix

string

No

The file suffix. Supported formats are txt for text; gif, jpg, and png for images; mp3 for audio; and mp4 for video. You can upload only one video file per template.

txt

FileName

string

No

The file name without the extension.

file-1

FileSize

integer

No

The file size, in bytes.

1840901

SignName

string

No

The signature.

签名

Response elements

Element

Type

Description

Example

object

Code

string

The status code of the request. A value of OK indicates a successful request.

OK

Message

string

The response message. success indicates a successful request. If the request fails, an error message is returned.

success

RequestId

string

The request ID. This unique identifier is generated by Alibaba Cloud and can be used to troubleshoot issues.

F655A8D5-B967-440B-8683-DAD6FF8DE990

TemplateCode

string

The template code.

DIGITAL_SMS_0001

Examples

Success response

JSON format

{
  "Code": "OK",
  "Message": "success",
  "RequestId": "F655A8D5-B967-440B-8683-DAD6FF8DE990",
  "TemplateCode": "DIGITAL_SMS_0001"
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.