You can call the DescribeAvailableClasses operation to query the specifications that are supported for an ApsaraDB RDS instance. The specifications include the instance type and the storage capacity.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | DescribeAvailableClasses |
The operation that you want to perform. Set the value to DescribeAvailableClasses. |
DBInstanceId | String | Yes | rm-uf6wjk5xxxxxx |
The ID of the instance. |
Category | String | Yes | HighAvailability |
The RDS edition that the instance runs. Valid values:
|
DBInstanceStorageType | String | Yes | local_ssd |
The type of storage media that is used by the instance. Valid values:
|
Engine | String | Yes | MySQL |
The database engine that the instance runs. Valid values:
|
EngineVersion | String | Yes | 8.0 |
The database engine version that the instance runs. Valid values:
|
InstanceChargeType | String | Yes | Prepaid |
The billing method of the instance. Valid values:
|
RegionId | String | Yes | cn-hangzhou |
The region ID of the instance. You can call the DescribeDBInstanceAttribute operation to query the region ID of an instance. |
ZoneId | String | Yes | cn-hangzhou-h |
The zone ID of the instance. You can call the DescribeDBInstanceAttribute operation to query the zone ID of an instance. |
OrderType | String | No | BUY |
The type of the order. Set the value to BUY. |
CommodityCode | String | No | bards |
The commodity code of the instance. Valid values:
Note When you query the specifications that are supported for a read-only instance, you
must specify the CommodityCode parameter.
|
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
DBInstanceClasses | Array of DBInstanceClass |
An array that consists of the instance types that are supported for the instance. |
|
DBInstanceClass | String | rds.mysql.c1.large |
The instance type that is supported for the instance. |
DBInstanceStorageRange | Struct |
The storage capacity range that is supported for the instance. |
|
MaxValue | Integer | 2000 |
The maximum storage capacity that is supported for the instance. Unit: GB. |
MinValue | Integer | 5 |
The minimum storage capacity that is supported for the instance. Unit: GB. |
Step | Integer | 5 |
The minimum increment at which you can adjust the storage capacity of the instance. The increment is 5 GB. |
RequestId | String | 7E4448A6-9FE6-4474-A0C1-AA7CFC772CAC |
The ID of the request. |
Examples
Sample requests
http(s)://rds.aliyuncs.com/? Action=DescribeAvailableClasses
&DBInstanceId=rm-uf6wjk5xxxxxx
&Category=HighAvailability
&DBInstanceStorageType=local_ssd
&Engine=MySQL
&EngineVersion=8.0
&InstanceChargeType=Prepaid
&RegionId=cn-hangzhou
&ZoneId=cn-hangzhou-h
&<Common request parameters>
Sample success responses
XML
format
<DescribeAvailableClassesResponse>
<DBInstanceClasses>
<DBInstanceClass>rds.mysql.c1.large</DBInstanceClass>
<DBInstanceStorageRange>
<MinValue>5</MinValue>
<MaxValue>2000</MaxValue>
<Step>5</Step>
</DBInstanceStorageRange>
</DBInstanceClasses>
<DBInstanceClasses>
<DBInstanceClass>rds.mysql.st.v52</DBInstanceClass>
<DBInstanceStorageRange>
<MinValue>1000</MinValue>
<MaxValue>6000</MaxValue>
<Step>5</Step>
</DBInstanceStorageRange>
</DBInstanceClasses>
<RequestId>7E4448A6-9FE6-4474-A0C1-AA7CFC772CAC</RequestId>
</DescribeAvailableClassesResponse>
JSON
format
{
"DBInstanceClasses": [
{
"DBInstanceClass": "rds.mysql.c1.large",
"DBInstanceStorageRange": {
"MinValue": 5,
"MaxValue": 2000,
"Step": 5
}
},
{
"DBInstanceClass": "rds.mysql.st.v52",
"DBInstanceStorageRange": {
"MinValue": 1000,
"MaxValue": 6000,
"Step": 5
}
}
],
"RequestId": "7E4448A6-9FE6-4474-A0C1-AA7CFC772CAC"
}
Error codes
For a list of error codes, visit the API Error Center.