调用GetRemind接口,获取自定义监控报警规则的详情。
调试
您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。
调试
授权信息
请求参数
|
名称 |
类型 |
必填 |
描述 |
示例值 |
| RemindId |
integer |
是 |
自定义监控规则的 ID。 |
1234 |
返回参数
|
名称 |
类型 |
描述 |
示例值 |
|
object |
返回的数据类型。 |
||
| HttpStatusCode |
integer |
HTTP 返回码。 |
200 |
| RequestId |
string |
本次调用的唯一 ID。出现错误后,您可以根据该 ID 排查问题。 |
0000-ABCD-EFGH-IJK**** |
| ErrorMessage |
string |
错误信息。 |
The specified parameters are invalid. |
| ErrorCode |
string |
错误码。 |
1031203110005 |
| Success |
boolean |
调用是否成功。 |
true |
| Data |
object |
自定义监控规则的详情。 |
|
| MaxAlertTimes |
integer |
最大报警次数。 |
3 |
| RemindUnit |
string |
对象的类型,包括 NODE(任务节点)、BASELINE(基线)、PROJECT(工作空间)和 BIZPROCESS(业务流程)。 |
NODE |
| AlertInterval |
integer |
最小报警间隔,单位为秒。 |
1800 |
| Useflag |
boolean |
自定义监控规则是否开启,包括 true(开启)和 false(关闭)。 |
true |
| Founder |
string |
自定义监控规则创建人的阿里云 UID。 |
9527951795**** |
| RemindId |
integer |
自定义监控规则的 ID。 |
1234 |
| DndEnd |
string |
免打扰截止时间,格式为 hh:mm。hh 的取值范围为[0,23],mm 的取值范围为[0,59]。 |
08:00 |
| RemindType |
string |
触发条件,包括 FINISHED(完成)、UNFINISHED(未完成)、ERROR(出错)、CYCLE_UNFINISHED(周期未完成)和 TIMEOUT(运行超时)。 |
FINISHED |
| AlertUnit |
string |
报警接收对象类型,多类型告警接收人参考出参 Receivers。
|
OWNER |
| DndStart |
string |
免打扰起始时间,格式为 hh:mm。hh 的取值范围为[0,23],mm 的取值范围为[0,59]。 |
00:00 |
| RemindName |
string |
规则的名称。 |
Rule name |
| Detail |
string |
|
{"hour":23,"minu":59} |
| Robots |
array<object> |
钉钉群机器人的 webhook 地址列表。 |
|
|
object |
返回的数据类型。 |
||
| WebUrl |
string |
钉钉群机器人的 webhook 地址。 |
https://oapi.dingtalk.com/robot/send?access_token=****************************** |
| AtAll |
boolean |
是否@所有人,包括 true(是)和 false(否)。 |
true |
| Nodes |
array<object> |
当 RemindUnit(对象类型)为 NODE(任务节点)时,该规则监控的节点列表。 |
|
|
object |
返回的数据类型。 |
||
| Owner |
string |
节点责任人的阿里云 UID。 |
9527951795**** |
| NodeName |
string |
节点的名称。 |
Node name |
| NodeId |
integer |
节点的 ID。 |
1234 |
| ProjectId |
integer |
节点所在工作空间的 ID。 |
1234 |
| Baselines |
array<object> |
当 RemindUnit(对象类型)为 BASELINE(基线)时,该规则监控的基线列表。 |
|
|
object |
返回的数据类型。 |
||
| BaselineName |
string |
基线的名称。 |
Baseline name |
| BaselineId |
integer |
基线的 ID。 |
1234 |
| Projects |
array<object> |
当 RemindUnit(对象类型)为 PROJECT(工作空间)时,该规则监控的工作空间列表。 |
|
|
object |
返回的数据类型。 |
||
| ProjectId |
integer |
工作空间的 ID。 |
1234 |
| BizProcesses |
array<object> |
当 RemindUnit(对象类型)为 BIZPROCESS(业务流程)时,该规则监控的业务流程列表。 |
|
|
object |
返回的数据类型。 |
||
| BizProcessName |
string |
业务流程名称。 |
Business process name |
| BizId |
integer |
业务流程 ID。 |
9527 |
| AlertTargets |
array |
报警接收人说明。多类型告警接收人参考出参 Receivers。 |
|
|
string |
|
9527952795279527 |
|
| AlertMethods |
array |
报警方式。 |
|
|
string |
报警的方式,取值如下:
|
SMS,MAIL |
|
| Webhooks |
array |
WebHook URL |
|
|
string |
企业微信或飞书机器人的 WebHook 地址。AlertMethods 中需要包含 WebHook 告警方式。 自定义 Webhook 仅 DataWorks 企业版支持。 |
https://open.feishu.cn/open-apis/bot/v2/hook/******* |
|
| Receivers |
array<object> |
告警接收人信息。 |
|
|
object |
报警接收对象类型。 |
||
| AlertUnit |
string |
报警接收对象类型,多类型告警接收人参考出参 Receivers。
|
OWNER |
| AlertTargets |
array |
告警接受对象。 |
|
|
string |
|
9527952795279527 |
|
| AllowNodes |
array |
告警白名单。 |
|
|
integer |
白名单中的任务 ID,在监控时会被忽略。 |
123 |
示例
正常返回示例
JSON格式
{
"HttpStatusCode": 200,
"RequestId": "0000-ABCD-EFGH-IJK****",
"ErrorMessage": "The specified parameters are invalid.",
"ErrorCode": "1031203110005",
"Success": true,
"Data": {
"MaxAlertTimes": 3,
"RemindUnit": "NODE",
"AlertInterval": 1800,
"Useflag": true,
"Founder": "9527951795****",
"RemindId": 1234,
"DndEnd": "08:00",
"RemindType": "FINISHED",
"AlertUnit": "OWNER",
"DndStart": "00:00",
"RemindName": "Rule name",
"Detail": "{\"hour\":23,\"minu\":59}",
"Robots": [
{
"WebUrl": "https://oapi.dingtalk.com/robot/send?access_token=******************************",
"AtAll": true
}
],
"Nodes": [
{
"Owner": "9527951795****",
"NodeName": "Node name",
"NodeId": 1234,
"ProjectId": 1234
}
],
"Baselines": [
{
"BaselineName": "Baseline name",
"BaselineId": 1234
}
],
"Projects": [
{
"ProjectId": 1234
}
],
"BizProcesses": [
{
"BizProcessName": "Business process name",
"BizId": 9527
}
],
"AlertTargets": [
"9527952795279527"
],
"AlertMethods": [
"SMS,MAIL"
],
"Webhooks": [
"https://open.feishu.cn/open-apis/bot/v2/hook/*******"
],
"Receivers": [
{
"AlertUnit": "OWNER",
"AlertTargets": [
"9527952795279527"
]
}
],
"AllowNodes": [
123
]
}
}
错误码
|
HTTP status code |
错误码 |
错误信息 |
描述 |
|---|---|---|---|
| 500 | Forbidden.Not.Server | The dataworksAPI service is not available in this area. Please try it in another area. | |
| 500 | InternalError.System | An internal system error occurred. Try again later. | |
| 500 | InternalError.UserId.Missing | An internal system error occurred. Try again later. | |
| 403 | Forbidden.Access | Access is forbidden. Please first activate DataWorks Enterprise Edition or Flagship Edition. | 没有权限,请授权 |
| 429 | Throttling.Api | The request for this resource has exceeded your available limit. | |
| 429 | Throttling.Api.Risk | The request for this resource has exceeded your daily available limit. | |
| 429 | Throttling.Resource | You have reached the limit for the resource. Please contact us by submitting a ticket. | |
| 429 | Throttling.System | The DataWorks system is busy. Try again later. | |
| 429 | Throttling.User | Your request is too frequent. Try again later. |
访问错误中心查看更多错误码。
变更历史
更多信息,参考变更详情。