All Products
Search
Document Center

Chat App Message Service:SendChatappMassMessage

Last Updated:Dec 18, 2025

Sends messages in bulk.

Operation description

QPS limits

  • This API is limited to 10 queries per second (QPS) for each user. If you exceed this limit, API calls are throttled, which can affect your business. Call this API within the specified limit.

  • A single request supports a maximum of 1,000 numbers.

Status changes

Message sending status can be monitored via Simple Message Service or HTTP callback. For details, see Configure message receipts.

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

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

cams:SendChatappMassMessage

create

*All Resource

*

None

None

Request parameters

Parameter

Type

Required

Description

Example

ChannelType

string

Yes

The channel type. Valid values:

  • whatsapp

  • messenger

  • instagram

  • viber

whatsapp

TemplateCode

string

No

The template code. View the template code on the Channel Management > Manage > Template Design page.

1119***************

Language

string

Yes

The language. For language codes, see Language codes.

en

From

string

Yes

The sender's number.

  • If ChannelType is whatsapp, this is the phone number registered and bound with WhatsApp. View the number on the Channel Management > Manage > WABA Management > Phone Number Management page.

  • If ChannelType is messenger, this is the Page ID. View the ID on the Channel Management > Manage > Facebook Homepage page.

  • If ChannelType is instagram, this is the Instagram professional account ID. View the ID on the Channel Management > Manage > Professional Account page.

  • If ChannelType is viber, this is the Viber service ID. View the ID on the Channel Management > Manage > Service Number Management page.

861387777****

CustWabaIddeprecated

string

No

The WhatsApp Business Account (WABA) ID of the Independent Software Vendor (ISV) customer. This is a deprecated parameter. Use CustSpaceId instead, which is the direct customer's instance ID. View the ID on the Channel Management page.

cams-8c8*********

FallBackId

string

No

The fallback policy ID. This parameter is for the international site (alibabacloud.com). You can ignore it for the China site (aliyun.com). View the policy ID on the Fallback Policy page.

S0****

FallBackContent

string

No

The custom fallback content. This parameter is for the international site (alibabacloud.com). You can ignore it for the China site (aliyun.com).

Fallback SMS

TaskId

string

No

The custom task ID.

10000****

SenderList

array<object>

No

A list of recipients.

array<object>

No

The phone number of the recipient.

TemplateParams

object

No

The collection of template parameters.

string

No

Template parameter as a Key-Value pair. The Key is the parameter name, and the Value is the parameter's value.

{ "param1": "value1", "param2": "value2" }

FlowAction

object

No

The Flow message object.

FlowActionData

object

No

A collection of default flow parameters.

any

No

Default flow parameter as a Key-Value pair. The Key is the parameter name, and the Value is the parameter's value.

{ "name": "name" }

FlowToken

string

No

The custom flow token information.

kde****

Payload

array

No

The list of payloads for the buttons.

string

No

The payload for a button.

payloadtext

To

string

No

The recipient's number.

  • If ChannelType is whatsapp, this is the recipient's phone number.

  • If ChannelType is messenger, this is a Page-Scoped User ID generated when a user interacts with a Facebook page.

  • If ChannelType is instagram, this is an Instagram User ID generated when a user interacts with an Instagram business or creator account.

  • If ChannelType is viber, this is the recipient's phone number.

861386666****

ProductAction

object

No

Product information. This parameter is only for WhatsApp channels and refers to product information uploaded to Meta.

ThumbnailProductRetailerId

string

No

The product catalog ID. Get it by calling the ListProductCatalog API.

skkks99****

Sections

array

No

The list of product categories. You can have up to 10 categories and 30 products.

array<object>

No

The product category.

Title

string

No

The category name. View it on the Channel Management > Manage > Catalog Management > Product Management page or get it by calling the ListProduct API.

abcd

ProductItems

array

No

The list of product information.

object

No

The product information.

ProductRetailerId

string

No

The product ID. View it on the Channel Management > Manage > Catalog Management > Product Management page or get it by calling the ListProduct API.

ksi3****

IsvCodedeprecated

string

No

ISV verification code, used to verify if the user is authorized by an ISV. This parameter is deprecated.

skdi3kksloslikd****

CustSpaceId

string

No

The Space ID of the ISV sub-customer, or the instance ID for a direct customer. View it on the Channel Management page.

cams-8c8*********

Ttl

integer

No

The timeout period for sending a Viber message. This parameter is for the international site (alibabacloud.com). You can ignore it for the China site (aliyun.com). Unit: seconds. Valid values: 30 to 1209600.

46

Label

string

No

The Viber message type. This parameter is for the international site (alibabacloud.com). You can ignore it for the China site (aliyun.com). Valid values:

  • promotion: marketing messages.

  • transaction: notification messages.

promotion

Tag

string

No

A custom tag for a Viber message.

Tag

FallBackDuration

integer

No

The time to trigger a fallback. This parameter is for the international site (alibabacloud.com). You can ignore it for the China site (aliyun.com). If a delivery receipt is not returned within the specified time, a fallback is triggered. If you leave this parameter empty, the fallback is not determined by time. A fallback is triggered only when the message fails to be sent or a failed status report is received. Unit: seconds. Minimum value: 60. Maximum value: 43200.

120

FallBackRule

string

No

The fallback rule. This parameter is for the international site (alibabacloud.com). You can ignore it for the China site (aliyun.com). Valid values:

  • undelivered: A fallback is triggered if the message cannot be delivered to the recipient. This rule requires that the template and parameters pass verification before sending. The rule does not apply if the message is blocked from sending, for example, due to a blacklisted template or phone number. This is the default rule if this parameter is empty.

  • sentFailed: A fallback is triggered if the template, template variables, or other parameters fail verification. Only the channelType, type, messageType, to, and the existence of the from parameter are strictly verified.

undelivered

TemplateName

string

No

The template name. View the template name on the Channel Management > Manage > Template Design page.

test_name

Response elements

Element

Type

Description

Example

object

The returned data.

AccessDeniedDetail

string

The details of the access denial.

None

RequestId

string

The request ID.

90E63D28-E31D-1EB2-8939-A9486641****

Message

string

The error message.

User not authorized to operate on the specified resource.

GroupMessageId

string

The bulk message ID.

890000010002****

Code

string

The request status code.

  • A value of OK indicates that the request was successful.

  • For other error codes, see Error codes.

OK

Examples

Success response

JSON format

{
  "AccessDeniedDetail": "None",
  "RequestId": "90E63D28-E31D-1EB2-8939-A9486641****",
  "Message": "User not authorized to operate on the specified resource.",
  "GroupMessageId": "890000010002****",
  "Code": "OK"
}

Error codes

HTTP status code

Error code

Error message

Description

400

Product.Unsubscript

You have not subscribed to the specified product.

You have not subscribed to the specified product.

400

Ram.PermissionDeny

You are not authorized to perform the operation.

400

System.LimitControl

The system is under flow control.

The system is under flow control.

400

Unknown.ResourceOwnerId

The resource does not belong to the current user.

The resource does not belong to the current user.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.