You need to enable JavaScript to run this app.
文档中心
智能视联

智能视联

复制全文
下载 pdf
视频流管理
GetStream - 查看视频流
复制全文
下载 pdf
GetStream - 查看视频流

查询指定视频流的详细信息。

请求说明

  • 请求方式:GET
  • 请求地址:https://open.volcengineapi.com?Action=GetStream&Version=2021-01-01

调试

请求参数

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

参数
类型
是否必填
示例值
描述
Action
String

GetStream

要执行的操作,取值:GetStream。

Version
String

2021-01-01

API的版本,取值:2021-01-01。

StreamingIndex
String

1

主子码流

SpaceID
String

spaceidxxxxuuid

空间ID

StreamID
String

4b9ee060-9fed-4c0e-aaa4-283b17xxxxxx

筛选条件,视频流 ID,可通过调用 ListStreams 接口获取

StreamName
String

demo stream

筛选条件,视频流名称,

FreshExpiredPull
String

1

是否刷新过期的拉流地址,如果设置为1,会判断拉流地址是否过期(拉流域名开启防盗链);如果过期,会刷新拉流地址

FreshExpiredPush
String

0

是否刷新过期的推流流地址,如果设置为1,会判断推流地址是否过期(推流域名开启防盗链);如果过期,会刷新推流地址

返回参数

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

参数
类型
示例值
描述
PushUrl
String

http://push_domain/push_stream_name

推流地址

SpaceID
String

517ff7ec-7700-4862-b1e7-7967a4xxxxxx

视频流所属空间 ID

SIPID
String

34020000002000xxxxxx

SIP 服务器 ID

StreamName
String

34020033991320xxxxxx_34020033991320384963

视频流名称

StreamID
String

4b9ee060-9fed-4c0e-aaa4-283b17xxxxxx

视频流 ID

SpaceAccessType
String

gb28181

视频流所属空间类型:

  • rtmp
  • gb28181
  • rtmp-forward
Status
String

online

视频流状态:

  • online:在线
  • offline:离线
  • failed:失败
  • pulling:拉流中
  • init:初始化
DeviceID
String

0a32c128-c89c-4f39-aa60-66e5f1xxxxxx

视频流所属设备 ID,RTMP 类型为空

DeviceNSID
String

34020033991320xxxxxx

视频流所属设备国标 ID,RTMP 类型为空

ChannelID
String

34020033991320xxxxxx

视频流所属设备通道 ID,RTMP 类型为空

StreamingType
String

main_stream

视频流类型:

  • main_stream:主码流
  • sub_stream:子码流
Description
String

channel: 34020033991320xxxxxx@device: 34020033991320xxxxxx

视频流描述

Screenshot
Object

为视频流配置的截图模板,参考以下 Template 数据结构说明

Record
Object

为视频流配置的录制模板,参考以下 Template 数据结构说明

AI
Object

为视频流配置的 AI 模板,参考以下 Template 数据结构说明

RecentPushTs
String

2021-11-30T17:07:35+08:00

最近推流时间

CreatedAt
String

2023-06-13T16:20:28+08:00

视频流创建时间

UpdatedAt
String

2023-06-13T16:22:28+08:00

视频流更新时间

RTMPushUrl
String

https://xxx-push.xx/xxx.sdp?Time=123&Secret=xxx

推流地址

PullUrls
Array of String

["rtmp://m8v21xhnuzxxxxxx.pull.xxx.com/xxx/xxx_xxx_xxx","https://prcldt8wqxxxxxx.pull.xxx.com/xxx.flv","https://prcldt8wqxxxxxx.pull.xxx.com/xxx.m3u8"]

拉流地址

TransPullUrls
Object

转封装拉流地址

RtpTransportTcp
Boolean

true

GB空间使用,流媒体传输是否使用 TCP 协议:

  • true:是
  • false:否
Resolution
String

6

GB空间使用,通道支持的分辨率列表:

  • 1(QCIF - 176x144)
  • 2(CIF - 320x288)
  • 3(4CIF - 704x576)
  • 4(D1 - 720x576)
  • 5(720p)
  • 6(1080p/i)
  • 其他(自定义宽高,如19201080等,需设备支持)
PullSource
String

http://pull_host/pull_stream_name

拉流空间使用,拉流的拉流地址

请求示例

GET https://open.volcengineapi.com?Action=GetStream&Version=2021-01-01&StreamID=4b9ee060-9fed-4c0e-aaa4-283b17xxxxxx&StreamName=&FreshExpiredPull=1

返回示例

{
  "ResponseMetadata": {
    "RequestId": "202405161415323611B09E71B9FF693CA5",
    "Action": "GetStream",
    "Version": "2021-01-01",
    "Service": "aiotvideo",
    "Region": "cn-north-1"
  },
  "Result": {
    "SpaceID": "af991768-856e-4c99-94c0-e8476dcb2896",
    "StreamName": "zxvxzbg",
    "StreamID": "2b49c3b4-31c6-4f48-b3f7-def75c198949",
    "SpaceAccessType": "rtmp",
    "Status": "offline",
    "StreamingType": "main_stream",
    "Screenshot": {
      "TemplateName": "",
      "TemplateID": "",
      "ApplyAll": null
    },
    "Record": {
      "TemplateName": "",
      "TemplateID": "",
      "ApplyAll": null
    },
    "AI": {
      "TemplateName": "",
      "TemplateID": "",
      "ApplyAll": null
    },
    "CreatedAt": "2024-04-25T17:44:27+08:00",
    "UpdatedAt": "2024-05-16T14:13:06+08:00",
    "PushUrl": "rtmp://lk9xvv3rvwgin59l.fcdn-boe-push.byted.org/kiizphpla00yfzmg/zxvxzbg?volcSecret=e0de2b3b67f392b23f44c7ab9841fa34&volcTime=1716444786",
    "RTMPushUrl": "https://lk9xvv3rvwgin59l.fcdn-boe-push.byted.org/kiizphpla00yfzmg/zxvxzbg.sdp?volcSecret=e0de2b3b67f392b23f44c7ab9841fa34&volcTime=1716444786",
    "PullUrls": [
      "rtmp://lk9xvv3rvwgin59l.fcdn-boe-pull.byted.org/kiizphpla00yfzmg/zxvxzbg",
      "https://lk9xvv3rvwgin59l.fcdn-boe-pull.byted.org/kiizphpla00yfzmg/zxvxzbg.flv",
      "https://lk9xvv3rvwgin59l.fcdn-boe-pull.byted.org/kiizphpla00yfzmg/zxvxzbg/index.m3u8",
      "https://lk9xvv3rvwgin59l.fcdn-boe-pull.byted.org/kiizphpla00yfzmg/zxvxzbg.sdp"
    ],
    "RecentPushTs": "2024-04-29T14:21:19+08:00",
    "Logs": null
  }
}

错误码

下表为您列举了该接口与业务逻辑相关的错误码。公共错误码请参见公共错误码文档。

状态码
错误码
错误信息
说明
400
InvalidParameter.StreamQueryArg

The request is failed due to get "http://live.volcengineapi.com/?action=describelivestreamstate&app=ford-prod&domain=streampull-transparent-showroom.changanford.cn&stream=cd-fuanda-ford_fc8271945&version=2023-01-01&vhost=dk51njy4w2lhx2r6.push.aiotvideo.volces.com": context deadline exceeded.

400
MissingParameterGetStream

MissingParameter.GetStream

500
NotFound.StreamService

The request is failed due to stream db.

500
InternalError.StreamDeleted

The request is failed due to stream deleted.

最近更新时间:2025.06.16 17:00:38
这个页面对您有帮助吗?
有用
有用
无用
无用