All Products
Search
Document Center

ApsaraDB for SelectDB:DescribeDBInstances

Last Updated:Jul 30, 2025

Queries the details of one or more instances.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that support authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

selectdb:DescribeDBInstances

list

*All Resource

*

None None

Request parameters

Parameter

Type

Required

Description

Example

ResourceGroupId

string

No

The ID of the resource group.

rg-4690g37929****

DBInstanceIds

string

No

The instance ID. You can specify multiple instance IDs. Separate them with commas (,).

selectdb-cn-7213cjv****

DBInstanceStatus

string

No

The state of the instance. Valid values:

  • CREATING: The instance is being created.

  • ACTIVATION: The instance is running.

  • RESOURCE_CHANGING: The instance is being upgraded or downgraded.

  • ORDER_PREPARING: The order is being confirmed.

  • READONLY_RESOURCE_CHANGING: The resources of the instance are being changed. The instance is write-locked.

  • DELETING: The instance is being deleted.

ACTIVATION

DBInstanceDescription

string

No

The description of the instance.

新建实例测试

PageSize

integer

No

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

  • 30 (default)

  • 50

  • 100

30

PageNumber

integer

No

The page number.

1

RegionId

string

Yes

The region ID.

cn-hangzhou

Tag

array<object>

No

The list of instance tags.

object

No

The list of instance tags.

Key

string

No

The tag key.

testKey

Value

string

No

The tag value.

testValue

Response parameters

Parameter

Type

Description

Example

object

Schema of Response

RequestId

string

The request ID.

BC854513-E85E-54F3-9842-B9CCD3308CDD

PageNumber

integer

The number of entries per page. Valid values:

  • 30 (default)

  • 50

  • 100

30

PageSize

integer

The page number.

1

TotalRecordCount

integer

The total number of entries.

2

Items

array<object>

The details of the instances.

object

The details of the instances.

connectionString

string

The endpoint.

暂不返回

DBInstanceId

string

The instance ID.

selectdb-cn-7213cjv****

Description

string

The description of the instance.

新建实例测试

Engine

string

The database engine.

selectdb

EngineVersion

string

The database engine version.

2.4

InstanceUsedType

string

The instance usage type.

Instance

RegionId

string

The region ID.

cn-hangzhou

ZoneId

string

The zone ID.

cn-hangzhou-i

ChargeType

string

The billing method of the instance. Valid values:

  • Postpaid: pay-as-you-go

  • Prepaid: subscription

PrePaid

Category

string

The instance edition. The default value is basic.

basic

Status

string

The state of the instance. Valid values:

  • CREATING: The instance is being created.

  • ACTIVATION: The instance is running.

  • RESOURCE_CHANGING: The instance is being upgraded or downgraded.

  • ORDER_PREPARING: The order is being confirmed.

  • READONLY_RESOURCE_CHANGING: The resources of the instance are being changed. The instance is write-locked.

  • DELETING: The instance is being deleted.

ACTIVATION

VpcId

string

The VPC ID.

vpc-bp175iuvg8nxqraf2****

VswitchId

string

The vSwitch ID.

vsw-bp1gzt31twhlo0sa5****

ResourceCpu

integer

The number of CPU cores of the resource.

8

ResourceMemory

integer

The memory size of the resource.

64

ScaleMin

integer

The minimum value of the auto-scaling range for RDS Capacity Units (RCUs) of the instance.

0

ScaleMax

integer

The maximum value of the auto-scaling range for RDS Capacity Units (RCUs) of the instance.

0

ScaleReplica

integer

This parameter is redundant.

StorageSize

integer

The storage capacity.

100

StorageType

string

The storage class of the instance.

cloud_essd

ObjectStoreSize

integer

The storage capacity of the instance. Unit: GB.

200

ExpireTime

string

The expiration time of the cluster.

Note

This parameter is returned only for subscription (Prepaid) clusters. For pay-as-you-go (Postpaid) clusters, an empty value is returned.

2024-03-29T03:47:05Z

LockMode

integer

The lock mode of the instance.

0

LockReason

string

The reason why the instance is locked.

nolock

IsDeleted

boolean

Indicates whether the instance is deleted. Valid values:

  • true: The instance is deleted.

  • false: The instance is not deleted.

false

MaintainStarttime

string

The start time of the maintenance window for the instance.

保留参数,暂不返回

MaintainEndtime

string

The end time of the maintenance window for the instance.

保留参数,暂不返回

GmtCreated

string

The time when the task was created. The time is in GMT.

2023-08-12T04:14Z

GmtModified

string

The time when the task was last modified. The time is in GMT.

2023-08-12T19:05Z

ParentInstance

string

The time when the instance was created.

保留参数,暂不返回

ResourceGroupId

string

The ID of the resource group.

保留参数,暂不返回

MaintainStartTimeStr

string

The start timestamp of the maintenance window.

保留参数,暂不返回

MaintainEndTimeStr

string

The end timestamp of the maintenance window.

保留参数,暂不返回

TenantClusterId

string

The ID of the Prometheus monitoring cluster.

保留参数,暂不返回

TenantToken

string

