ListEventRules
Queries the list of event notifications.
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 cloud service for event notifications. Currently, only OSS is supported. |
oss |
| ResourceName |
string |
No |
The resource name in the matching rule, which is used to filter rules. For example, in OSS, this is the OSS bucket name. |
test-bucket |
| RuleName |
string |
No |
The filter condition for the rule name. Exact matching is performed based on the rule name. |
rule-xsXDW |
| TopicName |
string |
No |
The name of the topic. The name must be 1 to 255 characters in length. It must start with a letter or a digit, and can contain only letters, digits, and hyphens (-). The name cannot start with mns-reserved-. |
test-topic |
| Subscription |
object |
No |
The subscription endpoint. |
|
| EndpointType |
string |
No |
The endpoint type. Valid values:
|
topic |
| EndpointValue |
string |
No |
The actual value of the receiving endpoint. When EndpointType is set to topic, this parameter specifies the topic name. When EndpointType is set to queue, this parameter specifies the queue name. |
test-topic |
| PageNum |
integer |
No |
The page number of the returned results. Valid values: 1 to 100000. If the specified value is less than 1, the system defaults to 1. If the specified value is greater than 100000, the system defaults to 100000. |
1 |
| PageSize |
integer |
No |
The number of entries per page. Valid values: 10 to 50. If the specified value is less than 10, the system defaults to 10. If the specified value is greater than 50, the system defaults to 50. |
20 |
| NextToken |
string |
No |
[Deprecated] Use PageNum for paging. |
cd7NlPlX4kgKCdsCWMiMR/+HnVzPLQ4/XLvjR64jZ7F9AQ+Mr3T59J6IVkuXeV3w |
| MaxResults |
integer |
No |
[Deprecated] Use PageSize for paging. |
50 |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| RequestId |
string |
The ID of the request. |
06273500-249F-5863-121D-74D51123E62C |
| Code |
integer |
The response code. |
200 |
| Status |
string |
The response status. |
Success |
| Message |
string |
The response message. |
operation success |
| Success |
boolean |
Indicates whether the request is successful. |
true |
| Data |
object |
The response data. |
|
| PageNum |
integer |
The page number of the returned results. |
1 |
| PageSize |
integer |
The number of entries per page. |
50 |
| Size |
integer |
The number of results on the current page. |
20 |
| Pages |
integer |
The total number of pages. |
3 |
| Total |
integer |
The total number of results. |
130 |
| NextToken |
string |
[Deprecated] Use PageNum for paging. |
a88f58d504b8b4c4e0b5e8707e68181f |
| MaxResults |
integer |
[Deprecated] Refer to Total for the maximum number of results in paged queries. |
1 |
| PageData |
array<object> |
The data items. |
|
|
array<object> |
The data item. |
||
| RuleName |
string |
The name of the event notification rule. |
rule-xsXDW |
| Subscriptions |
array<object> |
The subscription endpoints. A maximum of 20 entries are returned. If the number of entries exceeds 20, use Subscription list to query. |
|
|
object |
|||
| EndpointType |
string |
The endpoint type. |
queue |
| EndpointValue |
string |
The actual value of the receiving endpoint. |
wyx-vp-complete-queue |
| TopicName |
string |
The name of the topic. |
demo-topic |
| MatchRules |
array |
The event matching rules. The rules are evaluated with an OR relationship. |
|
|
array |
The event matching rules. The rules are evaluated with 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 address of the subscription. |
|
| EndpointType |
string |
The endpoint type. Valid values:
|
topic |
| EndpointValue |
string |
The actual value of the receiving endpoint. |
test-topic |
| DeliveryMode |
string |
[Deprecated] This field 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.