tencent cloud

APIs

DescribeInstances

下载
聚焦模式
字号
最后更新时间: 2026-10-28 10:18:27

1. API Description

Domain name for API request: cynosdb.intl.tencentcloudapi.com.

This API is used to query the instance list.

A maximum of 1000 requests can be initiated per second for this API.

We recommend you to use API Explorer
Try it
API Explorer provides a range of capabilities, including online call, signature authentication, SDK code generation, and API quick search. It enables you to view the request, response, and auto-generated examples.

2. Input Parameters

The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.

Parameter Name Required Type Description
Action Yes String Common Params. The value used for this API: DescribeInstances.
Version Yes String Common Params. The value used for this API: 2019-01-07.
Region Yes String Common Params. For more information, please see the list of regions supported by the product. This API only supports: ap-bangkok, ap-beijing, ap-chengdu, ap-chongqing, ap-guangzhou, ap-hongkong, ap-jakarta, ap-nanjing, ap-seoul, ap-shanghai, ap-shenzhen-fsi, ap-singapore, ap-tokyo, eu-frankfurt, na-ashburn, na-siliconvalley, sa-saopaulo.
Limit No Integer Number of returns. Default value: 20. Value range: (0, 100].
Offset No Integer Record offset. Default value: 0.
OrderBy No String Sorting field. Valid values:
  • CREATETIME: creation time
  • PERIODENDTIME: Expiration time
  • OrderByType No String Sorting type. Valid values:
  • ASC: ascending order
  • DESC: sort in descending order
  • Filters.N No Array of QueryFilter Search criteria. When multiple filters exist, the relationship between filters is logical AND.
    DbType No String Engine type. Currently, MYSQL is supported.
    Status No String Instance status. Available values:
    creating
    running
    isolating
    isolated
    Recovering
    offlining
    offlined
    InstanceIds.N No Array of String Instance ID list
    ClusterType No String Cluster type. Value range:
  • CYNOSDB: transactional cluster
  • LIBRADB: analysis cluster
  • ALL: all
  • . Defaults to ALL.

    3. Output Parameters

    Parameter Name Type Description
    TotalCount Integer Number of instances
    InstanceSet Array of CynosdbInstance Instance list
    RequestId String The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.

    4. Example

    Example1 Querying the Instance List

    This example shows you how to query the instance list.

    Input Example

    POST / HTTP/1.1
    Host: cynosdb.intl.tencentcloudapi.com
    Content-Type: application/json
    X-TC-Action: DescribeInstances
    <Common request parameters>
    
    {
        "Limit": 20,
        "Offset": 0,
        "OrderBy": "CREATETIME",
        "OrderByType": "ASC",
        "Filters": [
            {
                "Names": [
                    "status"
                ],
                "Values": [
                    "running"
                ],
                "ExactMatch": true,
                "Name": "",
                "Operator": ""
            }
        ],
        "DbType": "MYSQL",
        "Status": "running",
        "InstanceIds": [
            "cynosdbmysql-ins-1asd5qwe"
        ]
    }

    Output Example

    {
        "Response": {
            "TotalCount": 0,
            "InstanceSet": [
                {
                    "Uin": "238762734",
                    "AppId": 23762834,
                    "ClusterId": "cynosdbmysql-asd45qwe",
                    "ClusterName": "MyClusterName",
                    "InstanceId": "cynosdbmysql-ins-asd45qwe",
                    "InstanceName": "MyInstanceName",
                    "ProjectId": 2342,
                    "Region": "ap-guangzhou",
                    "Zone": "ap-guangzhou-3",
                    "Status": "running",
                    "StatusDesc": "running",
                    "DbMode": "NORMAL",
                    "DbType": "MYSQL",
                    "DbVersion": "5.7",
                    "Cpu": 1,
                    "Memory": 1,
                    "Storage": 10,
                    "InstanceType": "rw",
                    "InstanceRole": "master",
                    "UpdateTime": "2020-09-22 00:00:00",
                    "CreateTime": "2020-09-22 00:00:00",
                    "VpcId": "vpc-12as56",
                    "SubnetId": "subnet-12kasd",
                    "Vip": "192.0.2.1",
                    "Vport": 3306,
                    "PayMode": 0,
                    "PeriodEndTime": "2020-09-22 00:00:00",
                    "DestroyDeadlineText": "<5 days",
                    "IsolateTime": "2020-09-22 00:00:00",
                    "NetType": 1,
                    "WanDomain": "cynosdbpg-bzkxxrmt.wan.domain.com",
                    "WanIP": "3.1.5.2",
                    "WanPort": 3306,
                    "WanStatus": "running",
                    "DestroyTime": "2024-01-04 00:09:10",
                    "CynosVersion": "2.0.10",
                    "ProcessingTask": "taskUpgradeStorage",
                    "RenewFlag": 0,
                    "MinCpu": 1,
                    "MaxCpu": 8,
                    "ServerlessStatus": "paused",
                    "StorageId": "cynosdbpg-bzkxxrmt",
                    "StoragePayMode": 0,
                    "PhysicalZone": "ap-guangzhou-3",
                    "BusinessType": "bus_a",
                    "Tasks": [
                        {
                            "TaskId": 111110,
                            "TaskType": "taskCreateClusters",
                            "TaskStatus": "running",
                            "ObjectId": "cynosdbmysql-asd45qwe",
                            "ObjectType": "cluster"
                        }
                    ],
                    "IsFreeze": "no",
                    "ResourceTags": [
                        {
                            "TagKey": "tag_key_1",
                            "TagValue": "tag_value_1"
                        }
                    ],
                    "MasterZone": "ap-guangzhou-3",
                    "SlaveZones": [
                        "ap-guangzhou-4"
                    ],
                    "InstanceNetInfo": [
                        {
                            "InstanceGroupType": "ha",
                            "InstanceGroupId": "cynosdbmysql-grp-asd45qwe",
                            "VpcId": "vpc-12as45",
                            "SubnetId": "subnet-cbhs7ush",
                            "NetType": 1,
                            "Vip": "192.0.0.0",
                            "Vport": 3306,
                            "WanDomain": "cynosdbpg-bzkxxrmt.wan,domain,com",
                            "WanIP": "23.15.5.1",
                            "WanPort": 3306,
                            "WanStatus": "running"
                        }
                    ],
                    "ResourcePackages": [
                        {
                            "DeductionPriority": 0,
                            "PackageId": "package-bhsy2snc",
                            "PackageType": "CCU"
                        }
                    ],
                    "CynosVersionTag": "stable",
                    "InstanceIndexMode": "onlyRowIndex"
                }
            ],
            "RequestId": "fd5759b5-89e9-483c-b79c-d99b27c33192"
        }
    }

    5. Developer Resources

    SDK

    TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.

    Command Line Interface

    6. Error Code

    The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.

    Error Code Description
    FailedOperation.CamCheckResourceError Failed to obtain permissions. Try again later. If the issue persists, contact customer service.
    FailedOperation.CamSigAndAuthError Authentication failed. Try again later. If the issue persists, contact customer service.
    FailedOperation.DatabaseAccessError Database access failed. Try again later. If the issue persists, contact customer service.
    InternalError.DbOperationFailed Query database failed.
    InternalError.InternalHttpServerError http request execution error.
    InternalError.SystemError Internal system error.
    InternalError.UnknownError Unknown internal error.
    InvalidParameter Parameter error.
    InvalidParameterValue.IllegalOrderBy Invalid sorting field.
    InvalidParameterValue.InvalidParameterValueError Parameter value is invalid.
    InvalidParameterValue.ParamBothSetError Both parameters cannot be set simultaneously.
    InvalidParameterValue.ParamError Parameter error.
    UnauthorizedOperation.PermissionDenied CAM authentication failed.

    帮助和支持

    本页内容是否解决了您的问题?

    填写满意度调查问卷,共创更好文档体验。

    文档反馈