根據基準ID擷取基準配置。
調試
您可以在OpenAPI Explorer中直接運行該介面,免去您計算簽名的困擾。運行成功後,OpenAPI Explorer可以自動產生SDK程式碼範例。
調試
授權資訊
請求參數
|
名稱 |
類型 |
必填 |
描述 |
樣本值 |
| BaselineId |
integer |
是 |
基準的 ID,可以通過 ListBaselines 擷取。 |
123456 |
| ProjectId |
integer |
是 |
基準所監控的專案空間 ID,可從 ListBaselines 擷取。 |
10000 |
返回參數
|
名稱 |
類型 |
描述 |
樣本值 |
|
object |
OpenApiResultModel |
||
| Success |
boolean |
請求是否成功,true - 成功,false - 失敗。 |
true |
| ErrorCode |
string |
錯誤碼。 |
1031203110005 |
| ErrorMessage |
string |
錯誤資訊。 |
The specified parameters are invalid |
| HttpStatusCode |
integer |
HTTP 返回碼。 |
200 |
| Data |
object |
傳回值。 |
|
| BaselineId |
integer |
基準的 id。 |
1001 |
| BaselineName |
string |
基準名。 |
Test baseline |
| ProjectId |
integer |
專案 id。 |
10000 |
| Owner |
string |
責任人。 |
9527952**** |
| Priority |
integer |
基準的優先順序,取值集合為{1,3,5,7,8}。 |
1 |
| BaselineType |
string |
基準類型。
|
DAILY |
| OverTimeSettings |
array<object> |
基準承諾時間設定。 |
|
|
object |
監控周期。 |
||
| Cycle |
integer |
承諾時間對應的周期,Apsara Infrastructure Management Framework線是 1,小時基準可以配置最多 24 個周期。 |
1 |
| Time |
string |
承諾時間,hh:mm 格式,hh 的取值範圍為[0,47],mm 的取值範圍為[0,59]。 |
00:00 |
| Enabled |
boolean |
是否開啟基準。 |
true |
| NodeIds |
array |
基準上遊節點列表。 |
|
|
integer |
節點 ID。 |
700003**** |
|
| AlertEnabled |
boolean |
是否開啟警示。
|
true |
| AlertMarginThreshold |
integer |
預警餘量,單位為分鐘。 |
60 |
| AlertSettings |
array<object> |
警示設定。 |
|
|
array<object> |
基準的警示配置。 |
||
| AlertType |
string |
警示類型
|
BASELINE |
| AlertMethods |
array |
警示方式列表 |
|
|
string |
警示方式。取值如下:
|
|
|
| SilenceStartTime |
string |
靜默開始時間,格式為 HH:mm:ss 。 |
00:00:00 |
| SilenceEndTime |
string |
靜默結束時間,格式為 HH:mm:ss 。 |
00:00:00 |
| AlertInterval |
integer |
事件警示間隔,單位為秒。 |
900 |
| AlertMaximum |
integer |
事件警示最大次數。 |
1 |
| DingRobots |
array<object> |
DingTalk機器人列表。 |
|
|
object |
DingTalk機器人配置。 |
||
| WebUrl |
string |
DingTalk機器人地址。 |
https://oapi.dingtalk.com/robot/send?access_token=xxx |
| AtAll |
boolean |
是否 @所有人。 |
true |
| Webhooks |
array |
webhook 列表。 |
|
|
string |
企業微信或飛書機器人的 webhook 地址,多個 webhook 地址之間使用英文逗號(,)分隔。alertMethods 中需要包含 WEBHOOKS 警示方式。僅 DataWorks 企業版支援。 可用地區:華東 2(上海)、西南 1(成都)、華北 3(張家口)、華北 2(北京)、華東 1(杭州)、華南 1(深圳)、中國(香港)、歐洲中部 1(法蘭克福)、亞太地區東南 1(新加坡)。 |
https://open.feishu.cn/open-apis/bot/v2/hook/xxx |
|
| TopicTypes |
array |
事件警示類型列表,事件特有配置。 |
|
|
string |
事件警示類型。
|
SLOW |
|
| BaselineAlertEnabled |
boolean |
基準警示開關,基準特有配置。
|
false |
| AlertRecipientType |
string |
警示接收人類型。
|
OWNER |
| AlertRecipient |
string |
警示接收人詳情。
|
123123 |
| RequestId |
string |
請求 ID。 |
ecb967ec-c137-48a5-860**** |
樣本
正常返回樣本
JSON格式
{
"Success": true,
"ErrorCode": "1031203110005",
"ErrorMessage": "The specified parameters are invalid",
"HttpStatusCode": 200,
"Data": {
"BaselineId": 1001,
"BaselineName": "Test baseline",
"ProjectId": 10000,
"Owner": "9527952****",
"Priority": 1,
"BaselineType": "DAILY",
"OverTimeSettings": [
{
"Cycle": 1,
"Time": "00:00"
}
],
"Enabled": true,
"NodeIds": [
0
],
"AlertEnabled": true,
"AlertMarginThreshold": 60,
"AlertSettings": [
{
"AlertType": "BASELINE",
"AlertMethods": [
"MAIL"
],
"SilenceStartTime": "00:00:00",
"SilenceEndTime": "00:00:00",
"AlertInterval": 900,
"AlertMaximum": 1,
"DingRobots": [
{
"WebUrl": "https://oapi.dingtalk.com/robot/send?access_token=xxx",
"AtAll": true
}
],
"Webhooks": [
"https://open.feishu.cn/open-apis/bot/v2/hook/xxx"
],
"TopicTypes": [
"SLOW"
],
"BaselineAlertEnabled": false,
"AlertRecipientType": "OWNER",
"AlertRecipient": "123123"
}
]
},
"RequestId": "ecb967ec-c137-48a5-860****"
}
錯誤碼
訪問錯誤中心查看更多錯誤碼。
變更歷史
更多資訊,參考變更詳情。