Queries the network traffic for one or more domain names.
- If you specify neither the StartTime parameter nor the EndTime parameter, the data of the last 24 hours is returned.
- This operation is called to monitor data. The data is collected and processed in a manner different from that for billing. Therefore, the data that is returned by this operation cannot be used as a reference to calculate the resource usage for billing.
QPS limit
A single user can perform a maximum of 100 queries per second (QPS). Throttling is triggered when the number of calls per second exceeds the QPS limit. The throttling may affect your business. Thus, we recommend that you observe the QPS limit on this operation. For more information about what a single user means and the QPS details, see QPS limit on an API operation in ApsaraVideo Live.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | DescribeLiveDomainTrafficData |
The operation that you want to perform. Set the value to DescribeLiveDomainTrafficData. |
DomainName | String | No | example.com |
The streaming domain. Separate multiple domain names with commas (,). |
StartTime | String | No | 2017-12-10T14:00:00Z |
The beginning of the time range to query. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC. Note You can query the data of the last 90 days at most.
|
EndTime | String | No | 2017-12-10T15:00:00Z |
The end of the time range to query. The end time must be later than the start time. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC. |
Interval | String | No | 300 |
The interval at which data is to be queried. Unit: seconds. Valid values:
Note If you do not specify this parameter or the specified value is invalid, the default
value 300 is used.
|
LocationNameEn | String | No | tianjin |
The name of the region in which you want to query data. To query regions, call the DescribeCdnRegionAndIsp operation. If you do not specify this parameter, the data in all regions is returned. |
IspNameEn | String | No | alibaba |
The name of the Internet service provider (ISP). To query ISPs, call the DescribeCdnRegionAndIsp operation. If you do not specify this parameter, the data of all ISPs is returned. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
DomainName | String | example.com |
The streaming domain that was queried. |
DataInterval | String | 300 |
The interval at which data was queried. |
TrafficDataPerInterval | Array of DataModule |
The network traffic data that was collected for each interval. |
|
DataModule | |||
TimeStamp | String | 2017-12-10T15:00:05Z |
The timestamp of the returned data. |
TrafficValue | String | 454680793 |
The total network traffic. |
HttpTrafficValue | String | 0 |
The network traffic over HTTP. |
HttpsTrafficValue | String | 454680793 |
The network traffic over HTTPS. |
RequestId | String | B955107D-E658-4E77-B913-E0AC3D31693E |
The ID of the request. |
StartTime | String | 2017-12-10T14:00:00Z |
The beginning of the time range in which data was queried. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC. |
EndTime | String | 2017-12-10T15:00:00Z |
The end of the time range in which data was queried. The time follows the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time is displayed in UTC. |
Examples
Sample requests
http(s)://live.aliyuncs.com/?Action=DescribeLiveDomainTrafficData
&<Common request parameters>
Sample success responses
XML
format
<DescribeLiveDomainTrafficDataResponse>
<DataInterval>300</DataInterval>
<DomainName>example.com</DomainName>
<EndTime>2017-12-10T15:00:00Z</EndTime>
<RequestId>B955107D-E658-4E77-B913-E0AC3D31693E</RequestId>
<StartTime>2017-12-10T14:00:00Z</StartTime>
<TrafficDataPerInterval>
<DataModule>
<HttpTrafficValue>0</HttpTrafficValue>
<HttpsTrafficValue>423304182</HttpsTrafficValue>
<TimeStamp>2017-12-10T15:00:00Z</TimeStamp>
<TrafficValue>423304182</TrafficValue>
</DataModule>
<DataModule>
<HttpTrafficValue>0</HttpTrafficValue>
<HttpsTrafficValue>454680793</HttpsTrafficValue>
<TimeStamp>2017-12-10T15:00:05Z</TimeStamp>
<TrafficValue>454680793</TrafficValue>
</DataModule>
</TrafficDataPerInterval>
</DescribeLiveDomainTrafficDataResponse>
JSON
format
{
"DataInterval":"300",
"DomainName":"example.com",
"EndTime":"2017-12-10T15:00:00Z",
"RequestId":"B955107D-E658-4E77-B913-E0AC3D31693E",
"StartTime":"2017-12-10T14:00:00Z",
"TrafficDataPerInterval":{
"DataModule":[
{
"HttpTrafficValue":"0",
"HttpsTrafficValue":"423304182",
"TimeStamp":"2017-12-10T15:00:00Z",
"TrafficValue":"423304182"
},
{
"HttpTrafficValue":"0",
"HttpsTrafficValue":"454680793",
"TimeStamp":"2017-12-10T15:00:05Z",
"TrafficValue":"454680793"
}
]
}
}
Error codes
HttpCode | Error code | Error message | Description |
---|---|---|---|
400 | InvalidStartTime.Malformed | Specified StartTime is malformed. | The error message returned because the format of the start time is invalid. Check whether the value of the StartTime parameter is valid. |
400 | InvalidEndTime.Malformed | Specified EndTime is malformed. | The error message returned because the format of the end time is invalid. Check whether the value of the EndTime parameter is valid. |
400 | InvalidEndTime.Mismatch | Specified end time does not math the specified start time. | The error message returned because the end time is earlier than the start time. Check whether the values of the StartTime and EndTime parameters are valid. |
For a list of error codes, visit the API Error Center.