Pushes a message to a specified consumer.

Usage notes

This operation is used to verify the message consumption status. This operation obtains the message body based on the input MsgId parameter, re-encapsulates the message body, and then pushes the message body to the consumer. The resent message has the same content as the original message. However, the two messages are not the same. The values of the MsgId parameter for the two messages are different.

QPS limit

The queries-per-second (QPS) limit on this operation is 10 per user. Throttling is triggered when the number of calls to this operation exceeds this limit. Throttling may affect your business. Therefore, call this operation based on your needs. For more information, see QPS limits.

Authorization information

By default, only Alibaba Cloud accounts can call this operation. Resource Access Management (RAM) users can call this operation only after they are authorized. The following table lists the authorization information of this operation. For more information, see Policies and examples.



Resource with a namespace

Resource without a namespace






OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes OnsMessagePush

The operation that you want to perform. Set the value to OnsMessagePush.

GroupId String Yes GID_test_group_id

The group ID of the consumer to which you want to push a message. For more information, see Terms.

ClientId String Yes 30.5.121.**@24813#-1999745829#-1737591554#453111174894656

The ID of the consumer instance. You can call the OnsConsumerGetConnection operation to query the ID.

MsgId String Yes 0BC1669963053CF68F733BB70396****

The ID of the message.

Topic String Yes test-mq_topic

The topic to which the message is pushed.

InstanceId String Yes MQ_INST_111111111111_DOxxxxxx

The ID of the instance where the message to be pushed is located.

Response parameters

Parameter Type Example Description
RequestId String B8EDC90D-F726-4B9E-8BEF-F0DD25EC****

The ID of the request. This parameter is a common parameter. Each request has a unique ID, which facilitates troubleshooting and problem locating.


Sample requests

&Common request parameters

Sample success responses

XML format

HTTP/1.1 200 OK


JSON format

HTTP/1.1 200 OK

  "RequestId" : "B8EDC90D-F726-4B9E-8BEF-F0DD25EC****"

Error codes

For a list of error codes, visit the API Error Center.