Queries the authorization information about a topic.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
mq:QueryCustomAuthPermission |
get |
*Instance
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| InstanceId |
string |
Yes |
The ID of the ApsaraMQ for MQTT instance. |
post-cn-0pp12gl**** |
| IdentityType |
string |
No |
The identity type. |
USER |
| Identity |
string |
No |
The username or client ID. |
test |
| Topic |
string |
No |
The topic whose authorization information you want to query. Multi-level topics and wildcard characters are supported. |
test |
| NextToken |
string |
No |
The pagination token returned from the previous call. Set this parameter to an empty string for the first request or to retrieve all results. |
AAAAAThmKW2HkRgzo4G7IRRTK2fC6zZmAk6y0bwoNPFOOcSP |
| Size |
integer |
Yes |
The number of entries to return. Maximum value: 100. |
100 |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
The response schema. |
||
| RequestId |
string |
The request ID. |
63309FDB-ED6C-46AE-B31C-A172FBA0**** |
| Code |
integer |
The HTTP status code. |
200 |
| Success |
boolean |
Indicates whether the request was successful. |
True |
| Message |
string |
The returned message. |
operation success. |
| Data |
object |
The returned data. |
|
| Results |
array<object> |
The response results. |
|
|
object |
|||
| Identity |
string |
The username or client ID. |
test |
| PermitAction |
string |
The authorized permissions. |
PUB_SUB |
| Effect |
string |
Indicates whether to allow or deny access. |
ALLOW |
| IdentityType |
string |
The identity type. Valid values:
|
USER |
| Topic |
string |
The topic name. Multi-level topics and wildcard characters are supported. |
test |
| NextToken |
string |
The pagination token returned from the previous call. Set this parameter to an empty string for the first request or to retrieve all results. |
AAAAAV/vsqTyeMlX1MIk7/b6NrZLIlsSVf49O04ac7HAmlBoaYspakK7ZZkR3vRDp5Y9Nz0EmuWYrtF+1qkUwuJzPk/qEto/FGxl5Kd+qdwNt3t8 |
Examples
Success response
JSON format
{
"RequestId": "63309FDB-ED6C-46AE-B31C-A172FBA0****",
"Code": 200,
"Success": true,
"Message": "operation success.",
"Data": {
"Results": [
{
"Identity": "test",
"PermitAction": "PUB_SUB",
"Effect": "ALLOW",
"IdentityType": "USER",
"Topic": "test"
}
],
"NextToken": "AAAAAV/vsqTyeMlX1MIk7/b6NrZLIlsSVf49O04ac7HAmlBoaYspakK7ZZkR3vRDp5Y9Nz0EmuWYrtF+1qkUwuJzPk/qEto/FGxl5Kd+qdwNt3t8"
}
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | InstancePermissionCheckFailed | An error occurred while validating the permissions of the instance. Please verify the account that created the instance and its permissions settings. | |
| 400 | InvalidParameter.%s | An error occurred while validating the parameter. The parameter may be missing or invalid. | |
| 404 | ApiNotSupport | The specified API is not supported. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.