Obtaining All DB Instance Specifications

Function

This API is used to obtain all instance specifications of a specified database version ID in a specified region.

URI

  • URI format

    PATH: /rds/v1/{project_id}/flavors

    Method: GET

  • Parameter description

    Table 1 Parameter description

    Name

    Mandatory

    Description

    project_id

    Yes

    Specifies the project ID of a tenant in a region.

Request

  • Parameter description

    Table 2 Parameter description

    Name

    Mandatory

    Description

    dbId

    Yes

    Specifies the database version ID (dataStores.id in the response message in Database Version Queries).

    Valid value: The value cannot be empty. The string length and whether the string complying with UUID regular expression rules are verified.

    region

    Yes

    Specifies the region where the DB instance is deployed.

    Valid value:

    The value cannot be empty. For details about how to obtain this parameter value, see Regions and Endpoints.

  • Request example

    /rds/v1/375d8d8fad1f43039e23d3b6c0f60a19/flavors?dbId=e8a8b8cc-63f8-4fb5-8d4a-24c502317a6&region=eu-de
    

Normal Response

  • Parameter description

    Table 3 Parameter description

    Name

    Type

    Description

    flavors

    List data structure. For details, see Table 4.

    Indicates the DB instance specifications information list.

    Table 4 flavors field data structure description

    Name

    Type

    Description

    id

    String

    Indicates the specification ID. Its value is unique.

    name

    String

    Indicates the specification item name.

    ram

    Int

    Indicates the memory size in megabytes (MB).

    specCode

    String

    Indicates the resource specification code.

    Use rds.mysql.m1.xlarge as an example.

    rds indicates RDS, mysql indicates the DB engine, and m1.xlarge indicates the performance specification (large-memory).

  • Response example

    {
        "flavors": [
            {
                "id": "bf07a6d4-844a-4023-a776-fc5c5fb71fb4",
                "name": "OTC_MYHP_LARGE",
                "ram": 4096,
                "specCode": "rds.mysql.c2.large"
            },
            {
                "id": "f7f51f85-cfcd-4409-ae91-b3eae186d0ea",
                "name": "OTC_MYLM_XLARGE",
                "ram": 32768,
                "specCode": "rds.mysql.m1.xlarge"
            }
        ]
    }
    

Abnormal Response

For details, see Abnormal Request Results.