You need to enable JavaScript to run this app.
文档中心
云监控

云监控

复制全文
下载 pdf
通知策略
ListNotifications
复制全文
下载 pdf
ListNotifications
查询通知策略列表。
请求说明
  • 请求方式:POST
  • 请求地址:https://cloudmonitor.cn-beijing.volcengineapi.com?Action=ListNotifications&Version=2018-01-01
调试
API Explorer
您可以通过 API Explorer 在线发起调用,无需关注签名生成过程,快速获取调用结果。
请求参数
参数
类型
是否必选
示例值
描述
Action
String
ListNotifications
接口名称。当前 API 的名称为 ListNotifications
Version
String
2018-01-01
接口版本。当前 API 的版本为 2018-01-01
Name
String
notification-demo
基于告警通知策略名称进行筛选。
Levels
Array of String
notice
基于告警通知等级进行筛选,取值:
  • notice:通知
  • warning:警告
  • critical:严重
  • recovery:恢复
RuleIds
Array of String
189898***00
基于告警通知策略 ID 进行筛选。
可以调用 ListNotifications接口,获取通知策略 ID。
PageNumber
Integer
1
列表的页码,默认值为1。要查询的列表范围为:
  • 实际起始位置 = (PageNumber-1) * PageSize
  • 实际终止位置 = PageNumber * PageSize
PageSize
Integer
10
分页查询时每页的行数,取值 > 0 ,默认值为 10。
请求示例
POST https://cloudmonitor.cn-beijing.volcengineapi.com?Action=ListNotifications&Version=2018-01-01
Content-Type: application/json
{
"Name": "notification-demo",
"Levels": [
"notice"
],
"RuleIds": [
"189898***00"
],
"PageNumber": 1,
"PageSize": 10
}
返回参数
参数
类型
示例值
描述
Data
Array of Notification
-
通知策略详情。
Notification
参数
类型
示例值
描述
Id
String
189898***00
通知策略 ID。
Name
String
notification-demo
通知策略名称。
Levels
Array of String
notice
告警通知等级。
RuleIds
Array of String
关联的告警策略id
CreatedAt
String
2021-10-20T20:27:53+08:00
通知策略的创建时间。
UpdatedAt
String
2021-10-20T20:27:53+08:00
通知策略的更新时间。
EffectEndAt
String
23:59
通知策略生效的截止时间,格式为HH:MM,例如:23:59。
EffectStartAt
String
00:00
通知策略生效的开始时间,格式为HH:MM,例如:00:00。
Notifications
Array of NotificationNotify
-
分级告警通知策略详情。
NotificationNotify
参数
类型
示例值
描述
Level
String
critical
告警等级。
WebhookIds
Array of String
18913208***4528
Webhook 回调 ID。
AlertMethods
Array of String
Email
告警通知方式。
ContactGroupIds
Array of String
145080093687100****
告警联系组 ID。
NotifyTemplates
-
通知模版配置。
NotifyTemplateBasic
参数
类型
示例值
描述
Channel
String
email
通知渠道,取值:
  • email:邮箱
  • sms:短信
  • phone:电话
  • lark:飞书
  • dingtalk:钉钉
  • wecom:企业微信
  • slack:Slack
  • api:回调地址
NotifyTemplateId
String
189828***00
通知模版 ID。
注意
每种通知渠道仅支持配置 1 个通知模版 ID。
返回示例
{
"ResponseMetadata": {
"Action": "ListNotifications",
"Region": "cn-beijing",
"Service": "cloudmonitor",
"Version": "2018-01-01",
"RequestId": "20230604110420****100232280022D31"
},
"Result": {
"Data": [
{
"Id": "189898***00",
"Name": "notification-demo",
"Levels": [
"notice"
],
"CreatedAt": "2021-10-20T20:27:53+08:00",
"UpdatedAt": "2021-10-20T20:27:53+08:00",
"EffectEndAt": "23:59",
"EffectStartAt": "00:00",
"Notifications": [
{
"Level": "critical",
"WebhookIds": [
"18913208***4528"
],
"AlertMethods": [
"Email"
],
"ContactGroupIds": [
"145080093687100****"
],
"NotifyTemplates": [
{
"Channel": "email",
"NotifyTemplateId": "189828***00"
}
]
}
]
}
],
"PageSize": 30,
"PageNumber": 1,
"TotalCount": 2
}
}
错误码
本接口无特有的错误码。更多信息请参见 错误码
最近更新时间:2026.08.11 20:28:01
这个页面对您有帮助吗?
有用
有用
无用
无用