You need to enable JavaScript to run this app.
文档中心
应用性能监控全链路版

应用性能监控全链路版

复制全文
下载 pdf
错误新增报警
UpdateWebProNewErrorAlertRule
复制全文
下载 pdf
UpdateWebProNewErrorAlertRule
更新错误新增报警规则。
请求说明
客户端监控已在全球多个地域部署服务,旨在为您提供更稳定、低延迟的访问体验。您可以通过查阅 服务地址 文档,根据业务所在地选择最合适的接入点。
  • 请求方式:POST
  • 请求地址:https://apmplus-openapi.cn-beijing.volcengineapi.com?Action=UpdateWebProNewErrorAlertRule&Version=2022-10-12
请求参数
下方仅列出该接口特有的请求参数和部分公共参数,更多详细信息参见 公共参数
参数
类型
是否必选
示例值
描述
Action
String
UpdateWebProNewErrorAlertRule
接口名称。当前 API 的名称为 UpdateWebProNewErrorAlertRule
Version
String
2022-10-12
接口版本。当前 API 的版本为 2022-10-12
alert_param
Object of AlertParam
-
报警参数集合。
common
Object of CommonParams
-
通用参数。
AlertParam
参数
类型
是否必选
示例值
描述
id
Long
1
报警任务ID。
name
String
test
报警任务名称。
chats
Array of String
[1234]
报警通知群。
methods
Array of String
lark_webhook
配置报警通知方式。
  • mail:邮箱
  • lark_webhook:飞书
  • wechat_webhook:企业微信
  • dingding_webhook:钉钉
  • webhook:报警回调
is_close
Boolean
0
是否开启报警。
  • 0:开启
  • 1:关闭
receivers
Array of String
[]
接收人。当报警通知方式为lark时必填。
alert_level
String
warning
报警级别。
  • warning:提示
  • fatal:严重
mail_groups
Array of String
[123]
邮件通知组。
lark_at_conf
Object of AtConf
Jack
飞书需要at的人。
callback_urls
Array of String
[]
报警回调webhook。
lark_webhooks
Array of String
[]
飞书webhook。
alert_language
String
zh
报警语言。
  • en:海外
  • zh:国内
alert_strategy
Object of AlertStrategy
all
报警策略。多策略之间的关系只能是或。
  • latest:最新版本
  • specify:指定版本
  • all:全部版本
wechat_at_conf
Object of AtConf
Rose
企业微信需要at的人。
dingding_at_conf
Object of AtConf
Carl
钉钉需要at的人。
we_chat_webhooks
Array of String
[]
企业微信webhook。
dingding_webhooks
Array of String
[]
钉钉webhook。
CommonParams
参数
类型
是否必选
示例值
描述
aid
Long
12345
应用ID。
site_type
String
web
站点类型。
env
String
online
环境,填""时为全部。
os
String
webpro
服务类型,可选值为webproappminipro
user
String
test_user
用户名。
AtConf
参数
类型
是否必选
示例值
描述
id_type
String
userid
类型。
id_values
Array of String
[]
类型对应的值。
AlertStrategy
参数
类型
是否必选
示例值
描述
evType
String
js_error
枚举类型。
  • js_error:JS错误
  • http:请求错误
  • resource_error:静态资源错误
releases
Array of String
2.0.0
如果关注的是版本的新增错误,则需要传关注的版本列表。
disappear_time
Integer
30
多少天未出现认为是新错误。
user_threshold
Integer
100
用户数阈值。
filter_condition
Object of FilterConditions
-
筛选条件。
sample_threshold
Integer
100
样本数量阈值。
isReleaseNewError
Boolean
true
是否关注的是版本新增错误。
  • true:是
  • false:否
FilterConditions
参数
类型
是否必选
示例值
描述
type
String
and
筛选条件key。
sub_conditions
Array of SubCondition
[]
筛选条件值。
SubCondition
参数
类型
是否必选
示例值
描述
op
String
in
条件符号。
  • in:包含
  • not_in:不包含
  • Regex:正则匹配
  • not_regex:正则不匹配
value
String
-
筛选值的值,表示等值。
values
Array of String
-
筛选值的值,表示范围。
groupKey
String
-
报警分组维度。
dimension
String
-
报警归因维度。
请求示例
POST https://apmplus-openapi.cn-beijing.volcengineapi.com?Action=UpdateWebProNewErrorAlertRule&Version=2022-10-12
{
"common": {
"aid": 1,
"os": "webpro"
},
"alert_param": {
"name": "newRule",
"is_close": false,
"methods": [
"lark_webhook"
],
"alert_language": "zh",
"alert_level": "warning",
"note": "",
"id": 1,
"lark_webhooks": [
"your webhook"
],
"lark_at_conf": {
"id_type": "userid",
"id_values": []
},
"alert_strategy": {
"evType": "js_error",
"isReleaseNewError": true,
"user_threshold": 200,
"sample_threshold": 100,
"filter_condition": {
"type": "and",
"sub_conditions": []
}
}
}
}
返回参数
参数
类型
示例值
描述
error_no
Integer
0
错误码。成功为0。
error_msg
String
""
错误信息。成功为""
返回示例
{
"err_detail": "",
"data": null,
"error_msg": "",
"error_no": 0
}
错误码
当前接口暂无独立错误码,若接口调用返回异常,可参考 公共错误码 进行故障排查。
最近更新时间:2026.08.28 16:25:38
这个页面对您有帮助吗?
有用
有用
无用
无用