Creates an advanced download task.
Operation description
Supported database engines
- ApsaraDB RDS for MySQL
- ApsaraDB RDS for PostgreSQL
- PolarDB for MySQL
References
For the instances that meet your business requirements, you can create an advanced download task by point in time or backup set. You can set the download destination to a URL or directly upload the downloaded backup set to your Object Storage Service (OSS) bucket to facilitate data analysis and offline archiving.
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:CreateDownload | create |
|
| 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-beijing |
InstanceName | string | Yes | The ID of the instance. | rm-wz994c1t1**** |
BakSetType | string | No | The type of the download task. Valid values:
| full |
BakSetId | string | No | The ID of the backup set. You can call the DescribeBackups operation to query the ID of the backup set. Note
This parameter is required if the BakSetType parameter is set to full.
| 146005**** |
DownloadPointInTime | string | No | The point in time at which the backup set is downloaded. Specify a UNIX timestamp representing the number of milliseconds that have elapsed since January 1, 1970, 00:00:00 UTC. Note
This parameter is required if the BakSetType parameter is set to pitr.
| 1661331864000 |
BakSetSize | string | No | The size of the full backup set. Unit: bytes. You can call the DescribeBackups operation to query the size of the full backup set. | 216**** |
FormatType | string | No | The format to which the downloaded backup set is converted. Valid values:
Note
This parameter is required.
| CSV |
TargetType | string | No | The type of the destination to which the backup set is downloaded. Valid values:
| OSS |
TargetBucket | string | No | The name of the OSS bucket that is used to store the backup set.
| test123 |
TargetPath | string | No | The destination path to which the backup set is downloaded. Note
This parameter is required if the TargetType parameter is set to OSS.
| test_db/path |
TargetOssRegion | string | No | The region in which the OSS bucket resides. Note
This parameter is required if the TargetType parameter is set to OSS.
| cn-beijing |
Response parameters
Examples
Sample success responses
JSON
format
{
"RequestId": "A08F908D-2C35-583F-93C1-ED80753F****",
"ErrCode": "DBS.ParamIsInValid",
"Success": "true",
"ErrMessage": "formatType can not be empty",
"Code": "DBS.ParamIsInValid",
"Message": "formatType can not be empty",
"Data": {
"BakSetId": "146005****",
"DownloadStatus": "initializing",
"Progress": "0/0",
"BackupSetTime": 1661373070000,
"RegionCode": "cn-beijing",
"TargetPath": "test_db/path",
"DbList": "testdb",
"ExportDataSize": 0,
"ImportDataSize": 0,
"GmtCreate": 1661940917570,
"TaskId": "dt-qxnsfq5s****",
"Format": "CSV",
"TargetType": "URL"
}
}
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 |
---|