华为云用户手册

  • 响应参数 状态码: 200 表4 响应Body参数 参数 参数类型 描述 count Integer 边缘资源池总量 edge_pools Array of EdgePoolListItemDto objects 边缘资源池列表响应体 表5 EdgePoolListItemDto 参数 参数类型 描述 id String 边缘池ID name String 边缘池名称 state String 边缘池状态 project_id String 用户项目ID workspace_id String 工作空间ID created_at Long 创建时间 updated_at Long 更新时间 description String 描述信息 状态码: 400 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议 状态码: 500 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议
  • 响应参数 状态码: 400 表3 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议 状态码: 500 表4 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议
  • 请求参数 表2 请求Header参数 参数 是否必选 参数类型 描述 X-Auth-Token 是 String 用户Token,获取方法参见认证鉴权 表3 请求Body参数 参数 是否必选 参数类型 描述 video_group_name 是 String 视频源分组名称,只能由中文、小写英文字母(a~z)、大写英文字母(A~Z)、数字(0~9)组成, 长度范围为[1, 20] 最大长度:20 description 否 String 视频源分组描述 最大长度:100 access_type 是 String 接入方式,只能选择cloud 或者 edge 最大长度:5 video_source_ids 否 Array of strings 选中分组内视频源id列表,只能由小写英文字母(a~z,)、数字(0~9)、中划线(-)、下划线(_)组成, 长度范围为[4, 36]
  • URI DELETE /v2/{project_id}/video-group/{video_group_id} 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 用户项目ID,获取方法参见获取项目ID和名称 video_group_id 是 String 视频源分组id,只能由小写英文字母(a~z,)、数字(0~9)、中划线(-)、下划线(_)长度范围为[4, 36]
  • URI GET /v2/{project_id}/source/sources 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 用户项目ID,获取方法参见获取项目ID和名称 最大长度:64 表2 Query参数 参数 是否必选 参数类型 描述 scope 否 String 模糊查找参数,可选,根据名称查找 最小长度:0 最大长度:255 scope_name 否 String 模糊查找参数字段名,可选,名称(取值source_name)或分组名称(取值group_name) 缺省值:source_name 最大长度:11 status 否 Array 视频源状态,可选,取值为1 2 9,分别代表在线、离线、异常 type 否 Array 类型:obs、vcn、url、restful、camera、ivm video_group_id 否 Array 视频源分组,可选。若传入则需要符合正则表达式^[0-9a-zA-Z-_]{1,36}$ sort_name 否 String 排序项。可选,值范围(create_at,num_task,num_template) 缺省值:create_at order_by 否 String 排序顺序,可选,默认倒序 缺省值:desc is_paged 否 Boolean 是否分页 缺省值:false page_size 否 Integer 分页每页显示的条目 最小值:5 最大值:200 缺省值:10 page_num 否 Integer 第几页 最小值:1 最大值:100000 缺省值:1 access_type 否 Array 接入方式 platform_name 否 String 平台名称 最小长度:0 最大长度:100 tag 否 String 标签 最小长度:0 最大长度:255
  • 响应示例 状态码: 200 视频源分组列表响应体 { "video_group_number": 23, "total_number": 23, "quota_number": 200, "video_group_list": [ { "video_group_id": "a9334780-a53c-454e-a3c1-259c54678ec1", "video_group_name": "test000", "num_video_source": 2, "group_status": { "num_online": 2, "num_exception": 0, "num_offline": 0 }, "access_type": "cloud", "create_at": 1680773327730, "modify_at": 1680773463291, "num_batch_task": 0, "type": "restful" } }
  • URI GET /v2/{project_id}/video-group/groups 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 用户项目ID,获取方法参见获取项目ID和名称 最大长度:64 表2 Query参数 参数 是否必选 参数类型 描述 sort_name 否 String 排序项。可选,可选值(create_at、modify_at、num_video_source、num_task) 缺省值:create_at order_by 否 String 排序顺序,可选,默认倒序,可选值(desc、asc) 缺省值:desc is_paged 否 Boolean 是否分页 缺省值:false page_size 否 Integer 分页每页显示的条目 最小值:5 最大值:200 缺省值:10 page_num 否 Integer 第几页 最小值:1 最大值:100000 缺省值:1 name 否 String 模糊查找参数,可以按分组名称进行模糊查找 最大长度:20 status 否 String 状态level筛选,可选值(1、2、9) access_type 否 Array 根据接入方式筛选(可多选),可选值(cloud、edge) has_task 否 Boolean 是否有批量作业 缺省值:false type 否 Array 视频源类型筛选(可多选)类型:obs、vcn、url、restful、camera
  • 响应参数 状态码: 200 表4 响应Body参数 参数 参数类型 描述 video_group_number Integer 分组数量 total_number Integer 视频源分组总数 quota_number Integer 视频源分组最大限额 video_group_list Array of VideoGroupListInfoDto objects 分组列表 表5 VideoGroupListInfoDto 参数 参数类型 描述 video_group_id String 视频源分组id video_group_name String 视频源分组名称 num_video_source Integer 视频源数量 group_status GroupStatusDto object 分组中视频源状态 access_type String 接入方式 create_at Long 创建时间 modify_at Long 最后一次修改时间 num_batch_task Integer 已配置批量作业数量 type String 分组中视频源类型 表6 GroupStatusDto 参数 参数类型 描述 num_online Integer 在线视频源数量 num_exception Integer 异常视频源数量 num_offline Integer 离线视频源数量
  • URI PUT /v2/{project_id}/source/{video_source_id} 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 用户项目ID,获取方法参见获取项目ID和名称 最大长度:64 video_source_id 是 String 已创建成功的视频源id,只能由小写英文字母(a~z,)、数字(0~9)、中划线(-)、下划线(_)长度范围为[4, 36] 最大长度:36
  • 响应参数 状态码: 200 表4 响应Body参数 参数 参数类型 描述 video_source_name String 视频源名称,只支持中文、英文字母(a-z,A-Z)、数字、特殊字符(空格.-_() ()),不能以空格开头和结尾 最小长度:1 最大长度:100 access_type String 接入类型(cloud、edge) status VideoSourceStatusInfoDto object 数据源状态 type String 类型:obs、vcn、url、restful、camera latitude String 视频源的地理位置信息,纬度,-90.00000~90.00000 longitude String 视频源的地理位置信息,经度,-180.00000~180.00000 create_at Long 创建时间 type_config String 视频源配置信息xml video_packages Array of VideoGroupInfoDto objects 视频源所在分组 service_config_templates Array of VideoServiceConfigTemplateDto objects 算法模板体 stream_path String 流地址 image String 视频源截图的base64转码 tag Array of strings 视频源标签,标签最多选择4个,标签内容只能由中文, 英文字母(a~z, A~Z)、数字(0~9)、中划线(-)、下划线(_)组成, 最小长度:1 最大长度:10 scene_recommend Array of strings 智能算法推荐的标签 video_source_quality Array of strings 视频源的视频流质量: Blurry:画面模糊; ColorDistortion:画面颜色失真; AbnormalLight:画面光线异常; ScreenSplash:画面花屏异常; ScreenJitter:画面抖动; ScreenMovement:画面移动; SceneUpheaval:画面剧变; ScreenFreeze:画面冻结; BlackScreen:黑屏; SnowNoise:雪花噪声; Occlude:遮挡; GrayScreen:灰屏;ScreenSmudge:画面污迹 表5 VideoSourceStatusInfoDto 参数 参数类型 描述 status String 视频源状态 name String 状态中文名 level String 状态等级(用于前端图片颜色匹配) 表6 VideoGroupInfoDto 参数 参数类型 描述 video_group_id String 视频源所在分组id video_group_name String 视频源所在分组名称 description String 视频源所在分组描述 access_type String 接入方式(cloud、edge) create_at Long 创建时间 modify_at Long 修改时间 num_video_source Integer 视频源数量 group_status GroupStatusDto object 视频源状态 num_batch_task Integer 已配置批量作业数量 表7 GroupStatusDto 参数 参数类型 描述 num_online Integer 在线视频源数量 num_exception Integer 异常视频源数量 num_offline Integer 离线视频源数量 表8 VideoServiceConfigTemplateDto 参数 参数类型 描述 name String 算法服务名称 roi String 公共roi serviceConfig String 算法服务公共配置 createAt Long 创建时间 modifyAt Long 修改时间 numTask Integer 已运行算法数量
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 total_count Integer 作业总数 failed_count Integer 失败作业数量 succeed_count Integer 成功作业数量 id String 批量作业id error_list Array of strings 错误信息列表 状态码: 400 表4 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议 状态码: 500 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议
  • URI PUT /v2/{project_id}/batch-tasks/{id}/action/{command} 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 用户项目ID,获取方法参见获取项目ID和名称 id 是 String 批量配置ID command 是 String 指定该API要对批量任务配置进行的操作,停止或者启动 枚举值:start|stop
  • 响应参数 状态码: 201 表4 响应Body参数 参数 参数类型 描述 id String 创建出的边缘池ID 状态码: 400 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议 状态码: 500 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议
  • 请求参数 表2 请求Header参数 参数 是否必选 参数类型 描述 X-Auth-Token 是 String 用户Token,获取方法参见认证鉴权 表3 请求Body参数 参数 是否必选 参数类型 描述 name 是 String 边缘池名称。只能由小写字母(a~z)、数字(0~9)、中划线(-)组成,长度范围为[4,32]。需以小写字母开头,以小写字母或数字结尾。 description 否 String 作业的描述 最小长度:0 最大长度:255 ief_service_instance_id 否 String IEF的铂金版实例ID 最小长度:0 最大长度:255 nodes 是 Array of strings ief边缘节点数组 数组长度:1 - 10
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 total_count Integer 作业总数 failed_count Integer 失败作业数量 succeed_count Integer 成功作业数量 id String 批量作业id error_list Array of strings 错误信息列表 状态码: 400 表4 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议 状态码: 500 表5 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议
  • 响应示例 状态码: 200 视频源分组信息 { "video_group_id" : "xxxxxxx-xxxxxxx-xxxxxxx-xxxxx-xxxxxx", "video_group_name" : "test000", "description" : "", "access_type" : "cloud", "create_at" : 1680773327730, "modify_at" : 1680773463291, "num_video_source" : 2, "group_status" : { "num_online" : 2, "num_exception" : 0, "num_offline" : 0 }, "num_batch_task" : 0 }
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 video_group_id String 视频源所在分组id video_group_name String 视频源所在分组名称 description String 视频源所在分组描述 access_type String 接入方式(cloud、edge) create_at Long 创建时间 modify_at Long 修改时间 num_video_source Integer 视频源数量 group_status GroupStatusDto object 视频源状态 num_batch_task Integer 已配置批量作业数量 表4 GroupStatusDto 参数 参数类型 描述 num_online Integer 在线视频源数量 num_exception Integer 异常视频源数量 num_offline Integer 离线视频源数量
  • URI GET /v2/{project_id}/video-group/{video_group_id} 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 用户项目ID,获取方法参见获取项目ID和名称 video_group_id 是 String 视频源分组id,只能由小写英文字母(a~z)、数字(0~9)、中划线(-)、下划线(_)组成长度范围是[4,36]
  • 响应示例 状态码: 200 查询作业列表响应体 { "count" : 2, "tasks" : [ { "id" : "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "name" : "qqqq_task", "service_id" : "xxxxxxx-xxxxxxx-xxxxxxx-xxxxx-xxxxxx", "created_at" : "1686034773024", "state" : "PENDING", "video_source_name" : "url_test", "title" : "testwjh", "type" : "0", "algorithm_publish_id" : "xxxxxxx-xxxxxxx-xxxxxxx-xxxxx-xxxxxx" }, { "id" : "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "name" : "task_test1", "service_id" : "xxxxxxx-xxxxxxx-xxxxxxx-xxxxx-xxxxxx", "created_at" : "1686027880205", "state" : "STOPPED", "video_source_name" : "test_g11", "title" : "alg_test", "type" : "0", "algorithm_publish_id" : "xxxxxxx-xxxxxxx-xxxxxxx-xxxxx-xxxxxx" } ], "page" : 1, "page_size" : 10 }
  • URI GET /v2/{project_id}/tasks 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 用户项目ID,获取方法参见获取项目ID和名称 表2 Query参数 参数 是否必选 参数类型 描述 source_data_type 否 String 任务类型,用作查询过滤。仅支持async_task与sync_task两种类型。 title 否 String 算法中文名,需要满足正则表达式^[a-zA-Z0-9\u4e00-\u9fa5-_,]{2,64}$ camera_name 否 String 摄像头名称 最大长度:255 task_state 否 String 任务状态,状态可选PENDING|RECOVERING|STARTING|UPGRADING|CREATE_FAILED|START_FAILED|RUNNING|STOPPING|STOPPED|ABNORMAL|SUCCEEDED|FAILED|DELETING|FREEZING|FROZEN|SCHEDULING|LACK_OF_RESOURCES task_name 否 String 任务名称 最大长度:1024 page_size 否 Integer 每页显示的条目数量 最小值:5 最大值:1000 缺省值:10 page 否 Integer 偏移量 缺省值:1 sort_dir 否 String 展示服务任务时的排序规则 缺省值:desc batch_id 否 String 批量配置ID,需要满足正则表达式^[a-z0-9-_]{4,36}$ video_group_id 否 String 视频分组ID(多个ID英文逗号分隔拼接),长度要求[4,2048] company 否 String 厂商(多选时逗号分隔拼接) alg_id 否 String 算法ID,需要满足正则表达式^[0-9a-f]{8}-[0-9a-f]{4}-[4][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$
  • 响应参数 状态码: 200 表4 响应Body参数 参数 参数类型 描述 count Integer 当前页面的条目数 tasks Array of TaskInfo objects 查询到的任务列表信息 page Integer 当前页号 page_size Integer 分页尺寸 表5 TaskInfo 参数 参数类型 描述 id String 任务ID name String 任务的名称 service_id String 任务对应服务的ID created_at String 任务创建的时间 state String 任务当前的状态,分别为PENDING(等待中),RECOVERING(恢复中),STARTING(启动中),UPGRADING(升级中),CREATE_FAILED(创建失败),START_FAILED(启动失败),RUNNING(运行中),STOPPING(停止中),STOPPED(已停止),ABNORMAL(异常),SUCCEEDED(运行成功),FAILED(运行失败),DELETING(删除中),FREEZING(冻结中),FROZEN(已冻结) video_source_name String 视频源名称 title String 算法中文名称 type String 任务类型(0:云上任务 1:边缘任务) algorithm_publish_id String 算法id 状态码: 400 表6 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议 状态码: 500 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议
  • URI GET /v2/{project_id}/source/sources/{video_source_id} 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 用户项目ID,获取方法参见获取项目ID和名称 最大长度:64 video_source_id 是 String 已创建成功的视频源id,只能由小写英文字母(a~z)、数字(0~9)、中划线(-)、下划线(_)组成, 长度范围为[4, 36] 最大长度:36
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 video_source_name String 视频源名称,只支持中文、英文字母(a-z,A-Z)、数字、特殊字符(空格.-_() ()),不能以空格开头和结尾 最小长度:1 最大长度:100 access_type String 接入类型(cloud、edge) status VideoSourceStatusInfoDto object 数据源状态 type String 类型:obs、vcn、url、restful、camera latitude String 视频源的地理位置信息,纬度,-90.00000~90.00000 longitude String 视频源的地理位置信息,经度,-180.00000~180.00000 create_at Long 创建时间 type_config String 视频源配置信息xml video_packages Array of VideoGroupInfoDto objects 视频源所在分组 service_config_templates Array of VideoServiceConfigTemplateDto objects 算法模板体 stream_path String 流地址 image String 视频源截图的base64转码 tag Array of strings 视频源标签,标签最多选择4个,标签内容只能由中文, 英文字母(a~z, A~Z)、数字(0~9)、中划线(-)、下划线(_)组成, 最小长度:1 最大长度:10 scene_recommend Array of strings 智能算法推荐的标签 video_source_quality Array of strings 视频源的视频流质量: Blurry:画面模糊; ColorDistortion:画面颜色失真; AbnormalLight:画面光线异常; ScreenSplash:画面花屏异常; ScreenJitter:画面抖动; ScreenMovement:画面移动; SceneUpheaval:画面剧变; ScreenFreeze:画面冻结; BlackScreen:黑屏; SnowNoise:雪花噪声; Occlude:遮挡; GrayScreen:灰屏;ScreenSmudge:画面污迹 表4 VideoSourceStatusInfoDto 参数 参数类型 描述 status String 视频源状态 name String 状态中文名 level String 状态等级(用于前端图片颜色匹配) 表5 VideoGroupInfoDto 参数 参数类型 描述 video_group_id String 视频源所在分组id video_group_name String 视频源所在分组名称 description String 视频源所在分组描述 access_type String 接入方式(cloud、edge) create_at Long 创建时间 modify_at Long 修改时间 num_video_source Integer 视频源数量 group_status GroupStatusDto object 视频源状态 num_batch_task Integer 已配置批量作业数量 表6 GroupStatusDto 参数 参数类型 描述 num_online Integer 在线视频源数量 num_exception Integer 异常视频源数量 num_offline Integer 离线视频源数量 表7 VideoServiceConfigTemplateDto 参数 参数类型 描述 name String 算法服务名称 roi String 公共roi serviceConfig String 算法服务公共配置 createAt Long 创建时间 modifyAt Long 修改时间 numTask Integer 已运行算法数量 状态码: 400 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议 状态码: 500 表9 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议
  • 请求示例 修改配置名称为“wdwd”使用算法名为“烟火演示算法”版本为“1.0”厂商为“VIAS”不保存模板输入方式为“video_source”输出方式为“webhook”有相关算法配置的批量配置 /v2/{project_id}/batch-tasks/{id} { "name" : "wdwdxx", "service_name" : "烟火演示算法", "service_version" : "1.0", "manufacturer" : "VIAS", "priority" : "low", "is_saved_as_template" : false, "description" : "", "batch_input" : { "video_source_group" : [ { "video_source_group_id" : "xxxxxxx-xxxxxxx-xxxxxxx-xxxxx-xxxxxx", "video_source_list" : [ { "video_source_id" : "xxxxxxx-xxxxxxx-xxxxxxx-xxxxx-xxxxxx" } ] } ] }, "output" : { "webhook" : { "url" : "http://test", "headers" : { "a" : "a" } } }, "config" : { "common" : { "render_result_sw" : 1, "fire_detection_sw" : 1, "smoke_detection_sw" : 1 } } }
  • 响应参数 状态码: 200 表13 响应Body参数 参数 参数类型 描述 total_count Integer 作业总数 failed_count Integer 失败作业数量 succeed_count Integer 成功作业数量 id String 批量作业id error_list Array of strings 错误信息列表 状态码: 400 表14 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议 状态码: 500 表15 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议
  • 请求示例 部署算法,配置资源池ID、可承载的最大路数和服务启动参数 GET https://{endpoint}/v2/{project_id}/algorithm/068ed4d8-077e-4ec9-aa19-bc******e925/deploy { "pool_id" : "ed9f128bf7d04f5683f0ef******a255", "stream_count" : 1, "deploy_config" : { "sub_scene" : "common" } }
  • 响应示例 状态码: 200 边缘资源池详情响应体 { "id" : "xxx", "name" : "yundao2", "state" : "Running", "project_id" : "xxx", "workspace_id" : "0", "created_at" : 1683344661036, "updated_at" : 1683344661036, "nodes" : [ { "id" : "xxx", "name" : "测试边缘节点-2", "state" : "Running", "cpu" : 16, "arch" : "x86_64", "enable_gpu" : true, "enable_npu" : false, "memory" : 64263, "gpu_info" : [ { "name" : "gp0", "driver_version" : "418.67", "type" : "Tnt004", "capacity" : "15079Mi" } ], "npu_info" : [ ] } ] }
  • 响应参数 状态码: 200 表3 响应Body参数 参数 参数类型 描述 id String 边缘池ID name String 边缘池名称 description String 描述信息 state String 边缘池状态 project_id String 用户项目ID workspace_id String 工作空间ID created_at Long 创建时间 updated_at Long 更新时间 nodes Array of EdgeNodeInfoDto objects 边缘节点列表 表4 EdgeNodeInfoDto 参数 参数类型 描述 id String 边缘节点ID。 name String 边缘池名称。 description String 描述信息。描述为空则不返回该字段。 state String 边缘池状态 cpu Integer CPU核心数量。 arch String 计算机架构。 enable_gpu Boolean 是否使用GPU。 enable_npu Boolean 是否使用NPU。 memory Integer 内存大小。 gpu_info Array of GpuInfo objects GPU信息。 npu_info Array of NpuInfo objects NPU信息。 表5 GpuInfo 参数 参数类型 描述 name String GPU卡名称 driver_version String GPU卡驱动版本 type String GPU卡类型 capacity String GPU卡容量 表6 NpuInfo 参数 参数类型 描述 name String NPU卡名称 driver_version String NPU卡驱动版本 type String NPU卡类型 capacity String NPU卡容量 状态码: 400 表7 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议 状态码: 500 表8 响应Body参数 参数 参数类型 描述 error_code String 错误码 error_msg String 错误信息描述 detail String 错误详情 params Array of strings 错误参数列举 数组长度:0 - 1 reason String 错误原因 advice String 建议
  • 响应示例 状态码: 200 批量操作响应体 { "count" : 2, "batch_task_list" : [ { "id" : "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "batch_task_name" : "qqqq", "video_group_name" : "2312,1889,927,914", "alg_name" : "testwjh", "type" : "0", "priority" : "low", "num_task" : 3, "created_at" : 1685667905165, "batch_task_status_info" : { "stopped" : 3 } }, { "id" : "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", "batch_task_name" : "qqq", "video_group_name" : "2312", "alg_name" : "testwjh", "type" : "0", "priority" : "low", "num_task" : 1, "created_at" : 1685667856283, "batch_task_status_info" : { "running" : 1 } } ] }
  • URI GET /v2/{project_id}/batch-tasks 表1 路径参数 参数 是否必选 参数类型 描述 project_id 是 String 用户项目ID,获取方法参见获取项目ID和名称 表2 Query参数 参数 是否必选 参数类型 描述 is_paged 否 Boolean 是否分页 缺省值:true page_size 否 Integer 每页显示的条目数量 最小值:5 最大值:200 缺省值:10 page_num 否 Integer 页号 最小值:1 最大值:10000 缺省值:1 order_by 否 String 升序或降序,枚举值:asc|desc。 缺省值:desc sort_name 否 String 排序字段,枚举值:task_count|created_at。 缺省值:created_at video_group 否 String 视频源分组列表,多个以逗号分隔,需要满足正则:^[a-zA-Z0-9\u4e00-\u9fa5,-_]{1,1000}$ 最小长度:1 最大长度:1000 task_state 否 String 任务状态,需要枚举值:pending|recovering|starting|upgrading|create_failed|start_failed|running|stopping|stopped|abnormal|succeeded|failed|deleting|freezing|frozen|stopped_no_service|scheduling|lack_of_resources type_like 否 String 模糊查询字段,枚举值: batch_task_name|publish_service_name name_like 否 String 模糊查询名称,需要与type_like搭配使用来实现是通过batch_task_name还是publish_service_name进行模糊查询 最小长度:0 最大长度:100 manufacturer 否 String 根据厂商字段筛选,需要满足正则表达式 ^[a-zA-Z0-9\u4e00-\u9fa5,-_]{2,64}$ 最小长度:2 最大长度:64 title 否 String 算法中文名,需要满足正则表达式 ^[a-zA-Z0-9\u4e00-\u9fa5,-_]{2,64}$ 最小长度:2 最大长度:64
共100000条