Mengkueri data batch tingkat stream untuk nama domain yang ditentukan. Maksimum 5.000 baris data dapat dikembalikan per kueri.
Deskripsi operasi
Jika ini pertama kalinya Anda menggunakan operasi ini untuk mengkueri data tingkat stream untuk nama domain yang ditentukan, ajukan tiket untuk meminta konfigurasi backend sebelum menggunakan operasi ini. Berikan informasi berikut dalam tiket:
Nama domain yang akan dikueri.
Jumlah maksimum live stream bersamaan di bawah nama domain.
Jumlah maksimum penonton bersamaan per live stream.
Jenis protokol yang termasuk dalam permintaan klien.
Sebelum Anda memulai
-
Penghitungan penonton online untuk HLS tidak didukung secara default.
-
Hanya satu nama domain yang dapat dikueri pada satu waktu.
-
Rentang waktu kueri besar maksimum: 24 jam.
-
Granularitas kueri minimum: 1 menit.
-
Rentang kueri maksimum: 31 hari.
Batas laju
Batas QPS pengguna tunggal untuk operasi ini adalah 10 panggilan per detik. Jika batas ini terlampaui, panggilan API akan dibatasi, yang dapat memengaruhi bisnis Anda. Panggil operasi ini dengan tepat.
Coba sekarang
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
live:DescribeLiveStreamMetricDetailData |
none |
*Domain
|
None | None |
Parameter permintaan
|
Parameter |
Type |
Required |
Description |
Example |
| RegionId |
string |
No |
ID region. Valid values:
|
cn-shenzhen |
| DomainName |
string |
No |
|
example.com |
| StartTime |
string |
Yes |
Awal rentang waktu yang akan dikueri. Tentukan waktu dalam standar ISO 8601 dengan format YYYY-MM-DDThh:mm:ssZ. Waktu harus dalam UTC. |
2015-12-10T20:00:00Z |
| EndTime |
string |
Yes |
Akhir rentang waktu yang akan dikueri. Waktu akhir harus lebih lambat dari waktu mulai, dan selisihnya tidak boleh melebihi 1 hari. Tentukan waktu dalam standar ISO 8601 dengan format YYYY-MM-DDThh:mm:ssZ. Waktu harus dalam UTC. |
2015-12-10T21:00:00Z |
| AppName |
string |
No |
Nama aplikasi. Tentukan parameter ini untuk mengkueri data tingkat stream untuk aplikasi tertentu. Catatan
Jika Anda menentukan StreamName, Anda juga harus menentukan AppName. |
liveApp**** |
| StreamName |
string |
No |
Nama stream. Tentukan parameter ini bersama dengan AppName untuk mengembalikan data tingkat stream. Catatan
Jika Anda menentukan StreamName, Anda juga harus menentukan AppName. |
liveStream**** |
| Protocol |
string |
No |
Protokol stream. Nilai yang valid: flv, hls, rtmp, rts, dan p2p. Anda dapat mengkueri data untuk beberapa protokol dengan memisahkannya menggunakan koma (,). Data untuk beberapa protokol tidak diagregasi dan dikeluarkan pada tingkat stream. Catatan
Opsi rts mengkueri stream Real-Time Streaming (RTS) yang menggunakan protokol ARTC.
|
flv |
| NextPageToken |
string |
No |
Token kueri berhalaman. Maksimum 5.000 baris data dapat dikembalikan per kueri. Jika data yang dikueri melebihi 5.000 baris, respons menyertakan indeks awal untuk permintaan halaman berikutnya. Teruskan token ini dalam permintaan untuk melanjutkan kueri data dari tempat kueri sebelumnya berakhir. |
UjsM9x3aVcJi9a0-ArwJUTTC67CIBKLw***** |
Elemen respons
|
Element |
Type |
Description |
Example |
|
object |
Data kueri. |
||
| DomainName |
string |
Nama domain terakselerasi yang dikueri. |
example.com |
| EndTime |
string |
Waktu akhir. Waktu mengikuti standar ISO 8601 dengan format YYYY-MM-DDThh:mm:ssZ. Waktu ditampilkan dalam UTC. |
2015-12-10T21:00:00Z |
| NextPageToken |
string |
Indeks awal untuk kueri berikutnya. Nilai ini dikembalikan ketika data yang dikueri belum sepenuhnya diambil. |
UjsM9x3aVcJi9a0-ArwJUTTC67C***37C0= |
| PageSize |
integer |
Jumlah baris data yang dikembalikan. |
5000 |
| RequestId |
string |
ID permintaan. |
B955107D-E658-4E77-B913-E0AC3D31693E |
| StartTime |
string |
Waktu mulai. Waktu mengikuti standar ISO 8601 dengan format YYYY-MM-DDThh:mm:ssZ. Waktu ditampilkan dalam UTC. |
2015-12-10T20:00:00Z |
| StreamDetailData |
object |
||
| StreamData |
array<object> |
Kumpulan data yang dikembalikan. |
|
|
object |
Kumpulan data yang dikembalikan. |
||
| AppName |
string |
The application name. |
app |
| Bps |
number |
The average bandwidth of the stream per minute. Unit: bps. |
423304182.66 |
| Count |
integer |
The total number of online viewers for the stream per minute. |
423304182 |
| FlvBps |
number |
The bandwidth of the FLV stream. Unit: bps. Catatan
This parameter is not returned if the specified protocol is not used. |
454 |
| FlvCount |
integer |
The number of online viewers for the FLV stream. Catatan
This parameter is not returned if the specified protocol is not used. |
32 |
| FlvTraffic |
integer |
The traffic of the FLV stream. Unit: bytes. Catatan
This parameter is not returned if the specified protocol is not used. |
1254 |
| HlsBps |
number |
The bandwidth of the HLS stream. Unit: bps. Catatan
This parameter is not returned if the specified protocol is not used. |
4456 |
| HlsCount |
integer |
The number of online viewers for the HLS stream. Catatan
This parameter is not supported. |
56 |
| HlsTraffic |
integer |
The traffic of the HLS stream. Unit: bytes. Catatan
This parameter is not returned if the specified protocol is not used. |
568 |
| NewConns |
string |
The number of new connections to the stream per minute. |
450 |
| P2pBps |
number |
The bandwidth of the P2P stream. Unit: bps. Catatan
This parameter is not returned if the specified protocol is not used. |
6845 |
| P2pCount |
integer |
The number of online viewers for the P2P stream. Catatan
This parameter is not returned if the specified protocol is not used. |
78 |
| P2pTraffic |
integer |
The traffic of the P2P stream. Unit: bytes. Catatan
This parameter is not returned if the specified protocol is not used. |
4102 |
| RtmpBps |
number |
The bandwidth of the RTMP stream. Unit: bps. Catatan
This parameter is not returned if the specified protocol is not used. |
3323 |
| RtmpCount |
integer |
The number of online viewers for the RTMP stream. Catatan
This parameter is not returned if the specified protocol is not used. |
63 |
| RtmpTraffic |
integer |
The traffic of the RTMP stream. Unit: bytes. Catatan
This parameter is not returned if the specified protocol is not used. |
5568 |
| RtsBps |
number |
The bandwidth of the RTS stream. Unit: bps. Catatan
This parameter is not returned if the specified protocol is not used. |
2361 |
| RtsCount |
integer |
The number of online viewers for the RTS stream. Catatan
This parameter is not returned if the specified protocol is not used. |
89 |
| RtsTraffic |
integer |
The traffic of the RTS stream. Unit: bytes. Catatan
This parameter is not returned if the specified protocol is not used. |
2322 |
| StreamName |
string |
The stream name. |
test.flv |
| TimeStamp |
string |
The start of the time slice. |
2015-12-10T20:00:00Z |
| Traffic |
integer |
The total traffic of the stream per minute. Unit: bytes. |
423304182 |
Contoh
Respons sukses
JSONformat
{
"DomainName": "example.com",
"EndTime": "2015-12-10T21:00:00Z",
"NextPageToken": "UjsM9x3aVcJi9a0-ArwJUTTC67C***37C0=",
"PageSize": 5000,
"RequestId": "B955107D-E658-4E77-B913-E0AC3D31693E",
"StartTime": "2015-12-10T20:00:00Z",
"StreamDetailData": {
"StreamData": [
{
"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
}
]
}
}
Kode kesalahan
|
HTTP status code |
Error code |
Error message |
Description |
|---|---|---|---|
| 400 | InvalidStartTime.Malformed | Specified StartTime is malformed. | |
| 400 | InvalidEndTime.Malformed | Specified EndTime is malformed. | |
| 400 | InvalidEndTime.Mismatch | Specified end time does not math the specified start time. | The end time does not match the start time. Make sure that the start and end times match. |
| 400 | InvalidTimeSpan | The time span exceeds the limit. | The time span exceeds the limit. Please refer to the API documentation to specify a reasonable time span. |
| 400 | InvalidPageToken | The token of page is invalid. | The specified paging token is incorrect. Specify the correct token returned by the last query and confirm that your request parameters are not modified. |
| 400 | InvalidAppName.Mismatch | The AppName param must be passed. | The AppName parameter does not match. Make sure that you specify the correct AppName. |
| 400 | InvalidStreamProtocol.NotSupport | The specified stream protocol is not support. | |
| 400 | InvalidStreamName.LengthTooLong | The specified stream name is too long. | |
| 400 | InvalidAppName.LengthTooLong | The specified app name is too long. | |
| 400 | InvalidTime.ValueNotSupported | Specified Time is malformed. | The specified time is invalid. |
Lihat Error Codes untuk daftar lengkap.
Catatan rilis
Lihat Release Notes untuk daftar lengkap.