Queries the list of PolarDB clusters or the details about the list of PolarDB clusters that a RAM user is authorized to access.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | No | DescribeDBClusters |
The operation that you want to perform. Set the value to DescribeDBClusters. |
RegionId | String | Yes | cn-hangzhou |
The ID of the region. Note You can call the DescribeRegions operation to query the available regions.
|
DBClusterIds | String | No | pc-**************** |
The ID of the cluster. Separate multiple cluster IDs with commas (,). |
DBClusterDescription | String | No | pc-**************** |
The description of the cluster. It supports fuzzy search. |
DBClusterStatus | String | No | Running |
The status of the cluster. For more information about valid values, see Cluster status. |
DBType | String | No | MySQL |
The type of the database. Valid values:
|
Tag.N.Key | String | No | test1 |
The tag key. It can be used as a condition to filter the list of clusters. You can specify a maximum of 20 tags. The number N in each key-value pair must be unique and must be consecutive integers that start from 1. The value of the Tag.N.Key parameter is the value of the Tag.n.Vlaue parameter. Note The value can be at most 64 characters in length and cannot start with
aliyun, acs:, http://, or https:// .
|
Tag.N.Value | String | No | 1111 |
The value of the tag. It can be used as a condition to filter clusters. You can specify a maximum of 20 tags. The number N in each key-value pair must be unique and must be consecutive integers that start from 1. The value of the Tag.N.Value parameter is the value of the Tag.N.Key parameter. Note The value can be at most 64 characters in length and cannot start with
aliyun , acs: , http:// , or https:// .
|
PageSize | Integer | No | 30 |
The number of entries to return on each page. Valid values: 30, 50, or 100. Default value: 30. |
PageNumber | Integer | No | 1 |
The number of the page to return. The value must be an integer that is larger than 0 and does not exceed the maximum value of the INTEGER data type. Default value: 1. |
ResourceGroupId | String | No | rg-********** |
The ID of the resource group. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
Items | Array of DBCluster |
The list of clusters. |
|
DBCluster | |||
CreateTime | String | 2020-08-14T05:58:42Z |
The time when the cluster was created. |
DBClusterDescription | String | test |
The description 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. |
DBNodeClass | String | polar.mysql.x4.large |
The specification of the node. |
DBNodeNumber | Integer | 2 |
The number of nodes. |
DBNodes | Array of DBNode |
The list of nodes. |
|
DBNode | |||
DBNodeClass | String | polar.mysql.x4.large |
The specification of the node. |
DBNodeId | String | pi-**************** |
The ID of the node. |
DBNodeRole | String | Reader |
The role of the node. Valid values:
|
RegionId | String | cn-hangzhou |
The ID of the region. |
ZoneId | String | cn-hangzhou-i |
The ID of the zone. |
DBType | String | MySQL |
The type of the database. |
DBVersion | String | 5.6 |
The version of the database. |
DeletionLock | Integer | 0 |
Indicates the deletion protection status of the cluster. Valid values:
|
Engine | String | POLARDB |
The engine of the cluster. |
ExpireTime | String | 2020-11-14T16:00:00Z |
The time when the cluster expires. Note A specific parameter value is returned for only subscription clusters whose payment
method is Prepaid. An empty string is returned for pay-as-you-go clusters whose payment method is Postpaid.
|
Expired | String | false |
Indicates whether the cluster has expired. Note This parameter is returned for only subscription clusters whose payment method is
Prepaid.
|
LockMode | String | Unlock |
The lock status of the cluster. Valid values:
|
PayType | String | Prepaid |
The billing method. Valid values:
|
RegionId | String | cn-hangzhou |
The ID of the region. |
ResourceGroupId | String | rg-************ |
The ID of the resource group. |
StorageUsed | Long | 3009413120 |
The storage usage. |
Tags | Array of Tag |
The list of tags. |
|
Tag | |||
Key | String | MySQL |
The tag key. |
Value | String | 5.6 |
The value of the tag. |
VpcId | String | vpc-**************** |
The ID of the VPC. |
ZoneId | String | cn-hangzhou-i |
The ID of the zone. |
PageNumber | Integer | 1 |
The page number of the returned page. |
PageRecordCount | Integer | 1 |
The number of clusters returned on the current page. |
RequestId | String | 9B7BFB11-C077-4FE3-B051-F69CEB****** |
The ID of the request. |
TotalRecordCount | Integer | 1 |
The total number of entries. |
Examples
Sample requests
http(s)://polardb.aliyuncs.com/? Action=DescribeDBClusters
&RegionId=cn-hangzhou
&<Common request parameters>
Sample success responses
XML
format
<DescribeDBClustersResponse>
<TotalRecordCount>1</TotalRecordCount>
<PageRecordCount>1</PageRecordCount>
<RequestId>9B7BFB11-C077-4FE3-B051-F69CEB******</RequestId>
<PageNumber>1</PageNumber>
<Items>
<DBCluster>
<DeletionLock>0</DeletionLock>
<ZoneId>cn-hangzhou-i</ZoneId>
<ResourceGroupId>rg-***************</ResourceGroupId>
<DBClusterStatus>Running</DBClusterStatus>
<CreateTime>2020-08-14T05:58:42Z</CreateTime>
<DBClusterId>pc-****************</DBClusterId>
<DBClusterDescription>test</DBClusterDescription>
<Expired>false</Expired>
<PayType>Prepaid</PayType>
<DBClusterNetworkType>VPC</DBClusterNetworkType>
<DBType>MySQL</DBType>
<LockMode>Unlock</LockMode>
<DBNodeClass>polar.mysql.x4.large</DBNodeClass>
<StorageUsed>3009413120</StorageUsed>
<DBVersion>5.6</DBVersion>
<DBNodeNumber>2</DBNodeNumber>
<VpcId>vpc-****************</VpcId>
<DBNodes>
<DBNode>
<ZoneId>cn-hangzhou-i</ZoneId>
<DBNodeRole>Writer</DBNodeRole>
<DBNodeId>pi-****************</DBNodeId>
<RegionId>cn-hangzhou</RegionId>
<DBNodeClass>polar.mysql.x4.large</DBNodeClass>
</DBNode>
<DBNode>
<ZoneId>cn-hangzhou-i</ZoneId>
<DBNodeRole>Reader</DBNodeRole>
<DBNodeId>pi-****************</DBNodeId>
<RegionId>cn-hangzhou</RegionId>
<DBNodeClass>polar.mysql.x4.large</DBNodeClass>
</DBNode>
</DBNodes>
<RegionId>cn-hangzhou</RegionId>
<ExpireTime>2020-11-14T16:00:00Z</ExpireTime>
<Engine>POLARDB</Engine>
<Tags>
<Tag>
<Value>5.6</Value>
<Key>MySQL</Key>
</Tag>
</Tags>
</DBCluster>
</Items>
</DescribeDBClustersResponse>
JSON
format
{
"TotalRecordCount": 1,
"PageRecordCount": 1,
"RequestId": "9B7BFB11-C077-4FE3-B051-F69CEB******",
"PageNumber": 1,
"Items": {
"DBCluster": [
{
"DeletionLock": 0,
"ZoneId": "cn-hangzhou-i",
"ResourceGroupId": "rg-***************",
"DBClusterStatus": "Running",
"CreateTime": "2020-08-14T05:58:42Z",
"DBClusterId": "pc-****************",
"DBClusterDescription": "test",
"Expired": false,
"PayType": "Prepaid",
"DBClusterNetworkType": "VPC",
"DBType": "MySQL",
"LockMode": "Unlock",
"DBNodeClass": "polar.mysql.x4.large",
"StorageUsed": 3009413120,
"DBVersion": "5.6",
"DBNodeNumber": "2",
"VpcId": "vpc-****************",
"DBNodes": {
"DBNode": [
{
"ZoneId": "cn-hangzhou-i",
"DBNodeRole": "Writer",
"DBNodeId": "pi-****************",
"RegionId": "cn-hangzhou",
"DBNodeClass": "polar.mysql.x4.large"
},
{
"ZoneId": "cn-hangzhou-i",
"DBNodeRole": "Reader",
"DBNodeId": "pi-****************",
"RegionId": "cn-hangzhou",
"DBNodeClass": "polar.mysql.x4.large"
}
]
},
"RegionId": "cn-hangzhou",
"ExpireTime": "2020-11-14T16:00:00Z",
"Engine": "POLARDB",
"Tags": {
"Tag": [
{
"Value": "5.6",
"Key": "MySQL"
}
]
}
}
]
}
}
Error codes
For a list of error codes, visit the API Error Center.