Files
doc-exports/docs/css/api-ref/ListYmls.html
zhengxiu 8f6b8d3664 css api 25.6.0 version
Reviewed-by: Pruthi, Vineet <vineet.pruthi@t-systems.com>
Co-authored-by: zhengxiu <zhengxiu@huawei.com>
Co-committed-by: zhengxiu <zhengxiu@huawei.com>
2025-11-25 11:21:12 +00:00

8.5 KiB

Obtaining the Parameter Configuration List

Function

This API is used to obtain the YAML parameter configuration list of the current cluster.

Calling Method

For details, see Calling APIs.

URI

GET /v1.0/{project_id}/clusters/{cluster_id}/ymls/template

Table 1 Path Parameters

Parameter

Mandatory

Type

Description

project_id

Yes

String

Definition:

Project ID. For details about how to obtain the project ID and name, see Obtaining the Project ID and Name.

Constraints:

N/A

Value range:

Project ID of the account.

Default value:

N/A

cluster_id

Yes

String

Definition:

ID of the cluster you want to query. For details about how to obtain the cluster ID, see Obtaining the Cluster ID.

Constraints:

N/A

Value range:

Cluster ID.

Default value:

N/A

Request Parameters

None

Response Parameters

Status code: 200

Table 2 Response body parameters

Parameter

Type

Description

configurations

Object

Definition:

Cluster parameter configuration list.

Value range:

The key value in the object is subject to the actual situation. The value has the following attributes:

  • id: parameter ID.

  • key: parameter name.

  • value: parameter value.

  • defaultValue: parameter default value.

  • regex: parameter constraint.

  • desc: parameter description in Chinese.

  • type: parameter type description.

  • moduleDesc: parameter function description in Chinese.

  • modifyEnable: whether a parameter can be modified. true: The value can be changed. false: The value cannot be changed.

  • enableValue: parameter value that can be changed.

  • fileName: name of the file where parameters exist. The default value is elasticsearch.yml.

  • version: version information.

  • descENG: parameter description in English.

  • moduleDescENG: parameter function description in English.

Example Requests

Obtain the YAML parameter configuration list of the current cluster.

GET https://{Endpoint}/v1.0/{project_id}/clusters/5c77b71c-5b35-4f50-8984-76387e42451a/ymls/template

Example Responses

Status code: 200

Request succeeded.

{
  "configurations" : {
    "http.cors.allow-credentials" : {
      "id" : "b462d13c-294b-4e0f-91d3-58be2ad02b99",
      "key" : "http.cors.allow-credentials",
      "value" : "false",
      "defaultValue" : "false",
      "regex" : "^(true|false)$",
      "desc" : "Indicates whether to return **Access-Control-Allow-Credentials** in the header during cross-domain access. The value is of the Boolean type and can be **true** or **false**.",
      "type" : "Boolean",
      "moduleDesc" : "Cross-domain access",
      "modifyEnable" : "true",
      "enableValue" : "true,false",
      "fileName" : "elasticsearch.yml",
      "descENG" : "Whether to return the Access-Control-Allow-Credentials of the header during cross-domain access. The value is a Boolean value and the options are true and false.",
      "moduleDescENG" : "Cross-domain Access"
    }
  }
}

Status Codes

Status Code

Description

200

Request succeeded.

400

Invalid request.

Modify the request before retry.

409

The request could not be completed due to a conflict with the current state of the resource.

The resource that the client attempts to create already exists, or the update request fails to be processed because of a conflict.

412

The server did not meet one of the preconditions contained in the request.

Error Codes

See Error Codes.