Sends a batch of emails.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
dm:BatchSendMail |
none |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| TemplateName |
string |
Yes |
The name of a pre-created and approved template. |
test1 |
| AccountName |
string |
Yes |
The sender address configured in the console. |
test@example.com |
| ReceiversName |
string |
Yes |
The name of a pre-created recipient list to which recipients have been uploaded. Note: The number of recipients in the list must not exceed your remaining daily quota. Otherwise, email sending fails. Do not delete the recipient list for at least 10 minutes after triggering the task. Otherwise, email sending may fail. |
test2 |
| AddressType |
integer |
Yes |
|
1 |
| TagName |
string |
No |
The name of the email tag. |
test3 |
| ReplyAddress |
string |
No |
The reply-to address. |
test2***@example.net |
| ReplyAddressAlias |
string |
No |
The alias for the reply-to address. |
小红 |
| ClickTrace |
string |
No |
|
0 |
| UnSubscribeLinkType |
string |
No |
The type of unsubscribe link to generate. For more information, see Unsubscribe link generation and filtering mechanism.
The language of the unsubscribe link matches the recipient's browser language setting. |
default |
| UnSubscribeFilterLevel |
string |
No |
The filtering level. For more information, see Unsubscribe link generation and filtering mechanism.
|
mailfrom_domain |
| Headers |
string |
No |
Message header settings. All fields, standard or non-standard, must follow standard header syntax. For API calls, the `headers` field supports up to 10 headers. Any headers beyond this limit are ignored. SMTP does not have a header limit. 1. Standard fields `Message-ID`, `List-Unsubscribe`, `List-Unsubscribe-Post` Standard fields overwrite existing values in the message header. 2. Non-standard fields Case-insensitive a. Start with `X-User-`. These fields are not pushed to EventBridge or Message Service. They are required only for API calls. SMTP supports any custom header. b. Start with `X-User-Notify-`. These fields are pushed to EventBridge and Message Service. They are supported by both API and SMTP. When pushed to EventBridge or Message Service, these fields appear under the `headers` object. |
{
"Message-ID": " |
| IpPoolId |
string |
No |
The ID of the dedicated IP address pool. If you purchased dedicated IP addresses, use this parameter to specify the egress IP address for sending the email. |
e4xxxxxe-4xx0-4xx3-8xxa-74cxxxxx1cef |
| DomainAuth |
boolean |
No |
Enables domain-level authentication.
Use this parameter only for domain-level authentication. Ignore it for sender address-level authentication. 1. The console creates the address `domain-auth-created-by-system@example.com`. Do not change the prefix before the at sign (@). Replace the domain suffix with your own domain. 2. API scenario Set `AccountName` to your domain. Recipients see `domain-auth-created-by-system@example.com` as the sender. SMTP scenario a. Use the `ModifyPWByDomain` API to set a password for your domain. b. Authenticate using your domain and the password. Set the actual sender address (`mailfrom`) to a custom address, such as `user@example.com`. Recipients see `user@example.com` as the sender. |
true |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| EnvId |
string |
The event ID. |
xxx |
| RequestId |
string |
The request ID. |
12D086F6-8F31-4658-84C1-006DED011A85 |
Examples
Success response
JSON format
{
"EnvId": "xxx",
"RequestId": "12D086F6-8F31-4658-84C1-006DED011A85"
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.