Queries the backup details of a PolarDB cluster.
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 |
---|---|---|---|---|
polardb:DescribeBackups | get | *Backup acs:polardb:{#regionId}:{#accountId}:DBCluster/{#DBClusterId} *DBCluster acs:polardb:{#regionId}:{#accountId}:dbcluster/{#DbClusterId} |
| none |
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
DBClusterId | string | Yes | The ID of the cluster. | pc-**************** |
BackupId | string | No | The ID of the backup set. | 11111111 |
BackupStatus | string | No | The status of the backup set. Valid values:
| Success |
BackupMode | string | No | The backup mode. Valid values:
| Automated |
StartTime | string | Yes | The beginning of the time range to query. Specify the time in the | 2020-11-14T00:00Z |
EndTime | string | Yes | The end of the time range to query. Specify the time in the | 2020-11-16T00:00Z |
BackupRegion | string | No | The region where the cross-region data backup file of the instance is stored. Note
This parameter is valid only for PolarDB for MySQL clusters.
| cn-hangzhou |
PageSize | integer | No | The number of entries to return on each page. Valid values:
Default value: 30. | 30 |
PageNumber | integer | No | The page number. The value must be a positive integer that does not exceed the maximum value of the INTEGER data type. Default value: 1. | 1 |
Response parameters
Examples
Sample success responses
JSON
format
{
"TotalRecordCount": "1",
"PageRecordCount": "1",
"RequestId": "24A1990B-4F6E-482B-B8CB-75C612******",
"PageNumber": "1",
"Items": {
"Backup": [
{
"BackupSetSize": "4639948800",
"ConsistentTime": "1605425407",
"BackupStatus": "Success",
"BackupType": "FullBackup",
"BackupStartTime": "2020-11-15T07:30:05Z",
"ExpectExpireTime": "2022-10-24T08:13:23Z",
"ExpectExpireType": "EXPIRED",
"IsAvail": "0",
"BackupEndTime": "2020-11-15T07:30:20Z",
"BackupId": "61*******",
"DBClusterId": "pc-****************",
"BackupsLevel": "Level-1",
"BackupMode": "Automated",
"BackupMethod": "Snapshot"
}
]
},
"TotalLevel2BackupSize": "4639948800"
}
Error codes
HTTP status code | Error code | Error message | Description |
---|---|---|---|
400 | InvalidDBClusterId.Malformed | The specified parameter DBClusterId is not valid. | The specified DBClusterId parameter is invalid. |
400 | InvalidBackupStatus.Malformed | The specified parameter BackupStatus is not valid. | The specified BackupStatus parameter is invalid. |
400 | InvalidBackupMode.Malformed | The specified parameter BackupMode is not valid. | The specified BackupMode parameter is invalid. |
400 | InvalidStartTime.Malformed | The specified parameter StartTime is not valid. | The specified StartTime parameter is invalid. |
400 | InvalidEndTime.Malformed | The specified parameter EndTime is not valid. | The specified EndTime parameter is invalid. |
400 | InvalidPageSize.Malformed | The specified parameter PageSize is not valid. | The specified PageSize parameter is invalid. |
400 | InvalidPageNumber.Malformed | The specified parameter PageNumber is not valid. | The specified PageNumber parameter is invalid. |
404 | InvalidDBCluster.NotFound | The DBClusterId provided does not exist in our records. | The specified DBClusterId parameter does not exist in the current record. |
404 | InvalidDBClusterId.NotFound | The DBInstanceId provided does not exist in our records. | The specified DBClusterId parameter does not exist in the current record. |
For a list of error codes, visit the Service error codes.
Change history
Change time | Summary of changes | Operation |
---|---|---|
2023-09-12 | The Error code has changed | View Change Details |
2023-05-26 | The Error code has changed. The response structure of the API has changed | View Change Details |
2022-06-01 | The Error code has changed. The request parameters of the API has changed | View Change Details |