Queries the details of an event-triggered alert rule.
This topic provides an example on how to query the details of an event-triggered alert
rule named testRule
.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | DescribeEventRuleAttribute |
The operation that you want to perform. Set the value to DescribeEventRuleAttribute. |
RuleName | String | Yes | testRule |
The name of the event-triggered alert rule. For information about how to obtain the name of an event-triggered alert rule, see DescribeEventRuleList. |
SilenceTime | String | No | 86400 |
The mute period during which new alerts are not sent even if the trigger conditions are met. Unit: seconds. Default value: 86400. The default value indicates one day. Note Only one alert notification is sent during a mute period even if the metric value
exceeds the alert threshold during consecutive checks.
|
For more information about common request parameters, see Common parameters.
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
Result | Struct |
The details of the event-triggered alert rule. |
|
Description | String | Default group event rule. |
The description of the event-triggered alert rule. |
EventPattern | Struct |
The event pattern. This parameter specifies the trigger conditions of an event. |
|
LevelList | List | ["CRITICAL","WARN"] |
The level of the event-triggered alert rule. Valid values:
|
NameList | List | Agent_Status_Running |
The name of the event. |
Product | String | CloudMonitor |
The name of the cloud service. |
StatusList | List | Running |
The status of the event. |
EventType | String | SYSTEM |
The type of the event. Valid values:
|
GroupId | String | 3607**** |
The ID of the application group. |
Name | String | test_DefaultEventRule_7378**** |
The name of the event-triggered alert rule. |
State | String | ENABLED |
The status of the event-triggered alert rule. Valid values:
|
Message | String | The alert does not exist. |
The error message. |
RequestId | String | 9AA3F210-C03D-4C86-8DB6-21C84FF692A1 |
The ID of the request. |
Code | String | 200 |
The HTTP status code. Note The status code 200 indicates that the call was successful.
|
Success | Boolean | true |
Indicates whether the call was successful. Valid values:
|
Examples
Sample requests
http(s)://[Endpoint]/?Action=DescribeEventRuleAttribute
&RuleName=testRule
&<Common request parameters>
Sample success responses
XML
format
<DescribeEventRuleAttributeResponse>
<RequestId>9AA3F210-C03D-4C86-8DB6-21C84FF692A1</RequestId>
<Code>200</Code>
<Success>true</Success>
<Result>
<EventPattern>
<NameList>
<NameList>Agent_Status_Running</NameList>
</NameList>
<LevelList>
<LevelList>CRITICAL</LevelList>
</LevelList>
<Product>CloudMonitor</Product>
</EventPattern>
<Description>Default group event rule</Description>
<EventType>SYSTEM</EventType>
<State>ENABLED</State>
<Name>test_DefaultEventRule_7378****</Name>
<GroupId>3607****</GroupId>
</Result>
</DescribeEventRuleAttributeResponse>
JSON
format
{
"RequestId": "9AA3F210-C03D-4C86-8DB6-21C84FF692A1",
"Code": "200",
"Success": true,
"Result": {
"EventPattern": {
"NameList": {
"NameList": [
"Agent_Status_Running"
]
},
"LevelList": {
"LevelList": [
"CRITICAL"
]
},
"Product": "CloudMonitor"
},
"Description": "Default group event rule",
"EventType": "SYSTEM",
"State": "ENABLED",
"Name": "test_DefaultEventRule_7378****",
"GroupId": "3607****"
}
}
Error codes
For a list of error codes, visit the API Error Center.