All Products
Search
Document Center

Dynamic Content Delivery Network:DescribeDcdnDomainUsageData

Last Updated:Apr 11, 2024

Queries resource usage about domain names in a billable region.

Operation description

  • You can call this operation up to 10 times per second per account.
  • Usage data includes traffic (measured in bytes), bandwidth values (measured in bit/s), and the number of requests.

Time granularity

The time granularity supported by the Interval parameter, the maximum time period within which historical data is available, and the data delay vary with the maximum time range per query, as described in the following table.

Time granularityMaximum time range per queryHistorical data availableData delay
5 minutes3 days93 days15 minutes
1 hour31 days186 days4 hours
1 day366 days366 days04:00 on the next day

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
dcdn:DescribeDcdnDomainUsageDataRead
  • Domain
    acs:dcdn:*:{#accountId}:domain/{#domainName}
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
DomainNamestringNo

The accelerated domain name. You can specify up to 100 domain names in each request. Separate multiple domain names with commas (,).

Note If you do not specify this parameter, the usage data of all accelerated domain names that belong to your Alibaba Cloud account is returned.
example.com
StartTimestringYes

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 The minimum time granularity at which the data is queried is 5 minutes.
2015-12-10T20:00:00Z
EndTimestringYes

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. The maximum time range that can be queried is 31 days.
2015-12-10T22:00:00Z
FieldstringYes

The type of data that you want to query. Valid values:

  • bps: bandwidth
  • traf: traffic
  • acc: requests
Note acc does not support the Area parameter.
bps
TypestringNo

The type of the requests. Valid values:

  • static: static requests
  • dynamic: dynamic requests
  • all: all requests

Default value: all

dynamic
DataProtocolstringNo

The protocol of the data to query. Valid values:

  • quic: Quick UDP Internet Connections (QUIC)
  • https: HTTPS
  • http: HTTP
  • all: all the preceding protocols

Default value: all

all
AreastringNo

The billable region. Valid values:

  • CN: Chinese mainland
  • OverSeas: outside the Chinese mainland
  • AP1: Asia Pacific 1
  • AP2: Asia Pacific 2
  • AP3: Asia Pacific 3
  • NA: North America
  • SA: South America
  • EU: Europe
  • MEAA: Middle East and Africa
  • all: all the preceding billable regions

Default value: CN

CN
IntervalstringNo

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

The time interval varies with the maximum time range per query. Valid values: 300 (5 minutes), 3600 (1 hour), and 86400 (1 day). For more information, see Usage notes.

300

Response parameters

ParameterTypeDescriptionExample
object
DomainNamestring

The accelerated domain name that was queried.

example.com
EndTimestring

The end of the time range during which data was queried.

2015-12-10T22:00:00Z
StartTimestring

The beginning of the time range during which data was queried.

2015-12-10T20:00:00Z
Typestring

The type of the returned data.

bps
Areastring

The billable region where the usage data was collected.

CN
RequestIdstring

The ID of the request.

B955107D-E658-4E77-B913-E0AC3D31693E
DataIntervalstring

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

/
UsageDataPerIntervalobject []

The traffic that was collected at each interval.

TimeStampstring

The timestamp of the returned data.

2015-12-10T21:30:00Z
PeakTimestring

The time of the peak bandwidth value if the Field parameter in the request is set to bps. Otherwise, this parameter returns the same value as the TimeStamp parameter.

2015-12-10T21:30:00Z
Valuestring

The usage.

4233041**
SpecialValuestring

The data usage in a specific scenario.

Note This parameter indicates the data usage in a specific scenario. If no special billable item is specified, ignore this parameter.
4233041**

Examples

Sample success responses

JSONformat

{
  "DomainName": "example.com",
  "EndTime": "2015-12-10T22:00:00Z",
  "StartTime": "2015-12-10T20:00:00Z",
  "Type": "bps",
  "Area": "CN",
  "RequestId": "B955107D-E658-4E77-B913-E0AC3D31693E",
  "DataInterval": "/",
  "UsageDataPerInterval": {
    "DataModule": [
      {
        "TimeStamp": "2015-12-10T21:30:00Z",
        "PeakTime": "2015-12-10T21:30:00Z",
        "Value": "4233041**",
        "SpecialValue": "4233041**"
      }
    ]
  }
}

Error codes

HTTP status codeError codeError messageDescription
400InvalidParameterThe specified parameter is invalid.A parameter is set to an invalid value.
400InvalidStartTime.MalformedThe specified StartTime parameter is invalid.The format of the specified start time is invalid. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.
400InvalidEndTime.MalformedThe specified EndTime is invalid.The format of the specified end time is invalid. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.
400InvalidTime.MalformedSpecified StartTime or EndTime is malformed.The format of the specified start time or end time is invalid. Specify the time in the ISO 8601 standard in the yyyy-MM-ddTHH:mm:ssZ format. The time must be in UTC.
400InvalidParameterFieldThe specified Field is invalid.The Field parameter is set to an invalid value.
400InvalidParameterTypeThe specified Type is invalid.The Type parameter is set to an invalid value.
400InvalidEndTime.MismatchThe specified EndTime is earlier than the StartTime.The end time is earlier than the start time.
400InvalidTimeSpanThe time span exceeds the limit.The time span exceeds the limit. Configure a valid time span as described in API documentation.
400InvalidParameterIntervalThe specified Interval is invalid.The Interval parameter is set to an invalid value.

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
No change history