跳转到主要内容
POST
/
cloudextraction
/
statuses
批量获取任务状态
curl --request POST \
  --url https://openapi.bazhuayu.com/cloudextraction/statuses \
  --header 'Authorization: <authorization>' \
  --header 'Content-Type: <content-type>' \
  --data '
{
  "taskIds": [
    "<string>"
  ]
}
'
所需套餐: 旗舰+、企业版、团队版

端点

POST https://openapi.bazhuayu.com/cloudextraction/statuses

描述

根据任务 ID 批量获取任务状态信息。调用频率:5 秒 1 次请求。

请求头

参数类型必填说明
AuthorizationString身份令牌
Content-TypeStringapplication/json
请求头示例
{
  "Authorization": "Bearer <access_token>",
  "Content-Type": "application/json"
}

请求体

参数类型必填说明
taskIdsString[]任务 Id 列表
请求体示例
{
  "taskIds": [
    "a3b9bdf7-9aaa-22f6-9ccf-b32790f6df8f",
    "86b9bdf7-9aaa-22236-9ccf-b3279469df01"
  ]
}

响应

参数类型必填说明
dataObject[]响应数据
taskIdString任务Id
taskNameString任务名
statusString任务状态:Unexecuted - 未执行,Waiting - 等待分配,Extracting - 采集中,Stopped - 已停止,Finished - 已完成
requestIdString请求Id
成功示例
{
  "data": [
    {
      "taskId": "a3b9bdf7-9aaa-22f6-9ccf-b32790f6df8f",
      "taskName": "八爪鱼采集",
      "status": "Extracting"
    },
    {
      "taskId": "86b9bdf7-9aaa-22236-9ccf-b3279469df01",
      "taskName": "八爪鱼采集2",
      "status": "Stopped"
    }
  ],
  "requestId": "0HMD469L0I8R0:00000001"
}

错误响应

参数类型必填说明
requestIdString请求Id
errorObject错误信息,参考错误码
codeString错误码
messageString错误描述
错误示例
{
  "error": {
    "code": "ServerError",
    "message": "Internal Server Error"
  },
  "requestId": "0HMD469L0I8R0:00000001"
}