ListInstances - 获取实例列表

获取实例列表。

接口说明

方法

GET

URI

/openapi/ha3/instances

调试

您可以在OpenAPI Explorer中直接运行该接口,免去您计算签名的困扰。运行成功后,OpenAPI Explorer可以自动生成SDK代码示例。

调试

授权信息

下表是API对应的授权信息,可以在RAM权限策略语句的Action元素中使用,用来给RAM用户或RAM角色授予调用此API的权限。具体说明如下:

  • 操作:是指具体的权限点。

  • 访问级别:是指每个操作的访问级别,取值为写入(Write)、读取(Read)或列出(List)。

  • 资源类型:是指操作中支持授权的资源类型。具体说明如下:

    • 对于必选的资源类型,用前面加 * 表示。

    • 对于不支持资源级授权的操作,用全部资源表示。

  • 条件关键字:是指云产品自身定义的条件关键字。

  • 关联操作:是指成功执行操作所需要的其他权限。操作者必须同时具备关联操作的权限,操作才能成功。

操作

访问级别

资源类型

条件关键字

关联操作

searchengine:ListInstances

get

*Instance

acs:searchengine:{#regionId}:{#accountId}:instance/*

请求语法

GET /openapi/ha3/instances HTTP/1.1

请求参数

名称

类型

必填

描述

示例值

pageNumber

integer

指定页码,默认为:1

1

pageSize

integer

指定每页展示条数,默认为 10,限制:[1-50]

10

instanceId

string

实例 id

ha-cn-pl32rf0****

description

string

通过实例描述称进行过滤,支持模糊匹配。

问天引擎实例

resourceGroupId

string

资源组 id。

rg-aekzgpiswzbksdi

edition

string

实例类型,vector(向量索引版),engine(召回引擎版)

vector

tags

array<object>

标签。

object

实例标签。

key

string

标签键

opensearch

value

string

标签值

opensearch

catalog

string

database

string

table

string

dataSourceType

string

参数类型是否必需描述
statusString通过实例状态进行过滤。Running, Ready, Initializing,Starting
expiredTimeLong秒级时间戳,通过过期时间过滤,大于当前时间会过滤出即将过期的实例(不包含已经过期的实例)

示例

请求示例

GET /openapi/ha3/instances?name=test&instanceId=abc&page=1&size=10

返回参数

名称

类型

描述

示例值

object

Schema of Response

result

array<object>

返回结果

object

InstanceItemType

description

string

实例描述

应急测试

resourceGroupId

string

资源组 ID

ha-cn-pl32rf0****

expiredTime

string

到期时间

1634885083

commodityCode

string

商品 code

opensearch_ha3post_public_cn

status

string

状态

READY

instanceId

string

资源一级 ID

ha-cn-pl32rf0****

createTime

string

创建时间

2022-06-04T02:03:21Z

lockMode

string

锁定状态

Unlock

chargeType

string

付费类型

POSTPAY

updateTime

string

更新时间

2018-12-06T11:17:49.0

inDebt

boolean

是否欠费

false

network

object

网络搜索引擎实例信息

vSwitchId

string

虚拟交换机 id

vsw-bp11ldcf59q2n****

vpcId

string

vpc 网络 id

vpc-wz9axk41d9vff****

endpoint

string

网关接入点。

ha-cn-35t3r****.ha.aliyuncs.com

publicEndpoint

string

公网域名

ha-cn-35t3ni****.public.ha.aliyuncs.com

allow

string

公网域名白名单

127.0.0.1

tags

array<object>

标签。

object

标签。

key

string

标签键

opensearch

value

string

标签值

opensearch

edition

string

实例版本 -vector: 向量检索版 -engine:召回引擎版

vector

userName

string

用户名

admin

version

string

引擎版本号

ha3_3.10.0

noQrs

boolean

是否是单节点实例

false

spec

object

节点规格

qrsResource

object

查询节点规格

category

string

机型 -local_ssd:本地 SSD 盘型 -cloud: 云盘型

local_ssd

cpu

integer

CPU 核数。

1

mem

integer

内存,单位:G。

10

disk

integer

节点存储空间大小,单位:GB。

100

nodeCount

integer

节点数量

3

searchResource

object

数据节点规格

category

string

机型 -local_ssd:本地 SSD 盘型 -cloud: 云盘型

local_ssd

cpu

integer

CPU 核数。

1

mem

integer

内存,单位:G。

10

disk

integer

节点存储空间大小,单位:GB。

100

nodeCount

integer

节点数量

3

dataSourceDetails

array<object>

object

indexName

string

type

string

config

object

endpoint

string

accessKey

string

project

string

partition

string

table

string

namespace

string

path

string

ossPath

string

bucket

string

catalog

string

database

string

tag

string

totalCount

integer

总记录数。

5

requestId

string

请求 ID

89B968E6-1E41-58DF-BB25-5F98ECC759CE

返回示例

正常返回示例

{
    "result":
    [
        {
            "inDebt": false,
            "lockMode": "Unlock",
            "trFreeUrl": "",
            "chargeType": "POSTPAY",
            "edition": "engine",
            "description": "测试实例",
            "updateTime": "2024-05-06 14:08:24.0",
            "userName": "admin",
            "version": "ha3_3.10.0",
            "spec":
            {
                "qrsResource":
                {
                    "category": "local_ssd",
                    "cpu": 2,
                    "mem": 8,
                    "disk": 100,
                    "nodeCount": 5
                },
                "searchResource":
                {
                    "category": "local_ssd",
                    "cpu": 2,
                    "mem": 16,
                    "disk": 100,
                    "nodeCount": 4
                }
            },
            "network":
            {
                "vSwitchId": "vsw-bp179zkffzyva26ua8xil",
                "vpcId": "vpc-bp1956duqqe2lm2lvqjf1",
                "endpoint": "ha-cn-35t3ni61z06.ha.aliyuncs.com",
                "publicEndpoint": "ha-cn-35t3ni61z06.public.ha.aliyuncs.com",
                "allow": "127.0.0.1"
            },
            "tags":
            [
                {
                    "value": "rg-acfmv2hk2jpsxia",
                    "key": "acs:rm:rgId"
                }
            ],
            "noQrs": false,
            "instanceId": "ha-cn-35t3ni61z06",
            "createTime": "2024-03-14 10:49:32.0",
            "commodityCode": "opensearch_ha3post_public_cn",
            "resourceGroupId": "rg-acfmv2hk2jpsxia",
            "status": "READY"
        }
    ],
    "requestId": "949FDF5E-6FF6-13B9-A196-59B25F143B7F",
    "totalCount": 1
}

异常返回示例

{
  "requestId": "BD1EA715-DF6F-06C2-004C-C1FA0D3A9820",
  "httpCode": 404,
  "code": "App.NotFound",
  "message": "App not found"
}

示例

正常返回示例

JSON格式

{
  "result": [
    {
      "description": "应急测试",
      "resourceGroupId": "ha-cn-pl32rf0****",
      "expiredTime": "1634885083",
      "commodityCode": "opensearch_ha3post_public_cn",
      "status": "READY",
      "instanceId": "ha-cn-pl32rf0****",
      "createTime": "2022-06-04T02:03:21Z",
      "lockMode": "Unlock",
      "chargeType": "POSTPAY",
      "updateTime": "2018-12-06T11:17:49.0",
      "inDebt": false,
      "network": {
        "vSwitchId": "vsw-bp11ldcf59q2n****",
        "vpcId": "vpc-wz9axk41d9vff****",
        "endpoint": "ha-cn-35t3r****.ha.aliyuncs.com",
        "publicEndpoint": "ha-cn-35t3ni****.public.ha.aliyuncs.com",
        "allow": "127.0.0.1"
      },
      "tags": [
        {
          "key": "opensearch",
          "value": "opensearch"
        }
      ],
      "edition": "vector",
      "userName": "admin",
      "version": "ha3_3.10.0",
      "noQrs": false,
      "spec": {
        "qrsResource": {
          "category": "local_ssd",
          "cpu": 1,
          "mem": 10,
          "disk": 100,
          "nodeCount": 3
        },
        "searchResource": {
          "category": "local_ssd",
          "cpu": 1,
          "mem": 10,
          "disk": 100,
          "nodeCount": 3
        }
      },
      "dataSourceDetails": [
        {
          "indexName": "",
          "type": "",
          "config": {
            "endpoint": "",
            "accessKey": "",
            "project": "",
            "partition": "",
            "table": "",
            "namespace": "",
            "path": "",
            "ossPath": "",
            "bucket": "",
            "catalog": "",
            "database": "",
            "tag": ""
          }
        }
      ]
    }
  ],
  "totalCount": 5,
  "requestId": "89B968E6-1E41-58DF-BB25-5F98ECC759CE"
}

错误码

访问错误中心查看更多错误码。

变更历史

更多信息,参考变更详情