You can call this operation to configure the read/write mode for a topic.
By default, only Alibaba Cloud accounts can call this operation. Resource Access Management (RAM) users can call this operation only after being authorized.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | OnsTopicUpdate |
The operation that you want to perform. Set the value to OnsTopicUpdate. |
InstanceId | String | Yes | MQ_INST_111111111111_DOxxxxxx |
The ID of the Message Queue for Apache RocketMQ instance corresponding to the topic that you want to configure. |
Perm | Integer | Yes | 6 |
The read/write mode to be configured for the topic. Valid values:
|
Topic | String | Yes | test |
The name of the topic that you want to configure. The value must be unique under one account even in different regions. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
RequestId | String | 81979ADA-4A78-4F64-9DEC-5700446DF952 |
The ID of the request. This is a common parameter. |
Examples
Sample requests
http(s)://[Endpoint]/? Action=OnsTopicUpdate
&Perm=6
&Topic=test
&InstanceId=MQ_INST_111111111111_DOxxxxxx
&<Common request parameters>
Sample success responses
XML
format
<OnsTopicUpdateResponse>
<RequestId>81979ADA-4A78-4F64-9DEC-5700446DF952</RequestId>
</OnsTopicUpdateResponse>
JSON
format
{
"RequestId": "81979ADA-4A78-4F64-9DEC-5700446DF952"
}
Error codes
For a list of error codes, visit the API Error Center.