Querying Database Specifications
Function
This API is used to query the database specifications of a specified DB engine version.
- Before calling this API, learn how to authenticate it.
- Before calling this API, learn about request header parameters.
URI
- Parameter description
Table 1 Parameters Parameter
Mandatory
Description
project_id
Yes
Definition
Project ID of a tenant in a region.
To obtain the value, see Obtaining a Project ID.
Constraints
N/A
Range
N/A
Default Value
N/A
database_name
Yes
Definition
DB engine name.
Constraints
N/A
Range
- MySQL
- PostgreSQL
- SQLServer
Default Value
N/A
version_name
No
Definition
Database version. For details about how to obtain the database version, see section Querying Version Information About a DB Engine.
Constraints
N/A
Range
N/A
Default Value
N/A
spec_code
No
Definition
Specification code.
Response
- Normal response
Table 2 Parameters Parameter
Type
Description
flavors
Array of objects
Definition
Indicates the DB instance specifications information list.
For details, see Table 3.
Table 3 flavors field data structure description Parameter
Type
Description
vcpus
String
Definition
Indicates the CPU size. For example, the value 1 indicates 1 vCPU.
Range
N/A
ram
Integer
Definition
Indicates the memory size in GB.
Range
N/A
id
String
Definition
Indicates the specification ID, which is unique.
Range
N/A
spec_code
String
Definition
Indicates the resource specification code. Use rds.mysql.m1.xlarge.rr as an example.
- rds: indicates the RDS product.
- mysql: indicates the DB engine.
- m1.xlarge: indicates the high memory performance specifications.
- rr: indicates read replicas (.ha indicates primary/standby DB instances).
Range
N/A
version_name
Array
Definition
Indicates the database version.
instance_mode
String
Definition
Indicates the instance type.
Range
- ha: indicates primary/standby instances.
- replica: indicates read replicas.
- single: indicates single DB instances.
az_status
Map<String, String>
Definition
Indicates the specification status in an AZ.
Range
- normal: indicates that the specifications in the AZ are available.
- unsupported: indicates that the specifications are not supported by the AZ.
- sellout: indicates that the specifications in the AZ are sold out.
az_desc
Map<String, String>
Definition
Indicates the description of the AZ to which the specifications belong.
Range
N/A
group_type
String
Definition
Indicates instance specifications.
Range
- general: general-purpose
- dedicated: dedicated
- highPerformancePrivilegeEdition: ultra-high I/O (advanced)
- Example normal response
{ "flavors": [{ "vcpus": "1", "ram": 2, "id":"2988b9cc-2aac-3a94-898c-14666702f129", "spec_code": "rds.mysql.c2.medium.ha", "version_name": ["5.7","8.0"], "instance_mode": "ha", "az_status": { "az1": "normal" }, "az_desc": { "az1": "az1" }, "group_type": "general" }, { "vcpus": "1", "ram": 2, "id":"2988b9cc-2aac-3a94-898c-14666702f130", "spec_code": "rds.mysql.c2.medium.rr", "version_name": ["5.7","8.0"], "instance_mode": "replica", "az_status": { "az1": "normal" }, "az_desc": { "az1": "az1" }, "group_type": "general" } ] } - Abnormal response
For details, see Abnormal Request Results.
Status Code
- Normal
- Abnormal
For details, see Status Codes.
Error Code
For details, see Error Codes.