链接复制成功!
查询告警消息列表
功能介绍
查询单个告警的触发详情与历史。
调试
您可以在API Explorer中调试该接口,支持自动认证鉴权。API Explorer可以自动生成SDK代码示例,并提供SDK代码示例调试功能。
URI
POST /v1/apm2/openapi/alarm/data/get-alarm-notify-list
请求参数
参数 |
是否必选 |
参数类型 |
描述 |
---|---|---|---|
X-Auth-Token |
是 |
String |
从IAM服务获取的用户Token。 |
x-business-id |
是 |
Long |
应用id,用于鉴权。 |
响应参数
状态码: 200
参数 |
参数类型 |
描述 |
---|---|---|
front_alarm_notify_results |
Array of FrontAlarmNotifyResult objects |
告警通知列表。 |
total_count |
Integer |
消息总数。 |
请求示例
分页查询告警事件ID为42,Region ID为xxx-roma-2的触发详情与历史
/v1/apm2/openapi/alarm/data/get-alarm-notify-list
{
"alarm_data_id" : 42,
"region" : "xxx-roma-2",
"page" : 1,
"page_size" : 10
}
响应示例
状态码: 200
OK,请求响应成功。
{
"front_alarm_notify_results" : [ {
"id" : 1741,
"gmt_create" : "2022-10-09 22:58:27",
"notify_type" : "RECOVER",
"alarm_rule_id" : 3,
"template_id" : 2,
"alarm_data_event_id" : 42,
"notify_status" : false,
"alarm_content" : "CPU0.017使用率为0.017"
}, {
"id" : 1735,
"gmt_create" : "2022-10-09 22:58:26",
"notify_type" : "RECOVER",
"alarm_rule_id" : 3,
"template_id" : 2,
"alarm_data_event_id" : 42,
"notify_status" : false,
"alarm_content" : "CPU0.017使用率为0.017"
}, {
"id" : 682,
"gmt_create" : "2022-10-09 21:20:11",
"notify_type" : "RECOVER",
"alarm_rule_id" : 3,
"template_id" : 2,
"alarm_data_event_id" : 42,
"notify_status" : false,
"alarm_content" : "CPU0.017使用率为0.017"
}, {
"id" : 639,
"gmt_create" : "2022-10-09 21:16:04",
"notify_type" : "ALARM",
"alarm_rule_id" : 3,
"template_id" : 2,
"alarm_data_event_id" : 42,
"notify_status" : false,
"alarm_content" : "CPU0.021使用率为0.021"
} ],
"total_count" : 4
}
状态码
状态码 |
描述 |
---|---|
200 |
OK,请求响应成功。 |
400 |
Bad Request,语义或参数有误。 |
401 |
Unauthorized,没有权限。 |
403 |
Forbidden,禁止访问。 |
404 |
Not Found,没有找到要请求的资源。 |
错误码
请参见错误码。
父主题: 告警管理