The access token for Prometheus monitoring.

保留参数,暂不返回

TenantUserId

string

The user account label for Prometheus monitoring.

保留参数,暂不返回

Tags

array<object>

A list of instance tags.

object

A list of instance tags.

TagKey

string

The tag key.

testKey

TagValue

string

The tag value.

testValue

ClusterCount

integer

The total number of clusters.

1

DeployScheme

string

The deployment mode of the instance:

  • multi_az: Zone-redundant storage.

  • single_az: Locally redundant storage.

single_az

MultiZone

array<object>

The multi-zone configuration.

object

The list of multi-zones.

ZoneId

string

The zone ID.

cn-beijing-k

VSwitchIds

array

A list of vSwitch IDs.

string

The vSwitch ID.

vsw-bp1pla4vl8bs9uw9c7l2w

EngineMinorVersion

string

The minor engine version of the instance.

4.0.4

Examples

Success response

JSON format

{
  "RequestId": "BC854513-E85E-54F3-9842-B9CCD3308CDD",
  "PageNumber": 30,
  "PageSize": 1,
  "TotalRecordCount": 2,
  "Items": [
    {
      "connectionString": "暂不返回",
      "DBInstanceId": "selectdb-cn-7213cjv****",
      "Description": "新建实例测试",
      "Engine": "selectdb",
      "EngineVersion": "2.4",
      "InstanceUsedType": "Instance",
      "RegionId": "cn-hangzhou",
      "ZoneId": "cn-hangzhou-i",
      "ChargeType": "PrePaid",
      "Category": "basic",
      "Status": "ACTIVATION",
      "VpcId": "vpc-bp175iuvg8nxqraf2****",
      "VswitchId": "vsw-bp1gzt31twhlo0sa5****",
      "ResourceCpu": 8,
      "ResourceMemory": 64,
      "ScaleMin": 0,
      "ScaleMax": 0,
      "ScaleReplica": 0,
      "StorageSize": 100,
      "StorageType": "cloud_essd",
      "ObjectStoreSize": 200,
      "ExpireTime": "2024-03-29T03:47:05Z",
      "LockMode": 0,
      "LockReason": "nolock",
      "IsDeleted": false,
      "MaintainStarttime": "保留参数,暂不返回",
      "MaintainEndtime": "保留参数,暂不返回",
      "GmtCreated": "2023-08-12T04:14Z\n",
      "GmtModified": "2023-08-12T19:05Z",
      "ParentInstance": "保留参数,暂不返回",
      "ResourceGroupId": "保留参数,暂不返回",
      "MaintainStartTimeStr": "保留参数,暂不返回",
      "MaintainEndTimeStr": "保留参数,暂不返回",
      "TenantClusterId": "保留参数,暂不返回\n",
      "TenantToken": "保留参数,暂不返回\n",
      "TenantUserId": "保留参数,暂不返回\n",
      "Tags": [
        {
          "TagKey": "testKey",
          "TagValue": "testValue"
        }
      ],
      "ClusterCount": 1,
      "DeployScheme": "single_az",
      "MultiZone": [
        {
          "ZoneId": "cn-beijing-k",
          "VSwitchIds": [
            "vsw-bp1pla4vl8bs9uw9c7l2w"
          ]
        }
      ],
      "EngineMinorVersion": "4.0.4"
    }
  ]
}

Error codes

HTTP status code

Error code

Error message

Description

400 InvalidPageNumber.Malformed The specified parameter "PageNumber" is not valid. The number of records per page parameter is illegal.
400 DocumentConvertFailed.ExceedFileSizeLimit The conversion has been failed, exceed file size limit. english description1
400 Forbidden User not authorized to operate on the specified resource, or this API does not support RAM. english description1
400 InvalidDBName The specified database name is not allowed. english description1
400 CreateOrderFailed Failed to create order. Failed to create order.
403 DBClusterNotSupported The requested operation can not be performed while the cluster is not sale. The requested operation cannot be performed while the cluster is not running.
403 IncorrectDBInstanceState Current DB instance state does not support this operation. english description1
403 InstanceEngineType.NotSupport The instance engine and type does not support operations. english description1
403 InvalidDBInstanceState.NotSupport The specified instance state does't support this operation. The instance is in a state that does not support the current operation.
403 MoneyLessThan100 The Account Monet less Than 100. english description1
403 OperationDenied.DBNameAndAccountPrivilegeCount The operation is not permitted due to count of database or account privilege. english description1
403 InsufficientResourceCapacity The resource is out of usage. Not enough resources, please try again later.
404 DBInstanceLocked The current instance lock mode does not support this operation. english description1
404 IncorrectVswitchId The specified parameter VSwitchId is not valid. english description1
404 InvalidApi.NotFound Specified api is not found, please check your url and method.
404 InvalidDBInstance.NotFound The specified instance is not found. english description1
404 InvalidDBInstanceClass.NotFound The specified instance classic does not exist. english description1
404 InvalidRegionId.NotFound The provided RegionId does not exist in our records. english description1
404 QueryPrice.Failed The inquiry failed. Contact Alibaba Cloud customer service representatives. english description1

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.