Queries the total number and proportions of the HTTP status codes returned for one or more specified accelerated domains. The data was collected at intervals of 5 minutes. You can query data that was collected within the last 90 days.

Note If neither StartTime or EndTime is set, data collected within the last 24 hours is queried. If you set both StartTime and EndTime, data collected within the specified time range is queried.

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 DescribeDcdnDomainHttpCodeData

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

DomainName String Yes example.com

The accelerated domain name. Separate multiple accelerated domain names with commas (,).

StartTime String No 2019-03-01T00: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.

EndTime String No 2019-03-02T00: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.

Note The end time must be later than the start time.
Interval String No 300

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

The valid values vary based on the values of the StartTime and EndTime parameters. Valid values:

  • If the time range between StartTime and EndTime is less than 3 days, valid values are 300, 3600, and 86400. Default value: 300.
  • If the time range between StartTime and EndTime is from 3 to 31 days (31 days excluded), valid values are 3600 and 86400. Default value: 3600.
  • If the time range between StartTime and EndTime is 31 days or longer, set the value to 86400. Default value: 86400.
IspNameEn String No unicom

The name of your CDN service provider.

If you do not set this parameter, all ISPs are queried. You can call the DescribeCdnRegionAndIsp operation to query ISP names.

LocationNameEn String No beijing

The name of the region.

If you do not set this parameter, all regions are queried. You can call the DescribeCdnRegionAndIsp operation to query regions.

Response parameters

Parameter Type Example Description
DataInterval String 300

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

DataPerInterval Array of DataModule

The proportions of HTTP status codes collected during each interval.

DataModule
HttpCodeDataPerInterval Array of HttpCodeDataModule

The proportions of each HTTP status code.

HttpCodeDataModule
Code Integer 404

The HTTP status code.

Count Float 1

The number of entries returned.

Proportion Float 33.333333

The proportion of the HTTP status code.

TimeStamp String 2019-03-01T13:00:00Z

The timestamp of the data entry.

DomainName String example.com

The name of the accelerated domain.

RequestId String 91FC2D9D-B042-4634-8A5C-7B8E7482C22D

The ID of the request.

StartTime String 2019-03-01T00:00:00Z

The beginning of the time range.

EndTime String 2018-03-01T13:00:00Z

The end of the time range.

Examples

Sample requests

http(s)://dcdn.aliyuncs.com/?Action=DescribeDcdnDomainHttpCodeData
&DomainName=example.com
&StartTime=2019-03-01T00:00:00Z
&EndTime=2019-03-02T00:00:00Z
&<Common request parameters>

Sample success responses

XML format

<DescribeDcdnDomainHttpCodeDataResponse>
  <DataInterval>300</DataInterval>
  <RequestId>273642D8-A11C-420B-8EB5-BD62AE1FC69B</RequestId>
  <DomainName>example.com</DomainName>
  <DataPerInterval>
        <DataModule>
              <TimeStamp>2019-03-01T13:00:00Z</TimeStamp>
              <HttpCodeDataPerInterval>
                    <HttpCodeDataModule>
                          <Count>16</Count>
                          <Proportion>100</Proportion>
                          <Code>404</Code>
                    </HttpCodeDataModule>
              </HttpCodeDataPerInterval>
        </DataModule>
  </DataPerInterval>
  <EndTime>2018-03-01T13:05:00Z</EndTime>
  <StartTime>2018-03-01T13:00:00Z</StartTime>
</DescribeDcdnDomainHttpCodeDataResponse>

JSON format

{
	"DataInterval": 300,
	"RequestId": "273642D8-A11C-420B-8EB5-BD62AE1FC69B",
	"DomainName": "example.com",
	"DataPerInterval": {
		"DataModule": [
			{
				"TimeStamp": "2019-03-01T13:00:00Z",
				"HttpCodeDataPerInterval": {
					"HttpCodeDataModule": [
                        {
							"Count":16,
							"Proportion":100,
							"Code":404
						}
                    ]
				}
			}
		]
	},
	"EndTime": "2018-03-01T13:05:00Z",
	"StartTime": "2018-03-01T13:00:00Z"
}

Error codes

HttpCode Error code Error message Description
400 MissingTimeParameter The StartTime and EndTime must be both specified. The error message returned because the StartTime or EndTime parameter is not configured.
400 InvalidEndTime.Malformed The specified EndTime is invalid. The error message returned because the specified value of the EndTime parameter is invalid. You must specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.
400 InvalidEndTime.Mismatch The specified EndTime is earlier than the StartTime. The error message returned because the value of the EndTime parameter is earlier than the value of the StartTime parameter.
400 InvalidStartTime.ValueNotSupported The specified StartTime is invalid. The error message returned because the specified start time is invalid.

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