Queries the monitoring data of an accelerated domain name. Data is collected every day. You can query data collected within the last 90 days.

Note
  • If you do not set StartTime or EndTime, data within the last 24 hours is queried. If you set both StartTime and EndTime, data within the specified time range is queried.
  • You can query the monitoring data of a specific accelerated domain name or all accelerated domain names that belong to your Alibaba Cloud account.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String No DescribeDomainsUsageByDay

The operation that you want to perform. Set the value to DescribeDomainsUsageByDay.

DomainName String No example.com

The accelerated domain name. You can specify only one domain name.

If you do not specify an accelerated domain name, the monitoring data of all accelerated domain names that belong to your account is queried.

StartTime String No 2019-12-22T08:00:00Z

The start 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+0.

EndTime String No 2019-12-23T09:00:00Z

The end 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+0.

Note The end time must be later than the start time.

Response parameters

Parameter Type Example Description
RequestId String C88EF8ED-72F0-45EA-9E86-95114E224FC5

The ID of the request.

DomainName String example.com

The information about the accelerated domain name.

DataInterval String 86400

The time interval between the data entries. Unit: seconds.

StartTime String 2019-12-22T08:00:00Z

The start of the time range that was queried.

EndTime String 2019-12-23T09:00:00Z

The end of the time range that was queried.

UsageByDays Array of UsageByDay

The monitoring data collected at each time interval.

UsageByDay
BytesHitRate String 97.46250599529726

The cache hit ratio that is calculated based on bytes. The cache hit ratio is measured in percentage.

TimeStamp String 2019-12-22

The timestamp of the data returned.

Qps String 7.466354166666667

The number of queries per second (QPS).

RequestHitRate String 70.24770071912111

The cache hit ratio that is calculated based on requests. The cache hit ratio is measured in percentage.

MaxBps String 306747.76

The peak bandwidth value. Unit: bit/s.

MaxBpsTime String 2019-12-23 10:55:00

The time when the bandwidth reached the peak value.

MaxSrcBps String 72584.072

The peak bandwidth value during back-to-origin routing. Unit: bit/s.

TotalAccess String 645093

The total amount of requests.

MaxSrcBpsTime String 2019-12-23 11:45:00

The time when the bandwidth during back-to-origin routing reached the peak value.

TotalTraffic String 564300099309

The total amount of network traffic. Unit: bytes.

UsageTotal Struct

The summarized monitoring data.

BytesHitRate String 97.03110726801242

The cache hit ratio that is calculated based on bytes. The cache hit ratio is measured in percentage.

RequestHitRate String 69.92610837438424

The cache hit ratio that is calculated based on requests. The cache hit ratio is measured in percentage.

MaxBps String 1.0747912780000001E8

The peak bandwidth value. Unit: bit/s.

MaxBpsTime String 2019-12-23 10:55:00

The time when the bandwidth reached the peak value.

MaxSrcBps String 72584.072

The peak bandwidth value during back-to-origin routing. Unit: bit/s.

TotalAccess String 1319500

The total number of requests.

MaxSrcBpsTime String 2019-12-23 11:45:00

The time when the bandwidth during back-to-origin routing reached the peak value.

TotalTraffic String 1117711832100

The total amount of network traffic. Unit: bytes.

Examples

Sample requests

http://cdn.aliyuncs.com/?Action=DescribeDomainsUsageByDay
&DomainName=example.com
&StartTime=2019-12-22T08:00:00Z
&EndTime=2019-12-23T09:00:00Z
&<Common request parameters>

Sample success responses

XML format

<DescribeDomainsUsageByDayResponse>
  <UsageTotal>
        <RequestHitRate>0.46869615163699024</RequestHitRate>
        <MaxSrcBpsTime>2019-12-23 11:45:00</MaxSrcBpsTime>
        <MaxSrcBps>72584.072</MaxSrcBps>
        <MaxBps>306747.76</MaxBps>
        <TotalTraffic>220090843</TotalTraffic>
        <TotalAccess>1741</TotalAccess>
        <MaxBpsTime>2019-12-23 10:55:00</MaxBpsTime>
        <BytesHitRate>0.9338625414779297</BytesHitRate>
  </UsageTotal>
  <UsageByDays>
        <UsageByDay>
              <TimeStamp>2019-12-23</TimeStamp>
              <RequestHitRate>0.46869615163699024</RequestHitRate>
              <MaxSrcBpsTime>2019-12-23 11:45:00</MaxSrcBpsTime>
              <MaxSrcBps>72584.072</MaxSrcBps>
              <MaxBps>306747.76</MaxBps>
              <TotalTraffic>220090843</TotalTraffic>
              <TotalAccess>1741</TotalAccess>
              <MaxBpsTime>2019-12-23 10:55:00</MaxBpsTime>
              <Qps>0.020150462962962964</Qps>
              <BytesHitRate>0.9338625398107486</BytesHitRate>
        </UsageByDay>
  </UsageByDays>
  <RequestId>0DE5531F-A7C2-4788-A35A-38883193B2D8</RequestId>
  <EndTime>2019-12-23T09:00:00Z</EndTime>
  <StartTime>2019-12-22T08:00:00Z</StartTime>
  <DomainName>example.com</DomainName>
  <DataInterval>86400</DataInterval>
</DescribeDomainsUsageByDayResponse>

JSON format

{
    "UsageTotal": {
        "RequestHitRate": "0.46869615163699024",
        "MaxSrcBpsTime": "2019-12-23 11:45:00",
        "MaxSrcBps": 72584.072,
        "MaxBps": 306747.76,
        "TotalTraffic": 220090843,
        "TotalAccess": 1741,
        "MaxBpsTime": "2019-12-23 10:55:00",
        "BytesHitRate": "0.9338625414779297"
    },
    "UsageByDays": {
        "UsageByDay": [
            {
                "TimeStamp": "2019-12-23",
                "RequestHitRate": "0.46869615163699024",
                "MaxSrcBpsTime": "2019-12-23 11:45:00",
                "MaxSrcBps": 72584.072,
                "MaxBps": 306747.76,
                "TotalTraffic": 220090843,
                "TotalAccess": 1741,
                "MaxBpsTime": "2019-12-23 10:55:00",
                "Qps": "0.020150462962962964",
                "BytesHitRate": "0.9338625398107486"
            }
        ]
    },
    "RequestId": "0DE5531F-A7C2-4788-A35A-38883193B2D8",
    "EndTime": "2019-12-23T09:00:00Z",
    "StartTime": "2019-12-22T08:00:00Z",
    "DomainName":"example.com",
    "DataInterval":86400
}

Error codes

HttpCode Error code Error message Description
400 InvalidStartTime.Malformed Specified StartTime is malformed. The error message returned because the format of the specified start time is invalid. For more information about the time format, see the Request parameters section.
400 InvalidEndTime.Malformed Specified EndTime is malformed. The error message returned because the format of the specified end time is invalid. For more information about the time format, see the Request parameters section.
400 InvalidStartTime.ValueNotSupported The specified value of parameter StartTime is not supported. The error message returned because the specified start time is invalid. Rectify the start time and try again.
404 InvalidDomain.NotFound The domain provided does not exist in our records. The error message returned because the specified domain name does not exist or does not belong to the current Alibaba Cloud account. Check whether the domain name is correctly specified, whether the domain name is under the current Alibaba Cloud account, and whether the domain name has expired.

For a list of error codes, visit the API Error Center.