Queries the advanced download tasks for an ApsaraDB RDS for MySQL instance, an ApsaraDB RDS for PostgreSQL instance, or a PolarDB for MySQL cluster.
Operation description
Debugging
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.
Operation | Access level | Resource type | Condition key | Associated operation |
---|---|---|---|---|
dbs:DescribeDownloadTask | get |
|
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
RegionCode | string | Yes | The ID of the region in which the instance resides. You can call the DescribeDBInstanceAttribute operation to query the region ID of the instance. | cn-hangzhou |
InstanceName | string | No | The ID of the instance. Note
This parameter is required.
| rm-bp1imnmcjxdz7**** |
DatasourceId | string | No | The ID of the Database Backup (DBS) data source. Specify the parameter in the format of ds-${Instance ID}_${regionId}. | ds-rm-2ze8g2am97624****_cn-hangzhou |
BackupSetId | string | No | The ID of the backup set generated when you create a download task. You can call the DescribeBackups operation to query the ID. | 216**** |
State | string | No | The state of the download task. Valid values:
| queueing |
TaskType | string | No | The type of the download task. Valid values:
| full |
StartTime | string | No | The beginning of the time range to query. Specify this parameter as a timestamp of the LONG type. Unit: milliseconds. | 1661941554000 |
EndTime | string | No | The end of the time range to query. Specify this parameter as a timestamp of the LONG type. Unit: milliseconds. | 1661941556000 |
PageSize | string | No | The number of entries to return on each page. | 50 |
CurrentPage | string | No | The page number of the page to return. | 1 |
OrderDirect | string | No | The order in which you want to sort the entries. Valid values:
| desc |
OrderColumn | string | No | The column based on which the entries are sorted. By default, the entries are sorted by the time when the download task was created. Set the value to gmt_create. | gmt_create |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "5D285EB9-A443-592D-9F3D-A888FAC3****",
"ErrCode": "DBS.InternalError",
"Success": "true",
"ErrMessage": "instanceName can not be empty",
"Code": "DBS.InternalError",
"Message": "instanceName can not be empty",
"Data": {
"PageNumber": 1,
"TotalPages": 2,
"Extra": "dbtest",
"TotalElements": 1,
"PageSize": 10,
"Content": {
"List": [
{
"TaskId": "dt-qxntlvgu****",
"RegionCode": "cn-hangzhou",
"Format": "csv",
"DbList": "[dbtest]",
"BakSetId": "148261****",
"DownloadStatus": "queueing",
"ExportDataSize": "0",
"ImportDataSize": "0",
"BackupSetTime": "1663162216000",
"TargetType": "URL",
"TargetPath": "test_db/path",
"Progress": "0/0",
"GmtCreate": "1663321957000"
}
]
}
}
}
Error codes
HTTP status code | Error code | Error message |
---|---|---|
403 | Request.Forbidden | Have no Permissions |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2022-11-16 | The response structure of the API has changed | View Change Details |