云数据库 GEMINIDB-查询资源实例:请求示例

时间:2023-11-22 09:18:52

请求示例

  • URI样例
    POST https://gaussdb-nosql.cn-north-4.myhuaweicloud.com/v3/375d8d8fad1f43039e23d3b6c0f60a19/instances/resource-instances/action
  • 请求体样例

    根据实例名称查询实例,索引位置偏移量为100,查询100条数据

    {
      "offset" : 100,
      "limit" : 100,
      "action" : "filter",
      "matches" : [{
        "key" : "instance_name",
        "value" : "test-single"
      }],
      "tags" : [{
        "key" : "key1",
        "values" : [ "value1", "value2" ]
      }]
    }

    查询总记录数

    {
      "action" : "count",
      "tags" : [ {
        "key" : "key1",
        "values" : [ "value1", "value2" ]
      }, {
        "key" : "key2",
        "values" : [ "value1", "value2" ]
      } ],
      "matches" : [ {
        "key" : "instance_name",
        "value" : "test-single"
      }, {
        "key" : "instance_id",
        "value" : "958693039f284d6ebfb177375711072ein06"
      } ]
    }
support.huaweicloud.com/api-nosql/ListInstancesByResourceTags.html