Querying a Backup List
Description
- This API is used to query backups based on specified conditions.
- For a cluster DB instance, if an incremental backup contains data, the query result is not empty.
URI
|
Parameter |
Type |
Mandatory |
Description |
|---|---|---|---|
|
project_id |
string |
Yes |
Project ID of a tenant in a region. To obtain the project ID, see Obtaining a Project ID. |
|
instance_id |
string |
No |
The instance ID, which can be obtained by calling the API for querying instances. If you do not have an instance, you can call the API used for creating an instance. |
|
backup_id |
string |
No |
Backup ID. |
|
backup_type |
string |
No |
Backup type.
|
|
offset |
Integer |
No |
The index position. The query starts from the next instance creation time indexed by this parameter under a specified project. If offset is set to N, the resource query starts from the N+1 piece of data. The value must be greater than or equal to 0. If this parameter is not transferred, offset is set to 0 by default, indicating that the query starts from the latest created DB instance. |
|
limit |
Integer |
No |
The maximum allowed number of backups to be queried. The value ranges from 1 to 100. If this parameter is not transferred, the first 100 DB instances are queried by default. |
|
begin_time |
string |
No |
The start time of the query. The format is yyyy-mm-dd hh:mm:ss. The value is in UTC format.
NOTE:
When end_time is not empty, begin_time is mandatory. |
|
end_time |
string |
No |
Specifies the end time of the query. The format is "yyyy-mm-dd hh:mm:ss". The value is in UTC format. |
|
mode |
string |
No |
The DB instance mode. Valid value:
|
Request Parameters
|
Parameter |
Mandatory |
Type |
Description |
|---|---|---|---|
|
X-Auth-Token |
Yes |
String |
User token |
Response Parameters
|
Parameter |
Type |
Mandatory |
Description |
|---|---|---|---|
|
backups |
Array of objects |
Yes |
The backup list. For more information, see Table 4. |
|
total_count |
Integer |
Yes |
The total number of queried records. |
|
Parameter |
Type |
Mandatory |
Description |
|---|---|---|---|
|
id |
String |
Yes |
Indicates the backup ID. |
|
name |
String |
Yes |
The backup name. |
|
instance_id |
String |
Yes |
The ID of the DB instance from which the backup was created. You can obtain the ID by calling the API for querying DB instances. If you do not have an instance, you can call the API used for creating an instance. |
|
instance_name |
String |
Yes |
The name of the DB instance for which the backup is created. |
|
datastore |
Object |
Yes |
The database version. For more information, see Table 5. |
|
type |
String |
Yes |
The backup type.
|
|
begin_time |
String |
Yes |
The backup start time. The format of the start time is yyyy-mm-dd hh:mm:ss. The value is in UTC format. |
|
end_time |
String |
Yes |
The backup end time. The format of the end time is yyyy-mm-dd hh:mm:ss. The value is in UTC format. |
|
status |
String |
Yes |
The backup status. Valid value:
|
|
size |
Long |
Yes |
The backup size in KB. |
|
description |
String |
Yes |
The backup description. |
|
Parameter |
Type |
Mandatory |
Description |
|---|---|---|---|
|
type |
String |
Yes |
The DB engine. Valid value: DDS-Community. |
|
version |
String |
Yes |
The database version. Versions 4.4, 4.2, 4.0, and 3.4 are supported. The value can be 4.4, 4.2, 4.0, or 3.4. |
- Example response
{ "backups": [ { "id": "43e4feaab48f11e89039fa163ebaa7e4br01", "name": "backup-test", "instance_id": "43e4feaab48f11e89039fa163ebaa7e4br01", "instance_name": "cluster-test", "datastore" : { "type" : "DDS-Community", "version" : "3.4" }, "type": "auto", "begin_time": "2018-08-06 12:41:14", "end_time": "2018-08-06 12:43:14", "status": "COMPLETED", "size": 2803, "description": "backup description" } ], "total_count":1 }
Status Code
For details, see Status Code.
Error Code
For details, see Error Code.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot