You can call the DescribeUserUsageDetailDataExportTask operation to query the details export tasks for one or more CDN domains under your account. The task is to export detailed information about the resource usage that is queried at intervals of 5 minutes within a specific time range.

Note This operation has been available from July 20, 2018 and can be used to return tasks that query data of up to one year.

Debugging

Alibaba Cloud provides OpenAPI Explorer to simplify API usage. You can use OpenAPI Explorer to search for APIs, call APIs, and dynamically generate SDK example code.

Request parameters

Parameter Type Required Description
Action String Yes The operation that you want to perform. Set this parameter to DescribeUserUsageDetailDataExportTask.
PageSize Integer No The maximum number of entries to return on each page.
PageNumber Integer No The number of the page to return.

Response parameters

Parameter Type Description
TotalCount Integer The total number of entries returned.
PageSize Integer The maximum number of entries that can be returned on each page.
PageNumber Integer The number of the page returned.
UsageDataPerPage UsageData[] The task details on the page.

Parameters in UsageData

Parameter Type Description
StartTime String The beginning of the time range where the data was queried.
EndTime String The end of the time range where the data was queried.
CreateTime String The time when the task was created.
UpdateTime String The time when the task was last modified.
TaskId String The ID of the task.
TaskName String The name of the task.
Status String The status of the task.
DownloadUrl String The URL where the task file can be downloaded.

Examples

Sample request

http://cdn.aliyuncs.com?Action=DescribeUserUsageDetailDataExportTask&DomainName=example.com
&PageSize=10
&PageNumber=1
&<Common request parameters>          

Sample success response

JSON format

{
    "TotalCount": "1",
    "PageSize": "10",
    "PageNumber": "1",
    "UsageDataPerPage": {
        "UsageData": [
            {
                "StartTime": "2018-12-10T00:00:00Z",
                "EndTime": "2018-12-11T00:00:00Z",
                "CreateTime": "2018-12-15T12:33:10Z",
                "ModifyTime": "2018-12-15T12:38:49Z",
                "TaskName":"test",
                "TaskId":"34230590834"
                "Status": "Success",
                "DownloadUrl":"http://example.com/xxxx/xxxx.pdf",
                "UpdateTime": "2018-12-15T12:41:49Z"
            }
        ]
    },
    "RequestId": "B955107D-E658-4E77-B913-E0AC3D31693E"
}

Error codes

Error code Error message HTTP status code Description
Throttling Request was denied due to request throttling. 503 The error message returned because the request was denied due to throttling.
IllegalOperation Illegal domain, operation is not permitted. 403 The error message returned because the specified domain name is invalid.
OperationDenied Your account does not open Cdn service yet. 403 The error message returned because CDN has not been activated for your account.
OperationDenied Your Cdn service is suspended. 403 The error message returned because CDN has been suspended for your account.
InvalidParameter Invalid Parameter. 400 The error message returned because the parameters are invalid.
InvalidParameterProduct Invalid Parameter Product. 400 The error message returned because the specified Product parameter is invalid.
InvalidParameterArea Invalid Parameter Area. 400 The error message returned because the specified Area parameter is invalid.
InvalidParameterField Invalid Parameter Field. 400 The error message returned because the specified Field parameter is invalid.
InvalidParameterStartTime Invalid Parameter StartTime. 400 The error message returned because the specified StartTime parameter is invalid.
InvalidParameterEndTime Invalid Parameter EndTime. 400 The error message returned because the specified EndTime parameter is invalid.
InvalidTimeRange StartTime and EndTime range should less than 1 month. 400 The error message returned because the time range specified by the StartTime and EndTime parameters exceeds the maximum value of 31 days.