查詢資料品質校驗任務詳情。
目前該API介面已標記為棄用,推薦使用替代API:dataworks-public(2024-05-18) - CreateDataQualityScan。
介面說明
需要购买 DataWorks 基础版及以上版本才能使用。
調試
您可以在OpenAPI Explorer中直接運行該介面,免去您計算簽名的困擾。運行成功後,OpenAPI Explorer可以自動產生SDK程式碼範例。
調試
授權資訊
請求參數
|
名稱 |
類型 |
必填 |
描述 |
樣本值 |
| Id |
integer |
否 |
資料品質監控 ID。 |
1006455182 |
返回參數
|
名稱 |
類型 |
描述 |
樣本值 |
|
object |
Schema of Response |
||
| RequestId |
string |
Id of the request |
SDFSDFSDF-SDFSDF-SDFDSF-SDFSDF |
| DataQualityEvaluationTask |
object |
数据质量监控详情。 |
|
| Target |
object |
数据质量监控对象。 |
|
| Type |
string |
The type of the monitoring object.
|
Table |
| DatabaseType |
string |
The type of the database to which the table belongs. Valid values:
|
maxcompute |
| TableGuid |
string |
The ID of the table in Data Map. |
odps.meta_open_api_test_sz.test_partition_tbl |
| PartitionSpec |
string |
Data quality monitoring partition range settings. |
pt=$[yyyymmdd-1] |
| Description |
string |
质量监控任务描述。 |
The description of the quality monitoring task. |
| Trigger |
object |
数据质量校验任务的触发配置。 |
|
| Type |
string |
The trigger type of the monitor. Valid values:
|
ByScheduledTaskInstance |
| TaskIds |
array |
The IDs of scheduling tasks. This parameter is valid only if you set Type to ByScheduledTaskInstance. |
|
|
integer |
The ID of the scheduling task. |
30001 |
|
| RuntimeConf |
string |
扩展配置,JSON 格式的字符串,只对 EMR 类型的数据质量监控生效。
|
{ "queue": "default", "sqlEngine": "SPARK_SQL" } |
| Id |
integer |
数据质量监控 ID。 |
2178 |
| Name |
string |
质量监控任务名称。 |
OpenAPI create a data quality monitoring test |
| ProjectId |
integer |
项目空间 Id。 |
2626 |
| Hooks |
array<object> |
回调设置。 |
|
|
object |
Hook |
||
| Type |
string |
The hook type. Only one hook type is supported.
|
BlockTaskInstance |
| Condition |
string |
The hook trigger condition. When this condition is met, the hook action is triggered. Only two conditional expressions are supported:
|
(${severity} == "High" AND ${status} == "Critical") OR (${severity} == "Normal" AND ${status} == "Critical") OR (${severity} == "Normal" AND ${status} == "Error") |
| Notifications |
object |
通知订阅配置。 |
|
| Condition |
string |
The notification trigger condition. When this condition is met, the alert notification is triggered. Only two conditional expressions are supported:
|
(${severity} == "High" AND ${status} == "Critical") OR (${severity} == "Normal" AND ${status} == "Critical") OR (${severity} == "Normal" AND ${status} == "Error") |
| Notifications |
array<object> |
The configurations of alert notifications. |
|
|
array<object> |
|||
| NotificationReceivers |
array<object> |
The configurations of alert recipients. |
|
|
object |
|||
| ReceiverType |
string |
The additional parameters that are required when alerts are sent. The parameters are JSON-formatted strings. The following keys are supported:
Valid values:
枚舉值:
|
DingdingUrl |
| Extension |
string |
The extended information. |
{ "atAll": true } |
| ReceiverValues |
array |
The alert recipients. |
|
|
string |
The value of the receiver.
|
https://api.fc.aliyuncs.com/webhook |
|
| NotificationChannels |
array<object> |
The alert notification methods. |
|
|
object |
|||
| Channels |
array |
The alert notification methods. |
|
|
string |
The alert notification method. Valid values:
|
|
|
| DataSourceId |
integer |
质量监控任务所使用的数据源 ID。 |
45238 |
樣本
正常返回樣本
JSON格式
{
"RequestId": "SDFSDFSDF-SDFSDF-SDFDSF-SDFSDF",
"DataQualityEvaluationTask": {
"Target": {
"Type": "Table",
"DatabaseType": "maxcompute",
"TableGuid": "odps.meta_open_api_test_sz.test_partition_tbl",
"PartitionSpec": "pt=$[yyyymmdd-1]"
},
"Description": "The description of the quality monitoring task.",
"Trigger": {
"Type": "ByScheduledTaskInstance",
"TaskIds": [
30001
]
},
"RuntimeConf": "{ \"queue\": \"default\", \"sqlEngine\": \"SPARK_SQL\" }\n",
"Id": 2178,
"Name": "OpenAPI create a data quality monitoring test",
"ProjectId": 2626,
"Hooks": [
{
"Type": "BlockTaskInstance",
"Condition": "(${severity} == \"High\" AND ${status} == \"Critical\") OR (${severity} == \"Normal\" AND ${status} == \"Critical\") OR (${severity} == \"Normal\" AND ${status} == \"Error\")"
}
],
"Notifications": {
"Condition": "(${severity} == \"High\" AND ${status} == \"Critical\") OR (${severity} == \"Normal\" AND ${status} == \"Critical\") OR (${severity} == \"Normal\" AND ${status} == \"Error\")",
"Notifications": [
{
"NotificationReceivers": [
{
"ReceiverType": "DingdingUrl",
"Extension": "{ \"atAll\": true }\n",
"ReceiverValues": [
"https://api.fc.aliyuncs.com/webhook\n"
]
}
],
"NotificationChannels": [
{
"Channels": [
"Mail"
]
}
]
}
]
},
"DataSourceId": 45238
}
}
錯誤碼
訪問錯誤中心查看更多錯誤碼。
變更歷史
更多資訊,參考變更詳情。