Queries a list of event notification rules.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
mns:ListEventRules |
list |
*Topic
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| ProductName |
string |
No |
The name of the Alibaba Cloud service for which event notifications are configured. |
oss |
| ResourceName |
string |
No |
The resource name in the matching rule. This parameter is used to filter rules. For example, for Object Storage Service (OSS), this is the bucket name. |
test-bucket |
| RuleName |
string |
No |
The name of the rule. |
rule-xsXDW |
| TopicName |
string |
No |
The name of the topic. |
test-topic |
| Subscription |
object |
No |
The subscriber. |
|
| EndpointType |
string |
No |
The endpoint type. Valid values:
|
topic |
| EndpointValue |
string |
No |
The actual value of the endpoint. |
test-topic |
| PageNum |
integer |
No |
The page number of the results to return. Valid values: 1 to 100000. If you set this parameter to a value less than 1, the system uses 1. If you set this parameter to a value greater than 100000, the system uses 100000. |
1 |
| PageSize |
integer |
No |
The number of entries to return on each page. Valid values: 10 to 50. If you set this parameter to a value less than 10, the system uses 10. If you set this parameter to a value greater than 50, the system uses 50. |
20 |
| NextToken |
string |
No |
This parameter is deprecated. Use PageNum for paged queries. |
cd7NlPlX4kgKCdsCWMiMR/+HnVzPLQ4/XLvjR64jZ7F9AQ+Mr3T59J6IVkuXeV3w |
| MaxResults |
integer |
No |
This parameter is deprecated. Use PageSize for paged queries. |
50 |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| RequestId |
string |
The request ID. |
06273500-249F-5863-121D-74D51123E62C |
| Code |
integer |
The response code. |
200 |
| Status |
string |
The status of the response. |
Success |
| Message |
string |
The response message. |
operation success |
| Success |
boolean |
Indicates whether the request was successful. |
true |
| Data |
object |
The response data. |
|
| PageNum |
integer |
The page number of the returned results. |
1 |
| PageSize |
integer |
The number of entries returned per page. |
50 |
| Size |
integer |
The number of entries on the current page. |
20 |
| Pages |
integer |
The total number of pages. |
3 |
| Total |
integer |
The total number of entries. |
130 |
| NextToken |
string |
This parameter is deprecated. Paged queries are based on PageNum. |
a88f58d504b8b4c4e0b5e8707e68181f |
| MaxResults |
integer |
This parameter is deprecated. The maximum number of entries is based on Total. |
1 |
| PageData |
array<object> |
The data entries. |
|
|
array<object> |
The data entries. |
||
| RuleName |
string |
The name of the event notification rule. |
rule-xsXDW |
| Subscriptions |
array<object> |
The subscribers. A maximum of 20 entries are returned. If there are more subscribers, see List Subscriptions. |
|
|
object |
|||
| EndpointType |
string |
The endpoint type. |
queue |
| EndpointValue |
string |
The actual value of the endpoint. |
wyx-vp-complete-queue |
| TopicName |
string |
The name of the topic. |
demo-topic |
| MatchRules |
array |
The event matching rules. The rules have an OR relationship. |
|
|
array |
The event matching rules. The rules have an OR relationship. |
||
| EventMatchRule |
The matching rules. Multiple rules have an OR relationship. |
[[{\"MatchState\":true,\"Prefix\":\"cdhxdev1cdh-bba-dto-052901-sem-5seh/\",\"Suffix\":\"\"}]] |
|
| EventTypes |
array |
The list of event types. |
|
|
string |
The list of event types. |
["oss:ObjectCreated:CopyObject"] |
|
| Endpoint |
object |
The endpoint of the subscription. |
|
| EndpointType |
string |
The endpoint type. Valid values:
|
topic |
| EndpointValue |
string |
The actual value of the endpoint. |
test-topic |
| DeliveryMode |
string |
This parameter is deprecated. |
-- |
Examples
Success response
JSON format
{
"RequestId": "06273500-249F-5863-121D-74D51123E62C",
"Code": 200,
"Status": "Success",
"Message": "operation success",
"Success": true,
"Data": {
"PageNum": 1,
"PageSize": 50,
"Size": 20,
"Pages": 3,
"Total": 130,
"NextToken": "a88f58d504b8b4c4e0b5e8707e68181f",
"MaxResults": 1,
"PageData": [
{
"RuleName": "rule-xsXDW",
"Subscriptions": [
{
"EndpointType": "queue",
"EndpointValue": "wyx-vp-complete-queue"
}
],
"TopicName": "demo-topic",
"MatchRules": [
[
{
"MatchState": true,
"Name": "testBucket/folder1/file1",
"Prefix": "testBucket/prefix1xxx",
"Suffix": "suffix/xxxx.test"
}
]
],
"EventTypes": [
"[\"oss:ObjectCreated:CopyObject\"]"
],
"Endpoint": {
"EndpointType": "topic",
"EndpointValue": "test-topic"
},
"DeliveryMode": "--"
}
]
}
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.