You need to enable JavaScript to run this app.
导航
DescribeLiveBatchStreamTranscodeData - 查询直播流的转码数据
最近更新时间:2025.04.22 19:10:55首次发布时间:2023.09.25 14:36:38
我的收藏
有用
有用
无用
无用

调用 DescribeLiveBatchStreamTranscodeData 接口,查询指定时间范围内域名下所有转码流的转码时长、分辨率档位、编码方式等转码数据。

注意事项

  • 使用限制:支持查询指定域名(包含已删除域名)下,所有转码流的转码数据。
  • 请求频率:单用户请求频率限制为 30 次/秒
  • 数据延迟:数据延迟为 15 分钟

请求说明

  • 请求方式:POST
  • 请求地址:https://live.volcengineapi.com?Action=DescribeLiveBatchStreamTranscodeData&Version=2023-01-01

请求参数

下表仅列出该接口特有的请求参数和部分公共参数。更多信息请见公共参数

Query

参数类型是否必选示例值描述
ActionStringDescribeLiveBatchStreamTranscodeData接口名称。当前 API 的名称为 DescribeLiveBatchStreamTranscodeData
VersionString2023-01-01接口版本。当前 API 的版本为 2023-01-01

Body

参数类型是否必选示例值描述
DomainListArray of String["pull.example.com", "pull2.example.com"]域名列表,默认为空表示全部域名。您可以调用 ListDomainDetail 接口或在视频直播控制台的域名管理页面,获取直播流使用的域名信息。

StartTime

String

2022-11-10T00:00:00+08:00

查询的开始时间,RFC3339 格式的时间戳,精度为秒。

说明

查询历史数据的时间范围为 366 天。

EndTimeString2022-11-11T00:00:00+08:00查询的结束时间,RFC3339 格式的时间戳,精度为秒。
PageSizeInteger100每页显示的数据条数,默认值为 1000,取值范围为 [100,1000]。
PageNumInteger1查询数据的页码,默认值为 1,表示查询第一页的数据。

返回参数

下表仅列出本接口特有的返回参数。更多信息请见返回结构

参数类型示例值描述
DomainListArray of String["pull.example.com", "pull2.example.com"]域名列表。
StartTimeString2022-11-10T00:00:00+08:00查询的开始时间,RFC3339 格式的时间戳,精度为秒。
EndTimeString2022-11-11T00:00:00+08:00查询的结束时间,RFC3339 格式的时间戳,精度为秒。
TotalDurationFloat40.1当前查询条件下,所有流的转码总时长,单位为分钟。
StreamInfoListArray of StreamInfoList-流维度的转码用量信息详情。
PaginationObject of Pagination-数据分页的信息。

StreamInfoList

参数类型示例值描述
DomainStringpull.example.com域名。
AppStringlive应用名称。
StreamStringexample_stream流名称。

Resolution

String

720P

转码分辨率档位,以 720P 为例,表示转码配置的长边 x 短边计算而出的面积大于 480P(640 × 480)且小于等于 720P 档位(1280 x 720)。

  • 480P:640 × 480;
  • 720P:1280 × 720;
  • 1080P:1936 × 1088;
  • 2K:2560 × 1440;
  • 4K:4096 × 2160;
  • 8K:> 4096 x 2160
  • 0P:纯音频转码。
DurationFloat20.1当前流在查询时间内的转码总时长,单位为分钟。

VCodec

String

Normal_H264

视频编码格式,支持的取值和含义如下所示。

  • Normal_H264:H.264 标准转码;
  • Normal_H265:H.265 标准转码;
  • Normal_H266:H.266 标准转码;
  • ByteHD_H264:H.264 极智超清;
  • ByteHD_H265:H.265 极智超清;
  • ByteHD_H266:H.266 极智超清;
  • ByteQE:画质增强;
  • Audio:纯音频流;
CoderateInteger2000当前流的转码码率,单位为 kbps。

Pagination

参数类型示例值描述
PageNumInteger1当前所在分页的页码。
PageSizeInteger100每页展示的数据条数。
TotalCountInteger2查询结果的数据总条数。

请求示例

POST https://live.volcengineapi.com?Action=DescribeLiveBatchStreamTranscodeData&Version=2023-01-01
{
    "StartTime": "2022-11-10T00:00:00+08:00",
    "EndTime": "2022-11-11T00:00:00+08:00"
}

返回示例

{
  "ResponseMetadata":{
    "RequestId": "201806041104200100100232280022D30",
    "Action": "DescribeLiveBatchStreamTranscodeData",
    "Version": "2023-01-01",
    "Service": "live",
    "Region": "cn-north-1"
  },
  "Result":{
    "StartTime": "2022-11-10T00:00:00+08:00",
    "EndTime": "2022-11-11T00:00:00+08:00",
    "TotalDuration": 40,
    "StreamInfoList": [
      {
        "Domain": "pull.example.com"
        "Stream": "example_stream001",
        "App": "live",
        "Resolution": "720P",
        "Duration": 20,
        "VCodec": "Normal_H264"
      },
      {
        "Domain": "pull.example.com"
        "Stream": "example_stream002",
        "App": "live",
        "Resolution": "720P",
        "Duration": 20,
        "VCodec": "Normal_H264"
      }
    ],
    "Pagination": {
        "PageNum":    1,
        "PageSize":   1000,
        "TotalCount": 2,
    }
}

错误码

下表仅列出本接口特有的错误码。更多信息请参见公共错误码获取详细信息。

状态码错误码错误信息说明
400InvalidParam-输入的参数无效或不符合要求,请参照请求参数说明进行检查。
403RequestForbidden-请求被拒绝,当前账号下无请求的资源(域名空间、域名、应用、配置模版、证书)。
500InternalErroran internal error occurred, please contact the administrator.出现内部错误,请联系技术支持