All Products
Document Center


Last Updated: Sep 22, 2017


BatchSendMail is used for sending batch emails.

Request parameters

Name Type Required? Description
Action String Required Operation interface name, a system required parameter. Value: BatchSendMail.
AccountName String Required The sender address configured in the console.
AddressType Number Required Value range: 0-1. 0 indicates a random address, and 1 indicates the sender address.
TemplateName String Required The name of the template that is created and verified in advance .
ReceiversName String Required The name of the recipient list that is created in advance and uploaded with recipients.
TagName String Optional The mail tag name.
ClickTrace String Optional Value range: 0-1. 1 indicates enabling recipient tracking. 0 indicates that not enabling recipient tracking. The default value of this parameter is 0.

For other request parameters, see Public parameters.

Return parameters

For more information about public return parameters, see Public parameters.

Error codes

Error code Description HTTP status code Meaning
InvalidMailAddress.NotFound The specified mailAddress does not exist. 400 The sender address does not exist.
InvalidMailAddressStatus.Malformed The specified mailAddress status is wrongly formed. 400 The sender address status is incorrect.
InvalidMailAddressSendType.Malformed The specified mailAddress sendType is wrongly formed. 400 The sender address type is incorrect. Only the batch-type sender address is allowed.
InvalidReceiverName.Malformed The specified receiver name is wrongly formed. 400 The recipient list name is incorrect. The list does not exist or the list is empty.
InvalidSendMail.Spam Sendmail rejected by spam filter. 400 This mailing is detected as spam mailing by the anti-spam system and the email is forbidden from being sent. Check and optimize the email content.
InvalidTemplateName.Malformed The specified template name is wrongly formed. 400 The template name is incorrect.
InvalidMailAddressDomain.Malformed The specified mailAddress domain does not exist. 400 The domain status of the sender address is incorrect. Check the domain status, the ownership, MX and SPF configurations.


Request example

  2. &
  3. &AddressType=1
  4. &TemplateName=test1
  5. &ReceiversName=test2
  6. &TagName=test3
  7. &<Public request parameter>

Response example

XML format

  1. <BatchSendMailResponse>
  2. <RequestId>12D086F6-8F31-4658-84C1-006DED011A85</RequestId>
  3. </BatchSendMailResponse>

JSON example

  1. {
  2. "RequestId": "12D086F6-8F31-4658-84C1-006DED011A85"
  3. }