You need to enable JavaScript to run this app.
导航
获取工作流模板列表
最近更新时间:2023.08.04 11:00:30首次发布时间:2023.07.04 21:04:35
我的收藏
有用
有用
无用
无用

此接口用于获取工作流模板列表。

请求说明

  • 接口名称:ListWorkflowTemplate
  • 接口地址:https://vod.volcengineapi.com?Action=ListWorkflowTemplate&Version=2023-07-01

请求参数

参数类型是否必选描述
ActionString接口名称。当前接口取值为 ListWorkflowTemplate
VersionString接口版本。当前接口取值为 2023-07-01

SpaceName

String

点播空间名称。可通过以下方式获取空间名称:

  • 在视频点播控制台空间管理页面查看当前账号下所有空间的名称。
  • 调用 ListSpace 接口获取当前账号下所有空间的名称。
TemplateIdString模板 ID。
NameString模板名称。
Limitint32返回个数。取值范围为 (0,100]。默认为 30。
Offsetint32偏移量。需大于等于 0。

OrderByKey

String

排序 key。取值如下:

  • created_at:创建时间。

  • updated_at:更新时间。

Order

String

顺序。取值如下:

  • desc:降序。

  • asc:升序。

返回参数

参数类型描述
ResponseMetadataResponseMetadata响应通用信息
ResultVodListWorkflowTemplateResult响应结果

ResponseMetadata

参数类型描述
RequestIdString请求 ID
ActionString请求接口
VersionString版本
ServiceString服务
RegionString区域
ErrorResponseError异常信息

ResponseError

参数类型描述
CodeString错误码
MessageString详细错误信息

VodListWorkflowTemplateResult

参数类型描述
Limitint32返回个数。
Offsetint32偏移量。
Totalint64(Json中为String)工作流模板总数。
DataArray of WorkflowTemplate工作流模板信息。

WorkflowTemplate

参数类型描述
TemplateIdString工作流模板 ID。
SpaceNameString空间名称。
NameString工作流名称。
DescriptionString工作流描述。
CreatedAtString创建时间。
UpdatedAtString更新时间。
CommitIdString版本 ID。
ActivitiesArray of Activity工作流节点。

示例

请求示例

http://vod.volcengineapi.com?Action=ListWorkflowTemplate&Version=2023-07-01&SpaceName=YourSpaceName&TemplateId=YourTemplateId&Name=YourName&Limit=YourLimit&Offset=YourOffset&OrderByKey=YourOrderByKey&Order=YourOrder

正常返回示例

{
    "ResponseMetadata": {
        "RequestId": "20220726*******************051B513A",
        "Action": "ListWorkflowTemplate",
        "Version": "2023-07-01",
        "Service": "vod",
        "Region": "cn-north-1"
    },
        "Result": {
                "Limit": 1,
                "Offset": 1,
                "Total": "Total",
                "Data": [{
                                "TemplateId": "TemplateId",
                                "SpaceName": "SpaceName",
                                "Name": "Name",
                                "Description": "Description",
                                "CreatedAt": "2022-04-18T20:00:00Z",
                                "UpdatedAt": "2022-04-18T22:00:00Z",
                                "CommitId": "CommitId",
                                "Activities": [{
                                                "ActivityId": "ActivityId",
                                                "Name": "Name",
                                                "Description": "Description",
                                                "Type": "Type",
                                                "SnapshotActivity": {
                                                        "TemplateId": "TemplateId",
                                                        "FileName": "FileName",
                                                        "Condition": {
                                                                "ResRange": "ResRange",
                                                                "LongResRange": "LongResRange",
                                                                "DurationRange": "DurationRange",
                                                                "FpsRange": "FpsRange",
                                                                "BitrateRange": "BitrateRange",
                                                                "AudioBitrateRange": "AudioBitrateRange",
                                                                "FileType": "FileType",
                                                                "VQScoreRange": "VQScoreRange",
                                                                "VideoDurationRange": "VideoDurationRange",
                                                                "AudioDurationRange": "AudioDurationRange",
                                                                "UserCondition": "UserCondition"
                                                        }
                                                },
                                                "EndActivity": {
                                                        "TranscodeEvent": "TranscodeEvent"
                                                },
                                                "TranscodeActivity": {
                                                        "TemplateId": "TemplateId",
                                                        "Logo": {
                                                                "TemplateId": "TemplateId"
                                                        },
                                                        "FileName": "FileName",
                                                        "Condition": {
                                                                "ResRange": "ResRange",
                                                                "LongResRange": "LongResRange",
                                                                "DurationRange": "DurationRange",
                                                                "FpsRange": "FpsRange",
                                                                "BitrateRange": "BitrateRange",
                                                                "AudioBitrateRange": "AudioBitrateRange",
                                                                "FileType": "FileType",
                                                                "VQScoreRange": "VQScoreRange",
                                                                "VideoDurationRange": "VideoDurationRange",
                                                                "AudioDurationRange": "AudioDurationRange",
                                                                "UserCondition": "UserCondition"
                                                        }
                                                }
                                        }
                                ]
                        }
                ]
        }
}

异常返回示例

{
    "ResponseMetadata": {
        "RequestId": "20220726*******************051B513A",
        "Action": "ListWorkflowTemplate",
        "Version": "2023-07-01",
        "Service": "vod",
        "Region": "cn-north-1",
        "Error": {
            "Code": "InternalError",
            "Message": "InternalError:some error!"
        }
    }
}

错误码

详见视频点播公共错误码

服务端 SDK

点播 OpenAPI 提供了配套的服务端 SDK,支持多种编程语言,帮助您实现快速开发。建议使用服务端 SDK 来调用 API,此 API 各语言调用的示例代码,请参考如下: