All Products
Search
Document Center

ApsaraVideo Live:DescribeLiveStreamsOnlineList

Last Updated:Nov 14, 2024

Queries the information about all active streams under a specified domain name or the active streams of an application under a specified domain name.

Operation description

You can call this operation to query the following types of streams.

  • all: all streams.
  • raw: source streams.
  • trans: transcoded streams.

QPS limit

You can call this operation up to 10,000 times per minute per account. Requests that exceed this limit are dropped and you will experience service interruptions. We recommend that you take note of this limit when you call this operation. For more information, see QPS limit on an API operation in ApsaraVideo Live.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
live:DescribeLiveStreamsOnlineListget
*All Resources
*
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
DomainNamestringYes

The main streaming domain.

example.com
AppNamestringNo

The name of the application to which the live stream belongs.

liveApp****
StreamNamestringNo

The name of the live stream. You can specify only one live stream.

liveStream****
OnlyStreamstringNo

Specifies whether to return only specific parameters. Valid values:

  • yes: returns only the DomainName, AppName, StreamName, and PublishTime parameters.
  • no: returns all parameters. This is the default value.
no
PageSizeintegerNo

The number of entries per page. Valid values: 1 to 3000. Default value: 2000.

1500
PageNumintegerNo

The page number. Default value: 1.

1
StreamTypestringNo

The type of the streams to query. Valid values:

  • all (default): all streams
  • raw: source streams
  • trans: transcoded streams
all
QueryTypestringNo

The mode in which stream names are matched. Valid values:

  • fuzzy (default): fuzzy match
  • strict: exact match
fuzzy

Response parameters

ParameterTypeDescriptionExample
object

The information about active streams.

RequestIdstring

The ID of the request.

5c6a2a0df228-4a64- af62-20e91b9676b3
TotalPageinteger

The total number of pages returned.

2
PageNuminteger

The page number of the returned page.

1
PageSizeinteger

The number of entries returned per page.

10
TotalNuminteger

The total number of streams that meet the specified conditions.

11
OnlineInfoarray<object>

The information about the live streams that are being ingested.

LiveStreamOnlineInfoobject

The information about the live stream that is being ingested.

AudioDataRateinteger

The audio bitrate of the live stream. Unit: Kbit/s.

600
FrameRateinteger

The frame rate. Unit: FPS.

15
PublishUrlstring

The complete URL that was used to ingest the stream.

rtmp://demo.aliyundoc.com/live/test****
StreamNamestring

The name of the live stream.

liveStream****
AudioCodecIdinteger

The ID of the audio codec.

10
Heightinteger

The height of the video resolution. Unit: pixels.

720
VideoDataRateinteger

The video bitrate of the live stream. Unit: Kbit/s.

600
DomainNamestring

The main streaming domain.

example.com
PublishDomainstring

The ingest domain. If live center ingest was used, the streaming domain is returned.

demo.aliyundoc.com
PublishTimestring

The start time of stream ingest. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC.

2021-08-09T02:37:59Z
AppNamestring

The name of the application to which the live stream belongs.

liveApp****
PublishTypestring

The ingest type. Valid values:

  • edge: edge ingest.
  • center: live center ingest.
edge
VideoCodecIdinteger

The ID of the video codec.

7
Transcodedstring

Indicates whether the stream was transcoded. Valid values:

  • yes
  • no
no
Widthinteger

The width of the video resolution. Unit: pixels.

1280
ClientIpstring

The IP address of the client for stream ingest.

106.11.XX.XX
ServerIpstring

The IP address of the ingest node.

120.221.XX.XX

Examples

Sample success responses

JSONformat

{
  "RequestId": "5c6a2a0df228-4a64- af62-20e91b9676b3",
  "TotalPage": 2,
  "PageNum": 1,
  "PageSize": 10,
  "TotalNum": 11,
  "OnlineInfo": {
    "LiveStreamOnlineInfo": [
      {
        "AudioDataRate": 600,
        "FrameRate": 15,
        "PublishUrl": "rtmp://demo.aliyundoc.com/live/test****",
        "StreamName": "liveStream****",
        "AudioCodecId": 10,
        "Height": 720,
        "VideoDataRate": 600,
        "DomainName": "example.com",
        "PublishDomain": "demo.aliyundoc.com",
        "PublishTime": "2021-08-09T02:37:59Z",
        "AppName": "liveApp****",
        "PublishType": "edge",
        "VideoCodecId": 7,
        "Transcoded": "no",
        "Width": 1280,
        "ClientIp": "106.11.XX.XX",
        "ServerIp": "120.221.XX.XX"
      }
    ]
  }
}

Error codes

HTTP status codeError codeError message
400QpsOverLimitQps is over limit for this domainName.
400InvalidStartTime.MalformedSpecified StartTime is malformed.
400InvalidEndTime.MalformedSpecified EndTime is malformed.
400InvalidEndTime.MismatchSpecified end time does not match the specified start time.
400Duration.ExceedDuration between StartTime and EndTime is too long.

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2024-08-01The Error code has changed. The request parameters of the API has changed. The response structure of the API has changedView Change Details
2024-07-11API Description Update. The Error code has changed. The request parameters of the API has changed. The response structure of the API has changedView Change Details
2024-01-26The Error code has changed. The response structure of the API has changedView Change Details