查询频道统计信息 - ShowChannelStatistic
功能介绍
查询频道的统计信息(入流scte35信号)
授权信息
账号根用户具备所有API的调用权限,如果使用账号下的IAM用户调用当前API,该IAM用户需具备如下身份策略权限,更多的权限说明请参见权限和授权项。
授权项 | 访问级别 | 资源类型(*为必须) | 条件键 | 别名 | 依赖的授权项 |
|---|---|---|---|---|---|
live:ott:statistic | List | - | - | - | - |
URI
POST /v1/{project_id}/ott/channels/statistic
参数 | 是否必选 | 参数类型 | 描述 |
|---|---|---|---|
project_id | 是 | String | 参数解释: 项目ID,获取方法请参考获取项目ID。 约束限制: 不涉及 取值范围: [1,32] 默认取值: 不涉及 |
参数 | 是否必选 | 参数类型 | 描述 |
|---|---|---|---|
limit | 否 | Integer | 参数解释: 每页记录数 约束限制: 不涉及 取值范围: 1~100 默认取值: 10 |
offset | 否 | Integer | 参数解释: 偏移量。表示从此偏移量开始查询,offset大于等于0 约束限制: 不涉及 取值范围: 0~6553500 默认取值: 0 |
请求参数
参数 | 是否必选 | 参数类型 | 描述 |
|---|---|---|---|
X-Auth-Token | 否 | String | 参数解释: 用户Token,使用Token鉴权方式时为必填项。通过调用IAM服务获取用户Token接口获取(响应消息头中X-Subject-Token的值)。 约束限制: 不涉及 取值范围: [1,256] 默认取值: 不涉及 |
Authorization | 否 | String | 参数解释: 使用AK/SK方式认证时必填,携带的鉴权信息。 约束限制: 不涉及 取值范围: [1,256] 默认取值: 不涉及 |
X-Sdk-Date | 否 | String | 参数解释: 请求的发生时间,使用AK/SK方式认证时为必填项。 约束限制: 不涉及 取值范围: [1,256] 默认取值: 不涉及 |
X-Project-Id | 否 | String | 参数解释: 使用AK/SK方式认证时为必填项,携带项目ID信息。 约束限制: 不涉及 取值范围: [1,64] 默认取值: 不涉及 |
参数 | 是否必选 | 参数类型 | 描述 |
|---|---|---|---|
domain | 是 | String | 参数解释: 频道推流域名 约束限制: 不涉及 取值范围: 限制[1~255]个字符长度 默认取值: 不涉及 |
app_name | 是 | String | 参数解释: 组名或应用名 约束限制: 不涉及 取值范围: 限制[1~64]个字符长度 默认取值: 不涉及 |
id | 是 | String | 参数解释: 频道ID 约束限制: 不涉及 取值范围: 限制[2~64]个字符长度 默认取值: 不涉及 |
type | 是 | String | 参数解释: 统计信息的类型 约束限制: 不涉及 取值范围: 默认取值: 不涉及 |
scte35 | 否 | SCTE35StatisticReq object | 参数解释: 请求频道scte35信号的字段 约束限制: 不涉及 |
region_type | 否 | String | 参数解释: 频道对应的region类型,是主region,还是备region 约束限制: 如果region_type不填,或是没有该字段,则按照主region处理 取值范围: 默认取值: master |
响应参数
状态码:200
参数 | 参数类型 | 描述 |
|---|---|---|
domain | String | 参数解释: 频道推流域名 取值范围: 限制[1~255]个字符长度 |
app_name | String | 参数解释: 组名或应用名 取值范围: 限制[1~64]个字符长度 |
id | String | 参数解释: 频道ID 取值范围: 限制[2~64]个字符长度 |
type | String | 参数解释: 统计信息的类型 取值范围: |
scte35 | SCTE35StatisticRsp object | 参数解释: 获取SCTE35信号的响应体 |
参数 | 参数类型 | 描述 |
|---|---|---|
total | Integer | 参数解释: 查询到scet35信息的总个数 取值范围: 1~2147483648 |
scte35_info | Array of SCTE35InfoItem objects | 参数解释: 详细的scte35信号的数组 |
参数 | 参数类型 | 描述 |
|---|---|---|
type | String | 参数解释: 信号类型 取值范围: |
event_id | Integer | 参数解释: 广告信号的Event ID,Time Signal打印数组第一个 取值范围: 1~2147483648 |
start_date | Long | 参数解释: 广告信号的执行时间,unix time,单位:秒 取值范围: 1~4294967295 |
duration | Integer | 参数解释: 广告信号时长,-1表示没有携带;单位:秒 取值范围: -1~2147483648 |
segmentation_type | String | 参数解释: 分割类型;Splice Insert填空"-";Time Signal,支持0x30,0x31,0x32,0x33,0x34,0x35,0x36,0x37 取值范围: |
base64_data | String | 参数解释: 广告信号原始数据的base64值 取值范围: 限制[1~1024]个字符长度 |
raw_splice | String | 参数解释: 广告信号全量信息 取值范围: 限制[1~8096]个字符长度 |
region_type | String | 参数解释: 该广告信号对应的region类型,是主region,还是备region 取值范围: |
region | String | 参数解释: 该广告信号对应的region区域 取值范围: 华为云的region |
状态码:404
请求示例
POST https://{endpoint}/v1/{project_id}/ott/channels/statistic?limit=50&offset=10
{
"domain" : "www.huaweiott.pushdomain.com",
"app_name" : "live",
"id" : "channelId",
"type" : "scte35",
"region_type" : "master",
"scte35" : {
"type" : "all",
"start_time" : 1741650609,
"end_time" : 1741658609
}
} 响应示例
状态码:200
Query success response
{
"domain" : "www.huaweiott.pushdomain.com",
"app_name" : "live",
"id" : "channelId",
"type" : "scte35",
"scte35" : {
"total" : 50,
"scte35_info" : [ {
"type" : "Splice Insert",
"event_id" : 100,
"start_date" : 1741594376,
"duration" : 120,
"region_type" : "master",
"region" : "me-east-1",
"segmentation_type" : "Provider advertisement Start",
"base64_data" : "/DAlAAAAAAAAAP/wFAUAAAABf+/+AGAhYP4AKTLgAAEAAAAAjhdvmA==",
"raw_splice" : "{\"table_id\":252,\"section_syntax_indicator\":false,\"private_indicator\":false,\"section_length\":32,\"protocol_version\":0,\"encrypted_packet\":false,\"encryption_algorithm\":0,\"pts_adjustment\":0,\"cw_index\":0,\"tier\":0,\"splice_command_length\":15,\"splice_command_type\":\"Splice Insert\",\"splice_command\":{\"splice_event_id\":9,\"splice_event_cancel_indicator\":false,\"out_of_network_indicator\":false,\"program_splice_flag\":true,\"duration_flag\":false,\"splice_immediate_flag\":false,\"splice_time\":{\"time_specified_flag\":true,\"pts_time\":429850800},\"unique_program_id\":0,\"avail_num\":0,\"avails_expected\":0},\"descriptor_loop_length\":0,\"descriptors\":[],\"crc32\":2510451559}"
}, {
"type" : "Splice Insert",
"event_id" : 101,
"start_date" : 1741594378,
"duration" : 120,
"region_type" : "slave",
"region" : "ap-southeast-3",
"segmentation_type" : "Provider advertisement Start",
"base64_data" : "/DAlAAAAAAAAAP/wFAUAAAABf+/+AGAhYP4AKTLgAAEAAAAAjhdvmA==",
"raw_splice" : "{\"table_id\":252,\"section_syntax_indicator\":false,\"private_indicator\":false,\"section_length\":32,\"protocol_version\":0,\"encrypted_packet\":false,\"encryption_algorithm\":0,\"pts_adjustment\":0,\"cw_index\":0,\"tier\":0,\"splice_command_length\":15,\"splice_command_type\":\"Splice Insert\",\"splice_command\":{\"splice_event_id\":9,\"splice_event_cancel_indicator\":false,\"out_of_network_indicator\":false,\"program_splice_flag\":true,\"duration_flag\":false,\"splice_immediate_flag\":false,\"splice_time\":{\"time_specified_flag\":true,\"pts_time\":429850800},\"unique_program_id\":0,\"avail_num\":0,\"avails_expected\":0},\"descriptor_loop_length\":0,\"descriptors\":[],\"crc32\":2510451559}"
} ]
}
} 状态码:404
Query failed response
{
"error_code" : "LIVE.103011099",
"error_msg" : "query channel statistic failed"
} 状态码
状态码 | 描述 |
|---|---|
200 | Query success response |
404 | Query failed response |
错误码
请参见错误码。

