Updated on 2025-11-27 GMT+08:00

Querying the Recycling Policy

Function

This API is used to query the recycling policy.

Authorization Information

Each account has permissions to call all APIs, but IAM users must have the required permissions specifically assigned.

  • If you are using role/policy-based authorization, see the required permissions in Permissions and Supported Actions.
  • If you are using identity policy-based authorization, the following identity policy-based permissions are required.

    Action

    Access Level

    Resource Type (*: required)

    Condition Key

    Alias

    Dependencies

    gaussdbfornosql:instance:getRecyclePolicy

    Read

    -

    -

    nosql:instance:list

    -

URI

GET /v3/{project_id}/instances/recycle-policy

Table 1 Path parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Explanation:

Project ID of a user in a region. To obtain this value, see Obtaining a Project ID.

Constraints:

N/A

Values:

N/A

Default value:

N/A

Request Parameters

Table 2 Request header parameters

Parameter

Mandatory

Type

Description

X-Auth-Token

Yes

String

Explanation:

User token

You can obtain the token by calling the IAM API by following Obtaining a User Token Through Password Authentication.

Constraints:

N/A

Values:

N/A

Default value:

N/A

Response Parameters

Status code: 200

Table 3 Response body parameters

Parameter

Type

Description

recycle_policy

object

Explanation:

Recycling policy. For details, see Table 4.

Recycling policy

Values:

N/A

Table 4 RecyclePolicy

Parameter

Type

Description

retention_period_in_days

Integer

Explanation:

Policy retention duration, in days

Constraints:

N/A

Values:

17

Default value:

7

Example Request

  • URI example
    GET https://gaussdb-nosql.ap-southeast-1.myhuaweicloud.com/v3/054e292c9880d4992f02c0196d3ea468/instances/recycle-policy
  • Example request body

    None

Example Response

Status code: 200

Success

{
  "recycle_policy": {
    "retention_period_in_days": 7
  }
}

Status Codes

For details, see Status Codes.

Error Codes

For details, see Error Codes.