Queries the details about the PolarDB clusters that contain backup sets and reside in a specified region.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String No DescribeDBClustersWithBackups

The operation that you want to perform. Set the value to DescribeDBClustersWithBackups.

RegionId String Yes cn-hangzhou

The ID of the region.

Note You can call the DescribeRegions operation to query region IDs.
DBClusterIds String No pc-**************

The ID of the PolarDB cluster. If you need to specify multiple cluster IDs, separate the cluster IDs with commas (,).

DBClusterDescription String No test

The name of the cluster. The name must meet the following requirements:

  • The name cannot start with http:// or https://.
  • The name must be 2 to 256 characters in length.
DBType String No MySQL

The type of the database engine. Valid values:

  • MySQL
  • PostgreSQL
  • Oracle
IsDeleted Integer No 0

Specifies whether the cluster is deleted. Valid values:

  • 0: not deleted
  • 1: deleted
PageSize Integer No 30

The number of entries to return on each page. Valid values:

  • 30
  • 50
  • 100

Default value: 30s.

PageNumber Integer No 1

The number of the page to return. The value must be an integer that is larger than 0. Default value: 1.

DBVersion String No 8.0

The version number of the database engine. Valid values:

  • Valid values for MySQL:
    • 5.6
    • 5.7
    • 8.0
  • PostgreSQL: 11.
  • Oracle: 11.

Response parameters

Parameter Type Example Description
Items Array of DBCluster

The details about the cluster.

DBCluster
CreateTime String 2020-05-09T09:33:51Z

The time when the cluster was created.

DBClusterDescription String test

The name of the cluster.

DBClusterId String pc-****************

The ID of the cluster.

DBClusterNetworkType String VPC

The network type of the cluster.

DBClusterStatus String Running

The status of the cluster. Valid values:

  • Creating: The cluster is being created.
  • Running: The cluster is running.
  • Deleting: The cluster is being released.
  • Rebooting: The cluster is restarting.
  • DBNodeCreating: The node is being added to the cluster.
  • DBNodeDeleting: The node is being removed from the cluster.
  • ClassChanging: The node specification is being changed.
  • NetAddressCreating: The network connection is being created.
  • NetAddressDeleting: The network connection is being deleted.
  • NetAddressModifying: The network connection is being modified.
  • Deleted: The cluster is deleted.
DBNodeClass String polar.mysql.x4.medium

The specification of the node.

DBType String MySQL

The engine of the database.

DBVersion String 8.0

The version of the database engine.

DeletedTime String 2020-05-12T03:25:37Z

The time when the cluster was deleted.

DeletionLock Integer 0

Indicates whether the cluster is locked and can be deleted. Valid values:

  • 0: The cluster is not locked and can be deleted.
  • 1: The cluster is locked and cannot be deleted.
Engine String POLARDB

The engine of the cluster.

ExpireTime String 2019-09-14T16:00:00Z

The expiration time of the cluster.

Note A specific value will be returned only for subscription clusters. For pay-as-you-go clusters, an empty string will be returned.
Expired String false

Indicates whether the cluster expired.

Note A specific value will be returned only for subscription clusters.
IsDeleted Integer 1

Indicates whether the cluster was deleted. Valid values:

  • 1: deleted
  • 0: not deleted
LockMode String Unlock

The lock mode of the cluster. Valid values:

  • Unlock: The instance is not locked.
  • ManualLock: The instance is manually locked.
  • LockByExpiration: The cluster is automatically locked after the cluster expires.
PayType String Postpaid

The billing method. Valid values:

  • Postpaid: pay-as-you-go
  • Prepaid: subscription
RegionId String cn-hangzhou

The ID of the region.

VpcId String vpc-******************

The ID of the virtual private cloud (VPC).

ZoneId String cn-hangzhou-h

The zone ID of the cluster.

PageNumber Integer 1

The page number of the returned page.

PageRecordCount Integer 1

The number of clusters that are returned on the current page.

RequestId String F8529AA2-522F-4B30-B80B-8F7D39******

The ID of the request.

TotalRecordCount Integer 1

The total number of entries returned.

Examples

Sample request

http(s)://polardb.aliyuncs.com/? Action=DescribeDBClustersWithBackups
&RegionId=cn-hangzhou
&<Common request parameters>

Sample success responses

XML format

<DescribeDBClustersWithBackupsResponse>
  <TotalRecordCount>1</TotalRecordCount>
  <PageRecordCount>1</PageRecordCount>
  <RequestId>F8529AA2-522F-4B30-B80B-8F7D39******</RequestId>
  <PageNumber>1</PageNumber>
  <Items>
        <DBCluster>
              <IsDeleted>1</IsDeleted>
              <ZoneId>cn-hangzhou-h</ZoneId>
              <DeletedTime>2020-05-12T03:25:37Z</DeletedTime>
              <DBClusterStatus>Deleted</DBClusterStatus>
              <CreateTime>2020-05-09T09:33:51Z</CreateTime>
              <DBClusterId>pc-****************</DBClusterId>
              <DBClusterDescription>pc-****************</DBClusterDescription>
              <PayType>Postpaid</PayType>
              <DBClusterNetworkType>VPC</DBClusterNetworkType>
              <DBType>MySQL</DBType>
              <LockMode>Unlock</LockMode>
              <DBNodeClass>polar.mysql.x4.medium</DBNodeClass>
              <DBVersion>5.6</DBVersion>
              <VpcId>vpc-*****************</VpcId>
              <RegionId>cn-hangzhou</RegionId>
              <Engine>POLARDB</Engine>
        </DBCluster>
  </Items>
</DescribeDBClustersWithBackupsResponse>

JSON format

{
	"TotalRecordCount": 1,
	"PageRecordCount": 1,
	"RequestId": "F8529AA2-522F-4B30-B80B-8F7D39******",
	"PageNumber": 1,
	"Items": {
		"DBCluster": [
			{
				"IsDeleted": 1,
				"ZoneId": "cn-hangzhou-h",
				"DeletedTime": "2020-05-12T03:25:37Z",
				"DBClusterStatus": "Deleted",
				"CreateTime": "2020-05-09T09:33:51Z",
				"DBClusterId": "pc-****************",
				"DBClusterDescription": "pc-****************",
				"PayType": "Postpaid",
				"DBClusterNetworkType": "VPC",
				"DBType": "MySQL",
				"LockMode": "Unlock",
				"DBNodeClass": "polar.mysql.x4.medium",
				"DBVersion": "5.6",
				"VpcId": "vpc-*****************",
				"RegionId": "cn-hangzhou",
				"Engine": "POLARDB"
			}
		]
	}
}

Error codes

For a list of error codes, visit the API Error Center.