All Products
Search
Document Center

Direct Mail:ModifyTemplate

Last Updated:Jun 26, 2026

Modifies an email template.

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

TemplateId

integer

Yes

The template ID.

409481

TemplateName

string

Yes

The template name. Maximum length: 30 characters.

verification code

TemplateSubject

string

No

The subject of the email template. This parameter is required only when the templatetype is email. Maximum length: 256 characters.

REAL'EN OPEN TONNAGE

TemplateNickName

string

No

The nickname of the template or the alias of the sender. This parameter is required only when the templatetype is email. Maximum length: 30 characters.

Lisa Gao

TemplateText

string

No

The body content of the email. This parameter is required only when the templatetype is email. Maximum size: 1 MB.

hello {name}

SmsType

integer

No

The business type of the SMS template. This parameter is required only when the templatetype is SMS.

Valid values:

  • 0 :

    Verification code.

  • 2 :

    Notification or promotion.

0

SmsContent

string

No

The body content of the SMS template. This parameter is required only when the templatetype is SMS. Length: 2 to 400 characters.

hello {name}

Remark

string

No

The remarks or application description for the SMS template. This parameter is required only when the templatetype is SMS. Maximum length: 100 characters.

for verification

FromType

integer

No

The source channel through which the user connects. Default value: 1.

Valid values:

  • 1 :

    Direct access through Alibaba Cloud.

  • 2 :

    Access through a partner channel.

1

Response elements

Element

Type

Description

Example

object

RequestId

string

The unique request identifier.

C5AB05E9-D3CA-582E-9538-8C6C554040F6

Examples

Success response

JSON format

{
  "RequestId": "C5AB05E9-D3CA-582E-9538-8C6C554040F6"
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.