Queries stream-level batch data for a specified streaming domain. Multiple protocols are supported.
Operation description
Querying new connections for the HLS protocol is not supported. Concurrent connections for HLS are counted based on requests in the default format. Requests in special formats require configuration by submit a ticket. The default formats are as follows:
m3u8 request example: http(s)://example.aliyundoc.com/Appname/ StreamName.m3u8
ts request example: http(s)://example.aliyundoc.com/Appname/ StreamName/153xxxxxxxx_137xxxxx.ts.
Settings
Single query limit: A maximum of 5000 rows of data can be returned per query.
Domain name query limit: Only a single domain name is supported. An error is returned if multiple domain names are specified.
Time span limit: The maximum query time span is 24 hours.
Time granularity limit: The minimum query granularity is 1 minute.
Query range limit: The maximum query range is 31 days.
Call frequency limit: The maximum call frequency per user is 10 calls per second.
Special parameter combination: When
DomainNameis not empty and bothAppNameandStreamNameare set toall, the aggregate data for the streaming domain is returned.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
live:DescribeLiveUserStreamMetricData |
none |
*All Resource
|
None | None |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| DomainName |
string |
No |
The streaming domain to query. Note
Only a single domain name is supported. An error is returned if multiple domain names are specified. If the domain name is empty, aggregate data for all streaming domains under the user is queried. If |
test.com |
| StartTime |
string |
Yes |
The beginning of the time range to query. Specify the time in the ISO 8601 standard in the |
2015-12-10T20:00:00Z |
| EndTime |
string |
Yes |
The end of the time range to query. The end time must be later than the start time and the difference cannot exceed 1 day. Specify the time in the ISO 8601 standard in the |
2015-12-10T21:00:00Z |
| AppName |
string |
No |
The application name. Specify the application name to query stream-level data for the corresponding application. If |
app |
| StreamName |
string |
No |
The stream name. If |
test.flv |
| Protocol |
string |
No |
The stream protocol name. Specify the protocol name to query data for the corresponding protocol. Supported protocols: Note
The rts option queries Real-Time Streaming (RTS) streams using the ARTC protocol.
|
flv |
| PageNumber |
integer |
Yes |
The page number. |
1 |
| PageSize |
integer |
Yes |
The number of entries per page. Maximum value: 5000. |
10 |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
Schema of Response |
||
| DomainName |
string |
The streaming domain information. |
test.com |
| EndTime |
string |
YYYY-MM-DDThh:mm:ssZ |
2015-12-10T21:00:00Z |
| PageSize |
integer |
The number of entries per page. |
10 |
| RequestId |
string |
The request ID. |
16A96B9A-F203-4EC5-8E43-CB92E68F**** |
| StartTime |
string |
The beginning of the time range to query. The time is in the ISO 8601 standard in the |
2015-12-10T20:00:00Z |
| StreamDetailData |
array<object> |
The traffic data for each time interval. |
|
|
object |
The returned data group. |
||
| AppName |
string |
The application name. This value is returned regardless of whether it is specified. |
app |
| Bps |
number |
The total bandwidth per minute for the stream, in bps. |
423304182.66 |
| Count |
integer |
The total number of concurrent connections per minute for the stream. Note
Concurrent connections refers to the count of client process connections to the same stream within a unit of time. |
423304182 |
| FlvBps |
number |
The bandwidth for the FLV protocol, in bps. This field is not returned if the specified protocol does not match. |
454 |
| FlvCount |
integer |
The number of concurrent connections for the FLV protocol. This field is not returned if the specified protocol does not match. |
32 |
| FlvTraffic |
number |
The traffic for the FLV protocol, in bytes. This field is not returned if the specified protocol does not match. |
1254 |
| HlsBps |
number |
The bandwidth for the HLS protocol, in bps. This field is not returned if the specified protocol does not match. |
4456 |
| HlsCount |
integer |
The number of concurrent connections for the HLS protocol. This field is not returned if the specified protocol does not match. |
56 |
| HlsTraffic |
number |
The traffic for the HLS protocol, in bytes. This field is not returned if the specified protocol does not match. |
568 |
| NewConns |
integer |
The number of new connections per minute for the stream. |
450 |
| P2pBps |
number |
The bandwidth for the P2P protocol, in bps. This field is not returned if the specified protocol does not match. |
6845 |
| P2pCount |
integer |
The number of concurrent connections for the P2P protocol. This field is not returned if the specified protocol does not match. |
78 |
| P2pTraffic |
number |
The traffic for the P2P protocol, in bytes. This field is not returned if the specified protocol does not match. |
4102 |
| RtmpBps |
number |
The bandwidth for the RTMP protocol, in bps. This field is not returned if the specified protocol does not match. |
3323 |
| RtmpCount |
integer |
The number of concurrent connections for the RTMP protocol. This field is not returned if the specified protocol does not match. |
63 |
| RtmpTraffic |
number |
The traffic for the RTMP protocol, in bytes. This field is not returned if the specified protocol does not match. |
5568 |
| RtsBps |
number |
The bandwidth for the RTS protocol, in bps. This field is not returned if the specified protocol does not match. |
2361 |
| RtsCount |
integer |
The number of concurrent connections for the RTS protocol. This field is not returned if the specified protocol does not match. |
89 |
| RtsTraffic |
number |
The traffic for the RTS protocol, in bytes. This field is not returned if the specified protocol does not match. |
2322 |
| StreamName |
string |
The stream name. This value is returned regardless of whether it is specified. |
test.flv |
| TimeStamp |
string |
The start time of the time slice. The time is in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format in UTC+0. |
2015-12-10T20:00:00Z |
| Traffic |
number |
The total traffic per minute for the stream, in bytes. |
423304182 |
| TotalCount |
integer |
The total number of entries. |
50 |
| PageNumber |
integer |
The page number. |
1 |
Examples
Success response
JSON format
{
"DomainName": "test.com",
"EndTime": "2015-12-10T21:00:00Z",
"PageSize": 10,
"RequestId": "16A96B9A-F203-4EC5-8E43-CB92E68F****",
"StartTime": "2015-12-10T20:00:00Z",
"StreamDetailData": [
{
"AppName": "app",
"Bps": 423304182.66,
"Count": 423304182,
"FlvBps": 454,
"FlvCount": 32,
"FlvTraffic": 1254,
"HlsBps": 4456,
"HlsCount": 56,
"HlsTraffic": 568,
"NewConns": 450,
"P2pBps": 6845,
"P2pCount": 78,
"P2pTraffic": 4102,
"RtmpBps": 3323,
"RtmpCount": 63,
"RtmpTraffic": 5568,
"RtsBps": 2361,
"RtsCount": 89,
"RtsTraffic": 2322,
"StreamName": "test.flv",
"TimeStamp": "2015-12-10T20:00:00Z",
"Traffic": 423304182
}
],
"TotalCount": 50,
"PageNumber": 1
}
Error codes
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | Meter.ParamError | Param Error:%s,Please Check Again. | |
| 500 | Meter.ServerInternalError | The Request Processing Has Failed Due To Some Unknown Error. | |
| 500 | Meter.DataSourceQueryError | Data Source Error:%s,Please Try Again. | |
| 403 | Meter.AuthError | Authentication Failed,Please Try Again. | |
| 502 | Meter.ReadyTsError | Get ReadyTs Failed,Please Try Again. |
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.