All Products
Search
Document Center

OpenSearch:GetIndexVersion

Last Updated:Oct 16, 2024

Queries the information about index versions that the current index version can be rolled back to.

Operation description

Method

GET

URI

/openapi/ha3/instances/{instanceId}/clusters/{clusterName}/index-version

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • The required resource types are displayed in bold characters.
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
searchengine:GetIndexVersionget
  • Instance
    acs:searchengine:{#regionId}:{#accountId}:instance/{#InstanceId}
    none
none

Request syntax

GET /openapi/ha3/instances/{instanceId}/clusters/{clusterName}/index-version HTTP/1.1

Request parameters

ParameterTypeRequiredDescriptionExample
instanceIdstringYes

The instance ID.

ha-cn-2r42ostoc01
clusterNamestringYes

The name of the cluster

vpc_hz_domain_1

Examples

Sample requests

GET  /openapi/ha3/instances/ha3_instance_id_1/clusters/cluster1/index-version

Response parameters

ParameterTypeDescriptionExample
object

The response parameters.

requestIdstring

id of request

E7B7D598-B080-5C8E-AA35-D43EC0D5F886
resultobject

The clusters.

clusterstring

The cluster name.

ayoss-cn-zhangjiakou-b
indexVersionsarray<object>

The index versions.

indexVersionsobject

The list of index versions

indexNamestring

The name of the index table.

table4
versionsarray

The index versions.

versionslong

The index version.

1
buildDeployIdstring

The ID of the offline deployment.

" "
currentVersionlong

The current online version number.

1

Sample responses

Success responses

{
  "requestId": "e1eef569-1ff7-4bf8-acf7-1cecca9894ce",
  "result": {
    "cluster": "ea119cloud",
    "indexVersions": [
      {
        "versions": [
          1630527077,
          1630440554
        ],
        "currentVersion":1630527077,
        "indexName": "ihome_lapp_content_filter_param_index",
        "buildDeployId": "2837"
      },
      {
        "versions": [
          1630353700
        ],
        "currentVersion":1630353700,        
        "indexName": "ihome_lapp_case_tab_filter",
        "buildDeployId": "2829"
      }
    ]
  }
}

Examples

Sample success responses

JSONformat

{
  "requestId": "E7B7D598-B080-5C8E-AA35-D43EC0D5F886",
  "result": {
    "cluster": "ayoss-cn-zhangjiakou-b",
    "indexVersions": [
      {
        "indexName": "table4",
        "versions": [
          1
        ],
        "buildDeployId": "\" \"",
        "currentVersion": 1
      }
    ]
  }
}

Error codes

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2022-01-12Add OperationView Change Details