Querying All DB Engine Instances in the Recycle Bin
Function
This API is used to query all DB engine instances in the recycle bin. Before calling this API:
- Learn how to authenticate this API.
URI
GET https://{Endpoint}/v3.1/{project_id}/recycle-instances
| Parameter | Mandatory | Type | Description |
|---|---|---|---|
| project_id | Yes | String | Explanation: Project ID of a tenant in a region. For details about how to obtain the value, see Obtaining a Project ID. Restrictions: None Value range: The value can contain 32 characters. Only letters and digits are allowed. Default value: None |
| instance_name | No | String | DB instance name. |
| offset | No | Integer | Index offset. If offset is set to N, the resource query starts from the N+1 data entry. The default value is 0, indicating that the query starts from the first data entry. The value cannot be a negative number. For example, if this parameter is set to 0 and limit is set to 10, only the 1st to 10th records are displayed. |
| limit | No | Integer | Number of records to be queried. The default value is 50. The value cannot be a negative number. The minimum value is 1 and the maximum value is 50. For example, if this parameter is set to 10, a maximum of 10 records can be displayed. |
Request Parameters
None
Response Parameters
| Parameter | Type | Description |
|---|---|---|
| total_count | Integer | Total number of records. |
| instances | Array of objects | Information about all instances in the recycle bin. For details, see Table 3. |
| Parameter | Type | Description |
|---|---|---|
| id | String | Instance ID. |
| name | String | DB instance name. |
| ha_mode | String | Deployment model. Value:
|
| engine_version | String | Engine version. |
| pay_model | String | Billing mode. 0: pay-per-use 1: yearly/monthly |
| created_at | String | Creation time in the "yyyy-mm-ddThh:mm:ssZ" format. T is the separator between calendar and hourly notation of time. Z indicates the time zone offset. For example, in the Beijing time zone, the offset is shown as +0800. |
| deleted_at | String | Deletion time in the "yyyy-mm-ddThh:mm:ssZ" format. T is the separator between calendar and hourly notation of time. Z indicates the time zone offset. For example, in the Beijing time zone, the offset is shown as +0800. |
| volume_type | String | Disk type. Value:
|
| data_vip | String | Private IP address. |
| enterprise_project_id | String | Enterprise project ID. The value 0 indicates the default enterprise project. |
| recycle_backup_id | String | Backup ID. (Backup ID in the backup information generated when the instance is deleted.) |
| recycle_status | String | Backup status in the recycle bin. Value:
|
| mode | String | Product type. Value:
|
Example Request
GET https://gaussdb-opengauss.eu-west-101.myhuaweicloud.eu/v3.1/619d3e78f61b4be68bc5aa0b59edcf7b/recycle-instances
Example Response
{
"total_count" : 2,
"instances" : [ {
"id" : "21f20e55999947a9938ad0453b757e72in14",
"name" : "gaussdbv5_CCv20_bms_default_1_20220827012852",
"ha_mode" : "Ha",
"engine_version" : "V2.0-2.3.0",
"pay_model" : 0,
"created_at" : "2022-08-09T09:26:44.000+08:00",
"deleted_at" : "2022-08-09T09:26:44.000+08:00",
"volume_type" : "localssd",
"data_vip" : "25.213.0.41 / 25.213.0.188 / 25.213.0.101 / 25.213.0.82",
"enterprise_project_id" : 0,
"recycle_backup_id" : "00b755ed678e41d18c74b28e2ad41bdcbr14",
"recycle_status" : "Active",
"mode" : "enterprise"
}, {
"id" : "a9df5b52b32e4571b1b6425a78a32956in14",
"name" : "ecs-lxy-backup-3",
"ha_mode" : "Ha",
"engine_version" : "V2.0-2.3.0",
"pay_model" : 0,
"created_at" : "2022-08-09T09:26:44.000+08:00",
"deleted_at" : "2022-08-09T09:26:44.000+08:00",
"volume_type" : "ultrahigh",
"data_vip" : "173.202.10.246 / 173.202.10.205 / 173.202.10.175",
"enterprise_project_id" : 0,
"recycle_backup_id" : "ef393704ef0045d1b6226b6f2cdc48a7br14",
"recycle_status" : "Active",
"mode" : "enterprise"
} ]
} Status Code
- Normal
- Abnormal
For details, see Status Codes.
Error Code
For details, see Error Codes.