From 733affa1040f6d0b54eaad4e37685ff33ee60851 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Istv=C3=A1n=20Zolt=C3=A1n=20Szab=C3=B3?= Date: Wed, 9 Aug 2023 14:31:33 +0200 Subject: [PATCH] [DOCS] Adds descriptions to index APIs (G-Z) (#2230) Co-authored-by: Abdon Pijpelink --- output/schema/schema.json | 467 ++++++++++++------ specification/_doc_ids/table.csv | 2 + specification/indices/_types/IndexTemplate.ts | 44 +- .../get_alias/IndicesGetAliasRequest.ts | 31 ++ .../IndicesGetDataLifecycleRequest.ts | 15 + .../IndicesGetFieldMappingRequest.ts | 34 ++ .../get_mapping/IndicesGetMappingRequest.ts | 32 ++ .../get_template/IndicesGetTemplateRequest.ts | 19 + .../indices/open/IndicesOpenRequest.ts | 41 ++ .../put_alias/IndicesPutAliasRequest.ts | 45 ++ .../IndicesPutDataLifecycleRequest.ts | 27 + .../IndicesPutIndexTemplateRequest.ts | 51 +- .../put_mapping/IndicesPutMappingRequest.ts | 33 ++ .../put_template/IndicesPutTemplateRequest.ts | 12 + .../recovery/IndicesRecoveryRequest.ts | 15 + .../indices/refresh/IndicesRefreshRequest.ts | 23 + .../resolve_index/ResolveIndexRequest.ts | 13 + .../rollover/IndicesRolloverRequest.ts | 48 ++ .../segments/IndicesSegmentsRequest.ts | 28 +- .../shard_stores/IndicesShardStoresRequest.ts | 2 + .../indices/shrink/IndicesShrinkRequest.ts | 30 ++ .../IndicesSimulateIndexTemplateRequest.ts | 39 +- .../indices/split/IndicesSplitRequest.ts | 29 ++ .../indices/stats/IndicesStatsRequest.ts | 2 + .../unfreeze/IndicesUnfreezeRequest.ts | 35 ++ .../IndicesUpdateAliasesRequest.ts | 14 + specification/indices/update_aliases/types.ts | 87 +++- .../IndicesValidateQueryRequest.ts | 60 +++ 28 files changed, 1113 insertions(+), 165 deletions(-) diff --git a/output/schema/schema.json b/output/schema/schema.json index b88d3b0d58..99eaea8542 100644 --- a/output/schema/schema.json +++ b/output/schema/schema.json @@ -6866,7 +6866,8 @@ } }, "description": "Updates an alias to point to a new index when the existing index\nis considered to be too large or too old.", - "docUrl": "https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-rollover-index.html", + "docId": "indices-rollover-index", + "docUrl": "https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/indices-rollover-index.html", "name": "indices.rollover", "request": { "name": "Request", @@ -6989,7 +6990,8 @@ } }, "description": "Allow to shrink an existing index into a new index with fewer primary shards.", - "docUrl": "https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-shrink-index.html", + "docId": "indices-shrink-index", + "docUrl": "https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/indices-shrink-index.html", "name": "indices.shrink", "request": { "name": "Request", @@ -7121,7 +7123,8 @@ } }, "description": "Allows you to split an existing index into a new index with more primary shards.", - "docUrl": "https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-split-index.html", + "docId": "indices-split-index", + "docUrl": "https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/indices-split-index.html", "name": "indices.split", "request": { "name": "Request", @@ -110695,6 +110698,7 @@ }, "properties": [ { + "description": "Name of the index template.", "name": "index_patterns", "required": true, "type": { @@ -110706,6 +110710,7 @@ } }, { + "description": "An ordered list of component template names.\nComponent templates are merged in the order specified, meaning that the last component template specified has the highest precedence.", "name": "composed_of", "required": true, "type": { @@ -110720,6 +110725,7 @@ } }, { + "description": "Template to be applied.\nIt may optionally include an `aliases`, `mappings`, or `settings` configuration.", "name": "template", "required": false, "type": { @@ -110731,6 +110737,7 @@ } }, { + "description": "Version number used to manage index templates externally.\nThis number is not automatically generated by Elasticsearch.", "name": "version", "required": false, "type": { @@ -110742,6 +110749,7 @@ } }, { + "description": "Priority to determine index template precedence when a new data stream or index is created.\nThe index template with the highest priority is chosen.\nIf no priority is specified the template is treated as though it is of priority 0 (lowest priority).\nThis number is not automatically generated by Elasticsearch.", "name": "priority", "required": false, "type": { @@ -110753,6 +110761,7 @@ } }, { + "description": "Optional user metadata about the index template. May have any contents.\nThis map is not automatically generated by Elasticsearch.", "docId": "mapping-meta-field", "docUrl": "https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/mapping-meta-field.html", "name": "_meta", @@ -110777,6 +110786,7 @@ } }, { + "description": "If this object is included, the template is used to create data streams and their backing indices.\nSupports an empty object.\nData streams require a matching index template with a `data_stream` object.", "name": "data_stream", "required": false, "type": { @@ -110788,7 +110798,7 @@ } } ], - "specLocation": "indices/_types/IndexTemplate.ts#L31-L41" + "specLocation": "indices/_types/IndexTemplate.ts#L31-L70" }, { "kind": "interface", @@ -110824,7 +110834,7 @@ } } ], - "specLocation": "indices/_types/IndexTemplate.ts#L43-L54" + "specLocation": "indices/_types/IndexTemplate.ts#L72-L83" }, { "kind": "interface", @@ -110834,6 +110844,7 @@ }, "properties": [ { + "description": "Aliases to add.\nIf the index template includes a `data_stream` object, these are data stream aliases.\nOtherwise, these are index aliases.\nData stream aliases ignore the `index_routing`, `routing`, and `search_routing` options.", "name": "aliases", "required": false, "type": { @@ -110856,6 +110867,7 @@ } }, { + "description": "Mapping for fields in the index.\nIf specified, this mapping can include field names, field data types, and mapping parameters.", "name": "mappings", "required": false, "type": { @@ -110867,6 +110879,7 @@ } }, { + "description": "Configuration options for the index.", "name": "settings", "required": false, "type": { @@ -110900,7 +110913,7 @@ } } ], - "specLocation": "indices/_types/IndexTemplate.ts#L56-L65" + "specLocation": "indices/_types/IndexTemplate.ts#L85-L107" }, { "kind": "interface", @@ -116675,7 +116688,7 @@ "body": { "kind": "no_body" }, - "description": "Returns an alias.", + "description": "Retrieves information for one or more aliases.", "inherits": { "type": { "name": "RequestBase", @@ -116689,7 +116702,7 @@ }, "path": [ { - "description": "A comma-separated list of alias names to return", + "description": "Comma-separated list of aliases to retrieve.\nSupports wildcards (`*`).\nTo retrieve all aliases, omit this parameter or use `*` or `_all`.", "name": "name", "required": false, "type": { @@ -116701,7 +116714,7 @@ } }, { - "description": "A comma-separated list of index names to filter aliases", + "description": "Comma-separated list of data streams or indices used to limit the request.\nSupports wildcards (`*`).\nTo target all data streams and indices, omit this parameter or use `*` or `_all`.", "name": "index", "required": false, "type": { @@ -116715,9 +116728,10 @@ ], "query": [ { - "description": "Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified)", + "description": "If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices.\nThis behavior applies even if the request targets other open indices.", "name": "allow_no_indices", "required": false, + "serverDefault": true, "type": { "kind": "instance_of", "type": { @@ -116727,9 +116741,10 @@ } }, { - "description": "Whether to expand wildcard expression to concrete indices that are open, closed or both.", + "description": "Type of index that wildcard patterns can match.\nIf the request can target data streams, this argument determines whether wildcard expressions match hidden data streams.\nSupports comma-separated values, such as `open,hidden`.\nValid values are: `all`, `open`, `closed`, `hidden`, `none`.", "name": "expand_wildcards", "required": false, + "serverDefault": "open", "type": { "kind": "instance_of", "type": { @@ -116739,9 +116754,10 @@ } }, { - "description": "Whether specified concrete indices should be ignored when unavailable (missing or closed)", + "description": "If `false`, the request returns an error if it targets a missing or closed index.", "name": "ignore_unavailable", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -116751,9 +116767,10 @@ } }, { - "description": "Return local information, do not retrieve the state from master node (default: false)", + "description": "If `true`, the request retrieves information from the local node only.", "name": "local", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -116763,7 +116780,7 @@ } } ], - "specLocation": "indices/get_alias/IndicesGetAliasRequest.ts#L23-L39" + "specLocation": "indices/get_alias/IndicesGetAliasRequest.ts#L23-L70" }, { "body": { @@ -116876,7 +116893,7 @@ }, "path": [ { - "description": "A comma-separated list of data streams to get; use `*` to get all data streams", + "description": "Comma-separated list of data streams to limit the request.\nSupports wildcards (`*`).\nTo target all data streams, omit this parameter or use `*` or `_all`.", "name": "name", "required": true, "type": { @@ -116890,9 +116907,10 @@ ], "query": [ { - "description": "Whether wildcard expressions should get expanded to open or closed indices (default: open)", + "description": "Type of data stream that wildcard patterns can match.\nSupports comma-separated values, such as `open,hidden`.\nValid values are: `all`, `open`, `closed`, `hidden`, `none`.", "name": "expand_wildcards", "required": false, + "serverDefault": "open", "type": { "kind": "instance_of", "type": { @@ -116902,9 +116920,10 @@ } }, { - "description": "Return all relevant default configurations for the data stream (default: false)", + "description": "If `true`, return all default settings in the response.", "name": "include_defaults", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -116914,7 +116933,7 @@ } } ], - "specLocation": "indices/get_data_lifecycle/IndicesGetDataLifecycleRequest.ts#L23-L37" + "specLocation": "indices/get_data_lifecycle/IndicesGetDataLifecycleRequest.ts#L23-L52" }, { "body": { @@ -117051,7 +117070,7 @@ "body": { "kind": "no_body" }, - "description": "Returns mapping for one or more fields.", + "description": "Retrieves mapping definitions for one or more fields.\nFor data streams, the API retrieves field mappings for the stream’s backing indices.", "inherits": { "type": { "name": "RequestBase", @@ -117065,7 +117084,7 @@ }, "path": [ { - "description": "A comma-separated list of fields", + "description": "Comma-separated list or wildcard expression of fields used to limit returned information.", "name": "fields", "required": true, "type": { @@ -117077,7 +117096,7 @@ } }, { - "description": "A comma-separated list of index names", + "description": "Comma-separated list of data streams, indices, and aliases used to limit the request.\nSupports wildcards (`*`).\nTo target all data streams and indices, omit this parameter or use `*` or `_all`.", "name": "index", "required": false, "type": { @@ -117091,9 +117110,10 @@ ], "query": [ { - "description": "Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified)", + "description": "If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices.\nThis behavior applies even if the request targets other open indices.", "name": "allow_no_indices", "required": false, + "serverDefault": true, "type": { "kind": "instance_of", "type": { @@ -117103,9 +117123,10 @@ } }, { - "description": "Whether to expand wildcard expression to concrete indices that are open, closed or both.", + "description": "Type of index that wildcard patterns can match.\nIf the request can target data streams, this argument determines whether wildcard expressions match hidden data streams.\nSupports comma-separated values, such as `open,hidden`.\nValid values are: `all`, `open`, `closed`, `hidden`, `none`.", "name": "expand_wildcards", "required": false, + "serverDefault": "open", "type": { "kind": "instance_of", "type": { @@ -117115,9 +117136,10 @@ } }, { - "description": "Whether specified concrete indices should be ignored when unavailable (missing or closed)", + "description": "If `false`, the request returns an error if it targets a missing or closed index.", "name": "ignore_unavailable", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -117127,9 +117149,10 @@ } }, { - "description": "Whether the default mapping values should be returned as well", + "description": "If `true`, return all default settings in the response.", "name": "include_defaults", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -117139,9 +117162,10 @@ } }, { - "description": "Return local information, do not retrieve the state from master node (default: false)", + "description": "If `true`, the request retrieves information from the local node only.", "name": "local", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -117151,7 +117175,7 @@ } } ], - "specLocation": "indices/get_field_mapping/IndicesGetFieldMappingRequest.ts#L23-L39" + "specLocation": "indices/get_field_mapping/IndicesGetFieldMappingRequest.ts#L23-L73" }, { "body": { @@ -117412,7 +117436,7 @@ "body": { "kind": "no_body" }, - "description": "Returns mappings for one or more indices.", + "description": "Retrieves mapping definitions for one or more indices.\nFor data streams, the API retrieves mappings for the stream’s backing indices.", "inherits": { "type": { "name": "RequestBase", @@ -117426,7 +117450,7 @@ }, "path": [ { - "description": "A comma-separated list of index names", + "description": "Comma-separated list of data streams, indices, and aliases used to limit the request.\nSupports wildcards (`*`).\nTo target all data streams and indices, omit this parameter or use `*` or `_all`.", "name": "index", "required": false, "type": { @@ -117440,9 +117464,10 @@ ], "query": [ { - "description": "Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified)", + "description": "If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices.\nThis behavior applies even if the request targets other open indices.", "name": "allow_no_indices", "required": false, + "serverDefault": true, "type": { "kind": "instance_of", "type": { @@ -117452,9 +117477,10 @@ } }, { - "description": "Whether to expand wildcard expression to concrete indices that are open, closed or both.", + "description": "Type of index that wildcard patterns can match.\nIf the request can target data streams, this argument determines whether wildcard expressions match hidden data streams.\nSupports comma-separated values, such as `open,hidden`.\nValid values are: `all`, `open`, `closed`, `hidden`, `none`.", "name": "expand_wildcards", "required": false, + "serverDefault": "open", "type": { "kind": "instance_of", "type": { @@ -117464,9 +117490,10 @@ } }, { - "description": "Whether specified concrete indices should be ignored when unavailable (missing or closed)", + "description": "If `false`, the request returns an error if it targets a missing or closed index.", "name": "ignore_unavailable", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -117476,9 +117503,10 @@ } }, { - "description": "Return local information, do not retrieve the state from master node (default: false)", + "description": "If `true`, the request retrieves information from the local node only.", "name": "local", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -117488,9 +117516,10 @@ } }, { - "description": "Specify timeout for connection to master", + "description": "Period to wait for a connection to the master node.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "master_timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -117500,7 +117529,7 @@ } } ], - "specLocation": "indices/get_mapping/IndicesGetMappingRequest.ts#L24-L40" + "specLocation": "indices/get_mapping/IndicesGetMappingRequest.ts#L24-L72" }, { "body": { @@ -117707,7 +117736,7 @@ "body": { "kind": "no_body" }, - "description": "Returns an index template.", + "description": "Retrieves information about one or more index templates.", "inherits": { "type": { "name": "RequestBase", @@ -117721,7 +117750,7 @@ }, "path": [ { - "description": "The comma separated names of the index templates", + "description": "Comma-separated list of index template names used to limit the request.\nWildcard (`*`) expressions are supported.\nTo return all index templates, omit this parameter or use a value of `_all` or `*`.", "name": "name", "required": false, "type": { @@ -117735,9 +117764,10 @@ ], "query": [ { - "description": "Return settings in flat format (default: false)", + "description": "If `true`, returns settings in flat format.", "name": "flat_settings", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -117747,9 +117777,10 @@ } }, { - "description": "Return local information, do not retrieve the state from master node (default: false)", + "description": "If `true`, the request retrieves information from the local node only.", "name": "local", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -117759,9 +117790,10 @@ } }, { - "description": "Explicit operation timeout for connection to master node", + "description": "Period to wait for a connection to the master node.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "master_timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -117771,7 +117803,7 @@ } } ], - "specLocation": "indices/get_template/IndicesGetTemplateRequest.ts#L24-L38" + "specLocation": "indices/get_template/IndicesGetTemplateRequest.ts#L24-L57" }, { "body": { @@ -117992,7 +118024,7 @@ "body": { "kind": "no_body" }, - "description": "Opens an index.", + "description": "Opens a closed index.\nFor data streams, the API opens any closed backing indices.", "inherits": { "type": { "name": "RequestBase", @@ -118006,7 +118038,9 @@ }, "path": [ { - "description": "A comma separated list of indices to open", + "description": "Comma-separated list of data streams, indices, and aliases used to limit the request.\nSupports wildcards (`*`).\nBy default, you must explicitly name the indices you using to limit the request.\nTo limit a request using `_all`, `*`, or other wildcard expressions, change the `action.destructive_requires_name` setting to false.\nYou can update this setting in the `elasticsearch.yml` file or using the cluster update settings API.", + "docId": "cluster-update-settings", + "docUrl": "https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/cluster-update-settings.html", "name": "index", "required": true, "type": { @@ -118020,9 +118054,10 @@ ], "query": [ { - "description": "Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified)", + "description": "If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices.\nThis behavior applies even if the request targets other open indices.", "name": "allow_no_indices", "required": false, + "serverDefault": true, "type": { "kind": "instance_of", "type": { @@ -118032,9 +118067,10 @@ } }, { - "description": "Whether to expand wildcard expression to concrete indices that are open, closed or both.", + "description": "Type of index that wildcard patterns can match.\nIf the request can target data streams, this argument determines whether wildcard expressions match hidden data streams.\nSupports comma-separated values, such as `open,hidden`.\nValid values are: `all`, `open`, `closed`, `hidden`, `none`.", "name": "expand_wildcards", "required": false, + "serverDefault": "open", "type": { "kind": "instance_of", "type": { @@ -118044,9 +118080,10 @@ } }, { - "description": "Whether specified concrete indices should be ignored when unavailable (missing or closed)", + "description": "If `false`, the request returns an error if it targets a missing or closed index.", "name": "ignore_unavailable", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -118056,9 +118093,10 @@ } }, { - "description": "Specify timeout for connection to master", + "description": "Period to wait for a connection to the master node.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "master_timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -118068,9 +118106,10 @@ } }, { - "description": "Explicit operation timeout", + "description": "Period to wait for a response.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -118080,9 +118119,10 @@ } }, { - "description": "Sets the number of active shards to wait for before the operation returns.", + "description": "The number of shard copies that must be active before proceeding with the operation.\nSet to `all` or any positive integer up to the total number of shards in the index (`number_of_replicas+1`).", "name": "wait_for_active_shards", "required": false, + "serverDefault": "1", "type": { "kind": "instance_of", "type": { @@ -118092,7 +118132,7 @@ } } ], - "specLocation": "indices/open/IndicesOpenRequest.ts#L24-L41" + "specLocation": "indices/open/IndicesOpenRequest.ts#L24-L82" }, { "body": { @@ -118187,6 +118227,7 @@ "kind": "properties", "properties": [ { + "description": "Query used to limit documents the alias can access.", "name": "filter", "required": false, "type": { @@ -118198,6 +118239,7 @@ } }, { + "description": "Value used to route indexing operations to a specific shard.\nIf specified, this overwrites the `routing` value for indexing operations.\nata stream aliases don’t support this parameter.", "name": "index_routing", "required": false, "type": { @@ -118209,6 +118251,7 @@ } }, { + "description": "If `true`, sets the write index or data stream for the alias.\nIf an alias points to multiple indices or data streams and `is_write_index` isn’t set, the alias rejects write requests.\nIf an index alias points to one index and `is_write_index` isn’t set, the index automatically acts as the write index.\nData stream aliases don’t automatically set a write data stream, even if the alias points to one data stream.", "name": "is_write_index", "required": false, "type": { @@ -118220,6 +118263,7 @@ } }, { + "description": "Value used to route indexing and search operations to a specific shard.\nData stream aliases don’t support this parameter.", "name": "routing", "required": false, "type": { @@ -118231,6 +118275,7 @@ } }, { + "description": "Value used to route search operations to a specific shard.\nIf specified, this overwrites the `routing` value for search operations.\nData stream aliases don’t support this parameter.", "name": "search_routing", "required": false, "type": { @@ -118243,7 +118288,7 @@ } ] }, - "description": "Creates or updates an alias.", + "description": "Adds a data stream or index to an alias.", "inherits": { "type": { "name": "RequestBase", @@ -118257,7 +118302,7 @@ }, "path": [ { - "description": "A comma-separated list of index names the alias should point to (supports wildcards); use `_all` to perform the operation on all indices.", + "description": "Comma-separated list of data streams or indices to add.\nSupports wildcards (`*`).\nWildcard patterns that match both data streams and indices return an error.", "name": "index", "required": true, "type": { @@ -118269,7 +118314,9 @@ } }, { - "description": "The name of the alias to be created or updated", + "description": "Alias to update.\nIf the alias doesn’t exist, the request creates it.\nIndex alias names support date math.", + "docId": "api-date-math-index-names", + "docUrl": "https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/api-conventions.html#api-date-math-index-names", "name": "name", "required": true, "type": { @@ -118283,9 +118330,10 @@ ], "query": [ { - "description": "Specify timeout for connection to master", + "description": "Period to wait for a connection to the master node.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "master_timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -118295,9 +118343,10 @@ } }, { - "description": "Explicit timestamp for the document", + "description": "Period to wait for a response.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -118307,7 +118356,7 @@ } } ], - "specLocation": "indices/put_alias/IndicesPutAliasRequest.ts#L25-L46" + "specLocation": "indices/put_alias/IndicesPutAliasRequest.ts#L25-L91" }, { "body": { @@ -118335,6 +118384,7 @@ "kind": "properties", "properties": [ { + "description": "If defined, every document added to this data stream will be stored at least for this time frame.\nAny time after this duration the document could be deleted.\nWhen empty, every document in this data stream will be stored indefinitely.", "name": "data_retention", "required": false, "type": { @@ -118361,7 +118411,7 @@ }, "path": [ { - "description": "A comma-separated list of data streams whose lifecycle will be updated; use `*` to set the lifecycle to all data streams", + "description": "Comma-separated list of data streams used to limit the request.\nSupports wildcards (`*`).\nTo target all data streams use `*` or `_all`.", "name": "name", "required": true, "type": { @@ -118375,9 +118425,10 @@ ], "query": [ { - "description": "Whether wildcard expressions should get expanded to open or closed indices (default: open)", + "description": "Type of data stream that wildcard patterns can match.\nSupports comma-separated values, such as `open,hidden`.\nValid values are: all, hidden, open, closed, none.", "name": "expand_wildcards", "required": false, + "serverDefault": "open", "type": { "kind": "instance_of", "type": { @@ -118387,9 +118438,10 @@ } }, { - "description": "Specify timeout for connection to master", + "description": "Period to wait for a connection to the master node. If no response is\nreceived before the timeout expires, the request fails and returns an\nerror.", "name": "master_timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -118399,9 +118451,10 @@ } }, { - "description": "Explicit timestamp for the document", + "description": "Period to wait for a response.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -118411,7 +118464,7 @@ } } ], - "specLocation": "indices/put_data_lifecycle/IndicesPutDataLifecycleRequest.ts#L24-L42" + "specLocation": "indices/put_data_lifecycle/IndicesPutDataLifecycleRequest.ts#L24-L69" }, { "body": { @@ -118439,6 +118492,7 @@ }, "properties": [ { + "description": "Aliases to add.\nIf the index template includes a `data_stream` object, these are data stream aliases.\nOtherwise, these are index aliases.\nData stream aliases ignore the `index_routing`, `routing`, and `search_routing` options.", "name": "aliases", "required": false, "type": { @@ -118461,6 +118515,7 @@ } }, { + "description": "Mapping for fields in the index.\nIf specified, this mapping can include field names, field data types, and mapping parameters.", "name": "mappings", "required": false, "type": { @@ -118472,6 +118527,7 @@ } }, { + "description": "Configuration options for the index.", "name": "settings", "required": false, "type": { @@ -118505,7 +118561,7 @@ } } ], - "specLocation": "indices/put_index_template/IndicesPutIndexTemplateRequest.ts#L61-L70" + "specLocation": "indices/put_index_template/IndicesPutIndexTemplateRequest.ts#L97-L119" }, { "attachedBehaviors": [ @@ -118515,6 +118571,7 @@ "kind": "properties", "properties": [ { + "description": "Name of the index template to create.", "name": "index_patterns", "required": false, "type": { @@ -118526,6 +118583,7 @@ } }, { + "description": "An ordered list of component template names.\nComponent templates are merged in the order specified, meaning that the last component template specified has the highest precedence.", "name": "composed_of", "required": false, "type": { @@ -118540,6 +118598,7 @@ } }, { + "description": "Template to be applied.\nIt may optionally include an `aliases`, `mappings`, or `settings` configuration.", "name": "template", "required": false, "type": { @@ -118551,6 +118610,7 @@ } }, { + "description": "If this object is included, the template is used to create data streams and their backing indices.\nSupports an empty object.\nData streams require a matching index template with a `data_stream` object.", "name": "data_stream", "required": false, "type": { @@ -118562,6 +118622,7 @@ } }, { + "description": "Priority to determine index template precedence when a new data stream or index is created.\nThe index template with the highest priority is chosen.\nIf no priority is specified the template is treated as though it is of priority 0 (lowest priority).\nThis number is not automatically generated by Elasticsearch.", "name": "priority", "required": false, "type": { @@ -118573,6 +118634,7 @@ } }, { + "description": "Version number used to manage index templates externally.\nThis number is not automatically generated by Elasticsearch.", "name": "version", "required": false, "type": { @@ -118584,6 +118646,7 @@ } }, { + "description": "Optional user metadata about the index template.\nMay have any contents.\nThis map is not automatically generated by Elasticsearch.", "docId": "mapping-meta-field", "docUrl": "https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/mapping-meta-field.html", "name": "_meta", @@ -118598,7 +118661,7 @@ } ] }, - "description": "Creates or updates an index template.", + "description": "Creates or updates an index template.\nIndex templates define settings, mappings, and aliases that can be applied automatically to new indices.", "inherits": { "type": { "name": "RequestBase", @@ -118626,9 +118689,10 @@ ], "query": [ { - "description": "Whether the index template should only be added if new or can also replace an existing one", + "description": "If `true`, this request cannot replace or update existing index templates.", "name": "create", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -118638,7 +118702,7 @@ } } ], - "specLocation": "indices/put_index_template/IndicesPutIndexTemplateRequest.ts#L36-L59" + "specLocation": "indices/put_index_template/IndicesPutIndexTemplateRequest.ts#L36-L95" }, { "body": { @@ -118851,7 +118915,7 @@ } ] }, - "description": "Updates the index mappings.", + "description": "Adds new fields to an existing data stream or index.\nYou can also use this API to change the search settings of existing fields.\nFor data streams, these changes are applied to all backing indices by default.", "inherits": { "type": { "name": "RequestBase", @@ -118879,9 +118943,10 @@ ], "query": [ { - "description": "Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified)", + "description": "If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices.\nThis behavior applies even if the request targets other open indices.", "name": "allow_no_indices", "required": false, + "serverDefault": true, "type": { "kind": "instance_of", "type": { @@ -118891,9 +118956,10 @@ } }, { - "description": "Whether to expand wildcard expression to concrete indices that are open, closed or both.", + "description": "Type of index that wildcard patterns can match.\nIf the request can target data streams, this argument determines whether wildcard expressions match hidden data streams.\nSupports comma-separated values, such as `open,hidden`.\nValid values are: `all`, `open`, `closed`, `hidden`, `none`.", "name": "expand_wildcards", "required": false, + "serverDefault": "open", "type": { "kind": "instance_of", "type": { @@ -118903,9 +118969,10 @@ } }, { - "description": "Whether specified concrete indices should be ignored when unavailable (missing or closed)", + "description": "If `false`, the request returns an error if it targets a missing or closed index.", "name": "ignore_unavailable", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -118915,9 +118982,10 @@ } }, { - "description": "Specify timeout for connection to master", + "description": "Period to wait for a connection to the master node.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "master_timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -118927,9 +118995,10 @@ } }, { - "description": "Explicit operation timeout", + "description": "Period to wait for a response.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -118939,9 +119008,10 @@ } }, { - "description": "When true, applies mappings only to the write index of an alias or data stream", + "description": "If `true`, the mappings are applied only to the current write index for the target.", "name": "write_index_only", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -118951,7 +119021,7 @@ } } ], - "specLocation": "indices/put_mapping/IndicesPutMappingRequest.ts#L42-L116" + "specLocation": "indices/put_mapping/IndicesPutMappingRequest.ts#L42-L149" }, { "body": { @@ -119239,7 +119309,7 @@ } ] }, - "description": "Creates or updates an index template.", + "description": "Creates or updates an index template.\nIndex templates define settings, mappings, and aliases that can be applied automatically to new indices.", "inherits": { "type": { "name": "RequestBase", @@ -119280,8 +119350,10 @@ } }, { + "description": "If `true`, returns settings in flat format.", "name": "flat_settings", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -119304,8 +119376,10 @@ } }, { + "description": "Period to wait for a response.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -119327,7 +119401,7 @@ } } ], - "specLocation": "indices/put_template/IndicesPutTemplateRequest.ts#L29-L93" + "specLocation": "indices/put_template/IndicesPutTemplateRequest.ts#L29-L105" }, { "body": { @@ -119948,7 +120022,7 @@ "body": { "kind": "no_body" }, - "description": "Returns information about ongoing index shard recoveries.", + "description": "Returns information about ongoing and completed shard recoveries for one or more indices.\nFor data streams, the API returns information for the stream’s backing indices.", "inherits": { "type": { "name": "RequestBase", @@ -119962,7 +120036,7 @@ }, "path": [ { - "description": "A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices", + "description": "Comma-separated list of data streams, indices, and aliases used to limit the request.\nSupports wildcards (`*`).\nTo target all data streams and indices, omit this parameter or use `*` or `_all`.", "name": "index", "required": false, "type": { @@ -119976,9 +120050,10 @@ ], "query": [ { - "description": "Display only those recoveries that are currently on-going", + "description": "If `true`, the response only includes ongoing shard recoveries.", "name": "active_only", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -119988,9 +120063,10 @@ } }, { - "description": "Whether to display detailed information about shard recovery", + "description": "If `true`, the response includes detailed information about shard recoveries.", "name": "detailed", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -120000,7 +120076,7 @@ } } ], - "specLocation": "indices/recovery/IndicesRecoveryRequest.ts#L23-L36" + "specLocation": "indices/recovery/IndicesRecoveryRequest.ts#L23-L51" }, { "body": { @@ -120408,7 +120484,7 @@ "body": { "kind": "no_body" }, - "description": "Performs the refresh operation in one or more indices.", + "description": "A refresh makes recent operations performed on one or more indices available for search.\nFor data streams, the API runs the refresh operation on the stream’s backing indices.", "inherits": { "type": { "name": "RequestBase", @@ -120422,7 +120498,7 @@ }, "path": [ { - "description": "A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices", + "description": "Comma-separated list of data streams, indices, and aliases used to limit the request.\nSupports wildcards (`*`).\nTo target all data streams and indices, omit this parameter or use `*` or `_all`.", "name": "index", "required": false, "type": { @@ -120436,9 +120512,10 @@ ], "query": [ { - "description": "Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified)", + "description": "If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices.\nThis behavior applies even if the request targets other open indices.", "name": "allow_no_indices", "required": false, + "serverDefault": true, "type": { "kind": "instance_of", "type": { @@ -120448,9 +120525,10 @@ } }, { - "description": "Whether to expand wildcard expression to concrete indices that are open, closed or both.", + "description": "Type of index that wildcard patterns can match.\nIf the request can target data streams, this argument determines whether wildcard expressions match hidden data streams.\nSupports comma-separated values, such as `open,hidden`.\nValid values are: `all`, `open`, `closed`, `hidden`, `none`.", "name": "expand_wildcards", "required": false, + "serverDefault": "open", "type": { "kind": "instance_of", "type": { @@ -120460,9 +120538,10 @@ } }, { - "description": "Whether specified concrete indices should be ignored when unavailable (missing or closed)", + "description": "If `false`, the request returns an error if it targets a missing or closed index.", "name": "ignore_unavailable", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -120472,7 +120551,7 @@ } } ], - "specLocation": "indices/refresh/IndicesRefreshRequest.ts#L23-L36" + "specLocation": "indices/refresh/IndicesRefreshRequest.ts#L23-L59" }, { "body": { @@ -120659,7 +120738,7 @@ "body": { "kind": "no_body" }, - "description": "Returns information about any matching indices, aliases, and data streams", + "description": "Resolves the specified name(s) and/or index patterns for indices, aliases, and data streams.\nMultiple patterns and remote clusters are supported.", "inherits": { "type": { "name": "RequestBase", @@ -120673,7 +120752,7 @@ }, "path": [ { - "description": "A comma-separated list of names or wildcard expressions", + "description": "Comma-separated name(s) or index pattern(s) of the indices, aliases, and data streams to resolve\n Resources on remote clusters can be specified using the` `:`` syntax.", "name": "name", "required": true, "type": { @@ -120687,9 +120766,10 @@ ], "query": [ { - "description": "Whether wildcard expressions should get expanded to open or closed indices (default: open)", + "description": "Type of index that wildcard patterns can match.\nIf the request can target data streams, this argument determines whether wildcard expressions match hidden data streams.\nSupports comma-separated values, such as `open,hidden`.\nValid values are: `all`, `open`, `closed`, `hidden`, `none`.", "name": "expand_wildcards", "required": false, + "serverDefault": "open", "type": { "kind": "instance_of", "type": { @@ -120699,7 +120779,7 @@ } } ], - "specLocation": "indices/resolve_index/ResolveIndexRequest.ts#L23-L35" + "specLocation": "indices/resolve_index/ResolveIndexRequest.ts#L23-L48" }, { "kind": "interface", @@ -120899,6 +120979,7 @@ "kind": "properties", "properties": [ { + "description": "Aliases for the target index.\nData streams do not support this parameter.", "name": "aliases", "required": false, "type": { @@ -120921,6 +121002,7 @@ } }, { + "description": "Conditions for the rollover.\nIf specified, Elasticsearch only performs the rollover if the current index satisfies these conditions.\nIf this parameter is not specified, Elasticsearch performs the rollover unconditionally.\nIf conditions are specified, at least one of them must be a `max_*` condition.\nThe index will rollover if any `max_*` condition is satisfied and all `min_*` conditions are satisfied.", "name": "conditions", "required": false, "type": { @@ -120932,6 +121014,7 @@ } }, { + "description": "Mapping for fields in the index.\nIf specified, this mapping can include field names, field data types, and mapping paramaters.", "name": "mappings", "required": false, "type": { @@ -120943,6 +121026,7 @@ } }, { + "description": "Configuration options for the index.\nData streams do not support this parameter.", "name": "settings", "required": false, "type": { @@ -120962,7 +121046,7 @@ } ] }, - "description": "Updates an alias to point to a new index when the existing index\nis considered to be too large or too old.", + "description": "Creates a new index for a data stream or index alias.", "inherits": { "type": { "name": "RequestBase", @@ -120976,7 +121060,7 @@ }, "path": [ { - "description": "The name of the alias to rollover", + "description": "Name of the data stream or index alias to roll over.", "name": "alias", "required": true, "type": { @@ -120988,7 +121072,7 @@ } }, { - "description": "The name of the rollover index", + "description": "Name of the index to create.\nSupports date math.\nData streams do not support this parameter.", "name": "new_index", "required": false, "type": { @@ -121002,9 +121086,10 @@ ], "query": [ { - "description": "If set to true the rollover action will only be validated but not actually performed even if a condition matches. The default is false", + "description": "If `true`, checks whether the current index satisfies the specified conditions but does not perform a rollover.", "name": "dry_run", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -121014,9 +121099,10 @@ } }, { - "description": "Specify timeout for connection to master", + "description": "Period to wait for a connection to the master node.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "master_timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -121026,9 +121112,10 @@ } }, { - "description": "Explicit operation timeout", + "description": "Period to wait for a response.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -121038,9 +121125,10 @@ } }, { - "description": "Set the number of active shards to wait for on the newly created rollover index before the operation returns.", + "description": "The number of shard copies that must be active before proceeding with the operation.\nSet to all or any positive integer up to the total number of shards in the index (`number_of_replicas+1`).", "name": "wait_for_active_shards", "required": false, + "serverDefault": "1", "type": { "kind": "instance_of", "type": { @@ -121050,7 +121138,7 @@ } } ], - "specLocation": "indices/rollover/IndicesRolloverRequest.ts#L29-L51" + "specLocation": "indices/rollover/IndicesRolloverRequest.ts#L29-L99" }, { "body": { @@ -121391,7 +121479,7 @@ "body": { "kind": "no_body" }, - "description": "Provides low-level information about segments in a Lucene index.", + "description": "Returns low-level information about the Lucene segments in index shards.\nFor data streams, the API returns information about the stream’s backing indices.", "inherits": { "type": { "name": "RequestBase", @@ -121405,7 +121493,7 @@ }, "path": [ { - "description": "A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices", + "description": "Comma-separated list of data streams, indices, and aliases used to limit the request.\nSupports wildcards (`*`).\nTo target all data streams and indices, omit this parameter or use `*` or `_all`.", "name": "index", "required": false, "type": { @@ -121419,9 +121507,10 @@ ], "query": [ { - "description": "Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified)", + "description": "If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices.\nThis behavior applies even if the request targets other open indices.", "name": "allow_no_indices", "required": false, + "serverDefault": true, "type": { "kind": "instance_of", "type": { @@ -121431,9 +121520,10 @@ } }, { - "description": "Whether to expand wildcard expression to concrete indices that are open, closed or both.", + "description": "Type of index that wildcard patterns can match.\nIf the request can target data streams, this argument determines whether wildcard expressions match hidden data streams.\nSupports comma-separated values, such as `open,hidden`.\nValid values are: `all`, `open`, `closed`, `hidden`, `none`.", "name": "expand_wildcards", "required": false, + "serverDefault": "open", "type": { "kind": "instance_of", "type": { @@ -121443,9 +121533,10 @@ } }, { - "description": "Whether specified concrete indices should be ignored when unavailable (missing or closed)", + "description": "If `false`, the request returns an error if it targets a missing or closed index.", "name": "ignore_unavailable", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -121455,9 +121546,10 @@ } }, { - "description": "Includes detailed memory usage by Lucene.", + "description": "If `true`, the request returns a verbose response.", "name": "verbose", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -121467,7 +121559,7 @@ } } ], - "specLocation": "indices/segments/IndicesSegmentsRequest.ts#L23-L37" + "specLocation": "indices/segments/IndicesSegmentsRequest.ts#L23-L63" }, { "body": { @@ -121782,7 +121874,7 @@ "body": { "kind": "no_body" }, - "description": "Provides store information for shard copies of indices.", + "description": "Retrieves store information about replica shards in one or more indices.\nFor data streams, the API retrieves store information for the stream’s backing indices.", "inherits": { "type": { "name": "RequestBase", @@ -121875,7 +121967,7 @@ } } ], - "specLocation": "indices/shard_stores/IndicesShardStoresRequest.ts#L24-L58" + "specLocation": "indices/shard_stores/IndicesShardStoresRequest.ts#L24-L60" }, { "body": { @@ -122181,6 +122273,7 @@ "kind": "properties", "properties": [ { + "description": "The key is the alias name.\nIndex alias names support date math.", "name": "aliases", "required": false, "type": { @@ -122203,6 +122296,7 @@ } }, { + "description": "Configuration options for the target index.", "name": "settings", "required": false, "type": { @@ -122222,7 +122316,7 @@ } ] }, - "description": "Allow to shrink an existing index into a new index with fewer primary shards.", + "description": "Shrinks an existing index into a new index with fewer primary shards.", "inherits": { "type": { "name": "RequestBase", @@ -122236,7 +122330,7 @@ }, "path": [ { - "description": "The name of the source index to shrink", + "description": "Name of the source index to shrink.", "name": "index", "required": true, "type": { @@ -122248,7 +122342,7 @@ } }, { - "description": "The name of the target index to shrink into", + "description": "Name of the target index to create.", "name": "target", "required": true, "type": { @@ -122262,9 +122356,10 @@ ], "query": [ { - "description": "Specify timeout for connection to master", + "description": "Period to wait for a connection to the master node.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "master_timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -122274,9 +122369,10 @@ } }, { - "description": "Explicit operation timeout", + "description": "Period to wait for a response.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -122286,9 +122382,10 @@ } }, { - "description": "Set the number of active shards to wait for on the shrunken index before the operation returns.", + "description": "The number of shard copies that must be active before proceeding with the operation.\nSet to `all` or any positive integer up to the total number of shards in the index (`number_of_replicas+1`).", "name": "wait_for_active_shards", "required": false, + "serverDefault": "1", "type": { "kind": "instance_of", "type": { @@ -122298,7 +122395,7 @@ } } ], - "specLocation": "indices/shrink/IndicesShrinkRequest.ts#L27-L45" + "specLocation": "indices/shrink/IndicesShrinkRequest.ts#L27-L75" }, { "body": { @@ -122354,6 +122451,7 @@ "kind": "properties", "properties": [ { + "description": "This setting overrides the value of the `action.auto_create_index` cluster setting.\nIf set to `true` in a template, then indices can be automatically created using that template even if auto-creation of indices is disabled via `actions.auto_create_index`.\nIf set to `false`, then indices or data streams matching the template must always be explicitly created, and may never be automatically created.", "name": "allow_auto_create", "required": false, "type": { @@ -122365,6 +122463,9 @@ } }, { + "description": "Array of wildcard (`*`) expressions used to match the names of data streams and indices during creation.", + "docId": "avoid-index-pattern-collisions", + "docUrl": "https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/index-templates.html#avoid-index-pattern-collisions", "name": "index_patterns", "required": false, "type": { @@ -122376,6 +122477,7 @@ } }, { + "description": "An ordered list of component template names.\nComponent templates are merged in the order specified, meaning that the last component template specified has the highest precedence.", "name": "composed_of", "required": false, "type": { @@ -122390,6 +122492,7 @@ } }, { + "description": "Template to be applied.\nIt may optionally include an `aliases`, `mappings`, or `settings` configuration.", "name": "template", "required": false, "type": { @@ -122401,6 +122504,7 @@ } }, { + "description": "If this object is included, the template is used to create data streams and their backing indices.\nSupports an empty object.\nData streams require a matching index template with a `data_stream` object.", "name": "data_stream", "required": false, "type": { @@ -122412,6 +122516,7 @@ } }, { + "description": "Priority to determine index template precedence when a new data stream or index is created.\nThe index template with the highest priority is chosen.\nIf no priority is specified the template is treated as though it is of priority 0 (lowest priority).\nThis number is not automatically generated by Elasticsearch.", "name": "priority", "required": false, "type": { @@ -122423,6 +122528,7 @@ } }, { + "description": "Version number used to manage index templates externally.\nThis number is not automatically generated by Elasticsearch.", "name": "version", "required": false, "type": { @@ -122434,6 +122540,7 @@ } }, { + "description": "Optional user metadata about the index template.\nMay have any contents.\nThis map is not automatically generated by Elasticsearch.", "docId": "mapping-meta-field", "docUrl": "https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/mapping-meta-field.html", "name": "_meta", @@ -122448,7 +122555,7 @@ } ] }, - "description": "Simulate matching the given index name against the index templates in the system", + "description": "", "inherits": { "type": { "name": "RequestBase", @@ -122526,7 +122633,7 @@ } } ], - "specLocation": "indices/simulate_index_template/IndicesSimulateIndexTemplateRequest.ts#L33-L78" + "specLocation": "indices/simulate_index_template/IndicesSimulateIndexTemplateRequest.ts#L33-L115" }, { "body": { @@ -122770,6 +122877,7 @@ "kind": "properties", "properties": [ { + "description": "Aliases for the resulting index.", "name": "aliases", "required": false, "type": { @@ -122792,6 +122900,7 @@ } }, { + "description": "Configuration options for the target index.", "name": "settings", "required": false, "type": { @@ -122811,7 +122920,7 @@ } ] }, - "description": "Allows you to split an existing index into a new index with more primary shards.", + "description": "Splits an existing index into a new index with more primary shards.", "inherits": { "type": { "name": "RequestBase", @@ -122825,7 +122934,7 @@ }, "path": [ { - "description": "The name of the source index to split", + "description": "Name of the source index to split.", "name": "index", "required": true, "type": { @@ -122837,7 +122946,7 @@ } }, { - "description": "The name of the target index to split into", + "description": "Name of the target index to create.", "name": "target", "required": true, "type": { @@ -122851,9 +122960,10 @@ ], "query": [ { - "description": "Specify timeout for connection to master", + "description": "Period to wait for a connection to the master node.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "master_timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -122863,9 +122973,10 @@ } }, { - "description": "Explicit operation timeout", + "description": "Period to wait for a response.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -122875,9 +122986,10 @@ } }, { - "description": "Set the number of active shards to wait for on the shrunken index before the operation returns.", + "description": "The number of shard copies that must be active before proceeding with the operation.\nSet to `all` or any positive integer up to the total number of shards in the index (`number_of_replicas+1`).", "name": "wait_for_active_shards", "required": false, + "serverDefault": "1", "type": { "kind": "instance_of", "type": { @@ -122887,7 +122999,7 @@ } } ], - "specLocation": "indices/split/IndicesSplitRequest.ts#L27-L45" + "specLocation": "indices/split/IndicesSplitRequest.ts#L27-L74" }, { "body": { @@ -123348,7 +123460,7 @@ "body": { "kind": "no_body" }, - "description": "Provides statistics on operations happening in an index.", + "description": "Returns statistics for one or more indices.\nFor data streams, the API retrieves statistics for the stream’s backing indices.", "inherits": { "type": { "name": "RequestBase", @@ -123514,7 +123626,7 @@ } } ], - "specLocation": "indices/stats/IndicesStatsRequest.ts#L29-L83" + "specLocation": "indices/stats/IndicesStatsRequest.ts#L29-L85" }, { "body": { @@ -124413,7 +124525,7 @@ "body": { "kind": "no_body" }, - "description": "Unfreezes an index. When a frozen index is unfrozen, the index goes through the normal recovery process and becomes writeable again.", + "description": "Unfreezes an index.", "inherits": { "type": { "name": "RequestBase", @@ -124427,7 +124539,7 @@ }, "path": [ { - "description": "The name of the index to unfreeze", + "description": "Identifier for the index.", "name": "index", "required": true, "type": { @@ -124441,9 +124553,10 @@ ], "query": [ { - "description": "Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified)", + "description": "If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices.\nThis behavior applies even if the request targets other open indices.", "name": "allow_no_indices", "required": false, + "serverDefault": true, "type": { "kind": "instance_of", "type": { @@ -124453,9 +124566,10 @@ } }, { - "description": "Whether to expand wildcard expression to concrete indices that are open, closed or both.", + "description": "Type of index that wildcard patterns can match.\nIf the request can target data streams, this argument determines whether wildcard expressions match hidden data streams.\nSupports comma-separated values, such as `open,hidden`.\nValid values are: `all`, `open`, `closed`, `hidden`, `none`.", "name": "expand_wildcards", "required": false, + "serverDefault": "open", "type": { "kind": "instance_of", "type": { @@ -124465,9 +124579,10 @@ } }, { - "description": "Whether specified concrete indices should be ignored when unavailable (missing or closed)", + "description": "If `false`, the request returns an error if it targets a missing or closed index.", "name": "ignore_unavailable", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -124477,9 +124592,10 @@ } }, { - "description": "Specify timeout for connection to master", + "description": "Period to wait for a connection to the master node.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "master_timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -124489,9 +124605,10 @@ } }, { - "description": "Explicit operation timeout", + "description": "Period to wait for a response.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -124501,9 +124618,10 @@ } }, { - "description": "Sets the number of active shards to wait for before the operation returns.", + "description": "The number of shard copies that must be active before proceeding with the operation.\nSet to `all` or any positive integer up to the total number of shards in the index (`number_of_replicas+1`).", "name": "wait_for_active_shards", "required": false, + "serverDefault": "1", "type": { "kind": "instance_of", "type": { @@ -124513,7 +124631,7 @@ } } ], - "specLocation": "indices/unfreeze/IndicesUnfreezeRequest.ts#L24-L40" + "specLocation": "indices/unfreeze/IndicesUnfreezeRequest.ts#L24-L75" }, { "body": { @@ -124558,6 +124676,7 @@ }, "properties": [ { + "description": "Adds a data stream or index to an alias.\nIf the alias doesn’t exist, the `add` action creates it.", "name": "add", "required": false, "type": { @@ -124569,6 +124688,7 @@ } }, { + "description": "Removes a data stream or index from an alias.", "name": "remove", "required": false, "type": { @@ -124580,6 +124700,7 @@ } }, { + "description": "Deletes an index.\nYou cannot use this action on aliases or data streams.", "name": "remove_index", "required": false, "type": { @@ -124591,7 +124712,7 @@ } } ], - "specLocation": "indices/update_aliases/types.ts#L23-L28", + "specLocation": "indices/update_aliases/types.ts#L23-L39", "variants": { "kind": "container" } @@ -124604,6 +124725,7 @@ }, "properties": [ { + "description": "Alias for the action.\nIndex alias names support date math.", "name": "alias", "required": false, "type": { @@ -124615,6 +124737,7 @@ } }, { + "description": "Aliases for the action.\nIndex alias names support date math.", "name": "aliases", "required": false, "type": { @@ -124641,6 +124764,7 @@ } }, { + "description": "Query used to limit documents the alias can access.", "name": "filter", "required": false, "type": { @@ -124652,6 +124776,7 @@ } }, { + "description": "Data stream or index for the action.\nSupports wildcards (`*`).", "name": "index", "required": false, "type": { @@ -124663,6 +124788,7 @@ } }, { + "description": "Data streams or indices for the action.\nSupports wildcards (`*`).", "name": "indices", "required": false, "type": { @@ -124674,6 +124800,7 @@ } }, { + "description": "Value used to route indexing operations to a specific shard.\nIf specified, this overwrites the `routing` value for indexing operations.\nData stream aliases don’t support this parameter.", "name": "index_routing", "required": false, "type": { @@ -124685,6 +124812,7 @@ } }, { + "description": "If `true`, the alias is hidden.", "name": "is_hidden", "required": false, "serverDefault": false, @@ -124697,6 +124825,7 @@ } }, { + "description": "If `true`, sets the write index or data stream for the alias.", "name": "is_write_index", "required": false, "type": { @@ -124708,6 +124837,7 @@ } }, { + "description": "Value used to route indexing and search operations to a specific shard.\nData stream aliases don’t support this parameter.", "name": "routing", "required": false, "type": { @@ -124719,6 +124849,7 @@ } }, { + "description": "Value used to route search operations to a specific shard.\nIf specified, this overwrites the `routing` value for search operations.\nData stream aliases don’t support this parameter.", "name": "search_routing", "required": false, "type": { @@ -124730,6 +124861,7 @@ } }, { + "description": "If `true`, the alias must exist to perform the action.", "name": "must_exist", "required": false, "serverDefault": false, @@ -124742,7 +124874,7 @@ } } ], - "specLocation": "indices/update_aliases/types.ts#L30-L44" + "specLocation": "indices/update_aliases/types.ts#L41-L95" }, { "kind": "interface", @@ -124752,6 +124884,7 @@ }, "properties": [ { + "description": "Alias for the action.\nIndex alias names support date math.", "name": "alias", "required": false, "type": { @@ -124763,6 +124896,7 @@ } }, { + "description": "Aliases for the action.\nIndex alias names support date math.", "name": "aliases", "required": false, "type": { @@ -124789,6 +124923,7 @@ } }, { + "description": "Data stream or index for the action.\nSupports wildcards (`*`).", "name": "index", "required": false, "type": { @@ -124800,6 +124935,7 @@ } }, { + "description": "Data streams or indices for the action.\nSupports wildcards (`*`).", "name": "indices", "required": false, "type": { @@ -124811,6 +124947,7 @@ } }, { + "description": "If `true`, the alias must exist to perform the action.", "name": "must_exist", "required": false, "serverDefault": false, @@ -124823,7 +124960,7 @@ } } ], - "specLocation": "indices/update_aliases/types.ts#L46-L53" + "specLocation": "indices/update_aliases/types.ts#L97-L122" }, { "kind": "interface", @@ -124833,6 +124970,7 @@ }, "properties": [ { + "description": "Data stream or index for the action.\nSupports wildcards (`*`).", "name": "index", "required": false, "type": { @@ -124844,6 +124982,7 @@ } }, { + "description": "Data streams or indices for the action.\nSupports wildcards (`*`).", "name": "indices", "required": false, "type": { @@ -124855,6 +124994,7 @@ } }, { + "description": "If `true`, the alias must exist to perform the action.", "name": "must_exist", "required": false, "serverDefault": false, @@ -124867,7 +125007,7 @@ } } ], - "specLocation": "indices/update_aliases/types.ts#L55-L60" + "specLocation": "indices/update_aliases/types.ts#L124-L139" }, { "attachedBehaviors": [ @@ -124877,6 +125017,7 @@ "kind": "properties", "properties": [ { + "description": "Actions to perform.", "name": "actions", "required": false, "type": { @@ -124892,7 +125033,7 @@ } ] }, - "description": "Updates index aliases.", + "description": "Adds a data stream or index to an alias.", "inherits": { "type": { "name": "RequestBase", @@ -124907,9 +125048,10 @@ "path": [], "query": [ { - "description": "Specify timeout for connection to master", + "description": "Period to wait for a connection to the master node.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "master_timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -124919,9 +125061,10 @@ } }, { - "description": "Request timeout", + "description": "Period to wait for a response.\nIf no response is received before the timeout expires, the request fails and returns an error.", "name": "timeout", "required": false, + "serverDefault": "30s", "type": { "kind": "instance_of", "type": { @@ -124931,7 +125074,7 @@ } } ], - "specLocation": "indices/update_aliases/IndicesUpdateAliasesRequest.ts#L24-L37" + "specLocation": "indices/update_aliases/IndicesUpdateAliasesRequest.ts#L24-L51" }, { "body": { @@ -125013,6 +125156,7 @@ "kind": "properties", "properties": [ { + "description": "Query in the Lucene query string syntax.", "name": "query", "required": false, "type": { @@ -125025,7 +125169,7 @@ } ] }, - "description": "Allows a user to validate a potentially expensive query without executing it.", + "description": "Validates a potentially expensive query without executing it.", "inherits": { "type": { "name": "RequestBase", @@ -125039,7 +125183,7 @@ }, "path": [ { - "description": "A comma-separated list of index names to restrict the operation; use `_all` or empty string to perform the operation on all indices", + "description": "Comma-separated list of data streams, indices, and aliases to search.\nSupports wildcards (`*`).\nTo search all data streams or indices, omit this parameter or use `*` or `_all`.", "name": "index", "required": false, "type": { @@ -125053,9 +125197,10 @@ ], "query": [ { - "description": "Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified)", + "description": "If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices.\nThis behavior applies even if the request targets other open indices.", "name": "allow_no_indices", "required": false, + "serverDefault": true, "type": { "kind": "instance_of", "type": { @@ -125065,9 +125210,10 @@ } }, { - "description": "Execute validation on all shards instead of one random shard per index", + "description": "If `true`, the validation is executed on all shards instead of one random shard per index.", "name": "all_shards", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -125077,7 +125223,7 @@ } }, { - "description": "The analyzer to use for the query string", + "description": "Analyzer to use for the query string.\nThis parameter can only be used when the `q` query string parameter is specified.", "name": "analyzer", "required": false, "type": { @@ -125089,9 +125235,10 @@ } }, { - "description": "Specify whether wildcard and prefix queries should be analyzed (default: false)", + "description": "If `true`, wildcard and prefix queries are analyzed.", "name": "analyze_wildcard", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -125101,9 +125248,10 @@ } }, { - "description": "The default operator for query string query (AND or OR)", + "description": "The default operator for query string query: `AND` or `OR`.", "name": "default_operator", "required": false, + "serverDefault": "OR", "type": { "kind": "instance_of", "type": { @@ -125113,7 +125261,7 @@ } }, { - "description": "The field to use as default where no field prefix is given in the query string", + "description": "Field to use as default where no field prefix is given in the query string.\nThis parameter can only be used when the `q` query string parameter is specified.", "name": "df", "required": false, "type": { @@ -125125,9 +125273,10 @@ } }, { - "description": "Whether to expand wildcard expression to concrete indices that are open, closed or both.", + "description": "Type of index that wildcard patterns can match.\nIf the request can target data streams, this argument determines whether wildcard expressions match hidden data streams.\nSupports comma-separated values, such as `open,hidden`.\nValid values are: `all`, `open`, `closed`, `hidden`, `none`.", "name": "expand_wildcards", "required": false, + "serverDefault": "open", "type": { "kind": "instance_of", "type": { @@ -125137,9 +125286,10 @@ } }, { - "description": "Return detailed information about the error", + "description": "If `true`, the response returns detailed information if an error has occurred.", "name": "explain", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -125149,9 +125299,10 @@ } }, { - "description": "Whether specified concrete indices should be ignored when unavailable (missing or closed)", + "description": "If `false`, the request returns an error if it targets a missing or closed index.", "name": "ignore_unavailable", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -125161,9 +125312,10 @@ } }, { - "description": "Specify whether format-based query failures (such as providing text to a numeric field) should be ignored", + "description": "If `true`, format-based query failures (such as providing text to a numeric field) in the query string will be ignored.", "name": "lenient", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -125173,9 +125325,10 @@ } }, { - "description": "Provide a more detailed explanation showing the actual Lucene query that will be executed.", + "description": "If `true`, returns a more detailed explanation showing the actual Lucene query that will be executed.", "name": "rewrite", "required": false, + "serverDefault": false, "type": { "kind": "instance_of", "type": { @@ -125185,7 +125338,7 @@ } }, { - "description": "Query in the Lucene query string syntax", + "description": "Query in the Lucene query string syntax.", "name": "q", "required": false, "type": { @@ -125197,7 +125350,7 @@ } } ], - "specLocation": "indices/validate_query/IndicesValidateQueryRequest.ts#L25-L51" + "specLocation": "indices/validate_query/IndicesValidateQueryRequest.ts#L25-L111" }, { "body": { diff --git a/specification/_doc_ids/table.csv b/specification/_doc_ids/table.csv index 80f0c2f4a8..2f1a108ce9 100644 --- a/specification/_doc_ids/table.csv +++ b/specification/_doc_ids/table.csv @@ -1,8 +1,10 @@ +api-date-math-index-names,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/api-conventions.html#api-date-math-index-names async-search,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/async-search.html autoscaling-delete-autoscaling-policy,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/autoscaling-delete-autoscaling-policy.html autoscaling-get-autoscaling-capacity,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/autoscaling-get-autoscaling-capacity.html autoscaling-get-autoscaling-policy,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/autoscaling-get-autoscaling-policy.html autoscaling-put-autoscaling-policy,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/autoscaling-put-autoscaling-policy.html +avoid-index-pattern-collisions,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/index-templates.html#avoid-index-pattern-collisions docs-bulk,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/docs-bulk.html cat-alias,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/cat-alias.html cat-allocation,https://www.elastic.co/guide/en/elasticsearch/reference/{branch}/cat-allocation.html diff --git a/specification/indices/_types/IndexTemplate.ts b/specification/indices/_types/IndexTemplate.ts index 86327570df..c5e1dd2d14 100644 --- a/specification/indices/_types/IndexTemplate.ts +++ b/specification/indices/_types/IndexTemplate.ts @@ -29,14 +29,43 @@ import { } from '@indices/_types/DataLifecycle' export class IndexTemplate { + /** + * Name of the index template. + */ index_patterns: Names + /** + * An ordered list of component template names. + * Component templates are merged in the order specified, meaning that the last component template specified has the highest precedence. + */ composed_of: Name[] + /** + * Template to be applied. + * It may optionally include an `aliases`, `mappings`, or `settings` configuration. + */ template?: IndexTemplateSummary + /** + * Version number used to manage index templates externally. + * This number is not automatically generated by Elasticsearch. + */ version?: VersionNumber + /** + * Priority to determine index template precedence when a new data stream or index is created. + * The index template with the highest priority is chosen. + * If no priority is specified the template is treated as though it is of priority 0 (lowest priority). + * This number is not automatically generated by Elasticsearch. + */ priority?: long - /** @doc_id mapping-meta-field */ + /** + * Optional user metadata about the index template. May have any contents. + * This map is not automatically generated by Elasticsearch. + * @doc_id mapping-meta-field */ _meta?: Metadata allow_auto_create?: boolean + /** + * If this object is included, the template is used to create data streams and their backing indices. + * Supports an empty object. + * Data streams require a matching index template with a `data_stream` object. + */ data_stream?: IndexTemplateDataStreamConfiguration } @@ -54,8 +83,21 @@ export class IndexTemplateDataStreamConfiguration { } export class IndexTemplateSummary { + /** + * Aliases to add. + * If the index template includes a `data_stream` object, these are data stream aliases. + * Otherwise, these are index aliases. + * Data stream aliases ignore the `index_routing`, `routing`, and `search_routing` options. + */ aliases?: Dictionary + /** + * Mapping for fields in the index. + * If specified, this mapping can include field names, field data types, and mapping parameters. + */ mappings?: TypeMapping + /** + * Configuration options for the index. + */ settings?: IndexSettings /** * @availability stack since=8.8.0 stability=experimental diff --git a/specification/indices/get_alias/IndicesGetAliasRequest.ts b/specification/indices/get_alias/IndicesGetAliasRequest.ts index 550024b31b..dad10bb348 100644 --- a/specification/indices/get_alias/IndicesGetAliasRequest.ts +++ b/specification/indices/get_alias/IndicesGetAliasRequest.ts @@ -21,19 +21,50 @@ import { RequestBase } from '@_types/Base' import { ExpandWildcards, Indices, Names } from '@_types/common' /** + * Retrieves information for one or more aliases. * @rest_spec_name indices.get_alias * @availability stack since=0.0.0 stability=stable * @availability serverless stability=stable visibility=public */ export interface Request extends RequestBase { path_parts: { + /** + * Comma-separated list of aliases to retrieve. + * Supports wildcards (`*`). + * To retrieve all aliases, omit this parameter or use `*` or `_all`. + */ name?: Names + /** + * Comma-separated list of data streams or indices used to limit the request. + * Supports wildcards (`*`). + * To target all data streams and indices, omit this parameter or use `*` or `_all`. + */ index?: Indices } query_parameters: { + /** + * If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. + * This behavior applies even if the request targets other open indices. + * @server_default true + */ allow_no_indices?: boolean + /** + * Type of index that wildcard patterns can match. + * If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. + * Supports comma-separated values, such as `open,hidden`. + * Valid values are: `all`, `open`, `closed`, `hidden`, `none`. + * @server_default open + */ expand_wildcards?: ExpandWildcards + /** + * If `false`, the request returns an error if it targets a missing or closed index. + * @server_default false + */ ignore_unavailable?: boolean + /** + * If `true`, the request retrieves information from the local node only. + * @server_default false + */ local?: boolean } } diff --git a/specification/indices/get_data_lifecycle/IndicesGetDataLifecycleRequest.ts b/specification/indices/get_data_lifecycle/IndicesGetDataLifecycleRequest.ts index 9f2f59df7f..e5a32dfcee 100644 --- a/specification/indices/get_data_lifecycle/IndicesGetDataLifecycleRequest.ts +++ b/specification/indices/get_data_lifecycle/IndicesGetDataLifecycleRequest.ts @@ -28,10 +28,25 @@ import { ExpandWildcards, DataStreamNames } from '@_types/common' */ export interface Request extends RequestBase { path_parts: { + /** + * Comma-separated list of data streams to limit the request. + * Supports wildcards (`*`). + * To target all data streams, omit this parameter or use `*` or `_all`. + */ name: DataStreamNames } query_parameters: { + /** + * Type of data stream that wildcard patterns can match. + * Supports comma-separated values, such as `open,hidden`. + * Valid values are: `all`, `open`, `closed`, `hidden`, `none`. + * @server_default open + */ expand_wildcards?: ExpandWildcards + /** + * If `true`, return all default settings in the response. + * @server_default false + */ include_defaults?: boolean } } diff --git a/specification/indices/get_field_mapping/IndicesGetFieldMappingRequest.ts b/specification/indices/get_field_mapping/IndicesGetFieldMappingRequest.ts index ee732984d4..f23d7fde94 100644 --- a/specification/indices/get_field_mapping/IndicesGetFieldMappingRequest.ts +++ b/specification/indices/get_field_mapping/IndicesGetFieldMappingRequest.ts @@ -21,19 +21,53 @@ import { RequestBase } from '@_types/Base' import { ExpandWildcards, Fields, Indices } from '@_types/common' /** + * Retrieves mapping definitions for one or more fields. + * For data streams, the API retrieves field mappings for the stream’s backing indices. * @rest_spec_name indices.get_field_mapping * @availability stack since=0.0.0 stability=stable */ export interface Request extends RequestBase { path_parts: { + /** + * Comma-separated list or wildcard expression of fields used to limit returned information. + */ fields: Fields + /** + * Comma-separated list of data streams, indices, and aliases used to limit the request. + * Supports wildcards (`*`). + * To target all data streams and indices, omit this parameter or use `*` or `_all`. + */ index?: Indices } query_parameters: { + /** + * If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. + * This behavior applies even if the request targets other open indices. + * @server_default true + */ allow_no_indices?: boolean + /** + * Type of index that wildcard patterns can match. + * If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. + * Supports comma-separated values, such as `open,hidden`. + * Valid values are: `all`, `open`, `closed`, `hidden`, `none`. + * @server_default open + */ expand_wildcards?: ExpandWildcards + /** + * If `false`, the request returns an error if it targets a missing or closed index. + * @server_default false + */ ignore_unavailable?: boolean + /** + * If `true`, return all default settings in the response. + * @server_default false + */ include_defaults?: boolean + /** + * If `true`, the request retrieves information from the local node only. + * @server_default false + */ local?: boolean } } diff --git a/specification/indices/get_mapping/IndicesGetMappingRequest.ts b/specification/indices/get_mapping/IndicesGetMappingRequest.ts index 96309fdf58..c95c7dbfe1 100644 --- a/specification/indices/get_mapping/IndicesGetMappingRequest.ts +++ b/specification/indices/get_mapping/IndicesGetMappingRequest.ts @@ -22,19 +22,51 @@ import { ExpandWildcards, Indices } from '@_types/common' import { Duration } from '@_types/Time' /** + * Retrieves mapping definitions for one or more indices. + * For data streams, the API retrieves mappings for the stream’s backing indices. * @rest_spec_name indices.get_mapping * @availability stack since=0.0.0 stability=stable * @availability serverless stability=stable visibility=public */ export interface Request extends RequestBase { path_parts: { + /** + * Comma-separated list of data streams, indices, and aliases used to limit the request. + * Supports wildcards (`*`). + * To target all data streams and indices, omit this parameter or use `*` or `_all`. + */ index?: Indices } query_parameters: { + /** + * If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. + * This behavior applies even if the request targets other open indices. + * @server_default true + */ allow_no_indices?: boolean + /** + * Type of index that wildcard patterns can match. + * If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. + * Supports comma-separated values, such as `open,hidden`. + * Valid values are: `all`, `open`, `closed`, `hidden`, `none`. + * @server_default open + */ expand_wildcards?: ExpandWildcards + /** + * If `false`, the request returns an error if it targets a missing or closed index. + * @server_default false + */ ignore_unavailable?: boolean + /** + * If `true`, the request retrieves information from the local node only. + * @server_default false + */ local?: boolean + /** + * Period to wait for a connection to the master node. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ master_timeout?: Duration } } diff --git a/specification/indices/get_template/IndicesGetTemplateRequest.ts b/specification/indices/get_template/IndicesGetTemplateRequest.ts index 8e17d2ce92..a5a24ef596 100644 --- a/specification/indices/get_template/IndicesGetTemplateRequest.ts +++ b/specification/indices/get_template/IndicesGetTemplateRequest.ts @@ -22,17 +22,36 @@ import { Names } from '@_types/common' import { Duration } from '@_types/Time' /** + * Retrieves information about one or more index templates. * @rest_spec_name indices.get_template * @availability stack since=0.0.0 stability=stable * @availability serverless stability=stable visibility=public */ export interface Request extends RequestBase { path_parts: { + /** + * Comma-separated list of index template names used to limit the request. + * Wildcard (`*`) expressions are supported. + * To return all index templates, omit this parameter or use a value of `_all` or `*`. + */ name?: Names } query_parameters: { + /** + * If `true`, returns settings in flat format. + * @server_default false + */ flat_settings?: boolean + /** + * If `true`, the request retrieves information from the local node only. + * @server_default false + */ local?: boolean + /** + * Period to wait for a connection to the master node. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ master_timeout?: Duration } } diff --git a/specification/indices/open/IndicesOpenRequest.ts b/specification/indices/open/IndicesOpenRequest.ts index 4255a74746..9821d50bb9 100644 --- a/specification/indices/open/IndicesOpenRequest.ts +++ b/specification/indices/open/IndicesOpenRequest.ts @@ -22,20 +22,61 @@ import { ExpandWildcards, Indices, WaitForActiveShards } from '@_types/common' import { Duration } from '@_types/Time' /** + * Opens a closed index. + * For data streams, the API opens any closed backing indices. * @rest_spec_name indices.open * @availability stack since=0.0.0 stability=stable * @availability serverless stability=stable visibility=private */ export interface Request extends RequestBase { path_parts: { + /** + * Comma-separated list of data streams, indices, and aliases used to limit the request. + * Supports wildcards (`*`). + * By default, you must explicitly name the indices you using to limit the request. + * To limit a request using `_all`, `*`, or other wildcard expressions, change the `action.destructive_requires_name` setting to false. + * You can update this setting in the `elasticsearch.yml` file or using the cluster update settings API. + * @doc_id cluster-update-settings + */ index: Indices } query_parameters: { + /** + * If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. + * This behavior applies even if the request targets other open indices. + * @server_default true + */ allow_no_indices?: boolean + /** + * Type of index that wildcard patterns can match. + * If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. + * Supports comma-separated values, such as `open,hidden`. + * Valid values are: `all`, `open`, `closed`, `hidden`, `none`. + * @server_default open + */ expand_wildcards?: ExpandWildcards + /** + * If `false`, the request returns an error if it targets a missing or closed index. + * @server_default false + */ ignore_unavailable?: boolean + /** + * Period to wait for a connection to the master node. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ master_timeout?: Duration + /** + * Period to wait for a response. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ timeout?: Duration + /** + * The number of shard copies that must be active before proceeding with the operation. + * Set to `all` or any positive integer up to the total number of shards in the index (`number_of_replicas+1`). + * @server_default 1 + */ wait_for_active_shards?: WaitForActiveShards } } diff --git a/specification/indices/put_alias/IndicesPutAliasRequest.ts b/specification/indices/put_alias/IndicesPutAliasRequest.ts index 5e748f97a4..0730b11863 100644 --- a/specification/indices/put_alias/IndicesPutAliasRequest.ts +++ b/specification/indices/put_alias/IndicesPutAliasRequest.ts @@ -23,24 +23,69 @@ import { QueryContainer } from '@_types/query_dsl/abstractions' import { Duration } from '@_types/Time' /** + * Adds a data stream or index to an alias. * @rest_spec_name indices.put_alias * @availability stack since=0.0.0 stability=stable * @availability serverless stability=stable visibility=public */ export interface Request extends RequestBase { path_parts: { + /** + * Comma-separated list of data streams or indices to add. + * Supports wildcards (`*`). + * Wildcard patterns that match both data streams and indices return an error. + */ index: Indices + /** + * Alias to update. + * If the alias doesn’t exist, the request creates it. + * Index alias names support date math. + * @doc_id api-date-math-index-names + */ name: Name } query_parameters: { + /** + * Period to wait for a connection to the master node. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ master_timeout?: Duration + /** + * Period to wait for a response. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ timeout?: Duration } body: { + /** + * Query used to limit documents the alias can access. + */ filter?: QueryContainer + /** + * Value used to route indexing operations to a specific shard. + * If specified, this overwrites the `routing` value for indexing operations. + * Data stream aliases don’t support this parameter. + */ index_routing?: Routing + /** + * If `true`, sets the write index or data stream for the alias. + * If an alias points to multiple indices or data streams and `is_write_index` isn’t set, the alias rejects write requests. + * If an index alias points to one index and `is_write_index` isn’t set, the index automatically acts as the write index. + * Data stream aliases don’t automatically set a write data stream, even if the alias points to one data stream. + */ is_write_index?: boolean + /** + * Value used to route indexing and search operations to a specific shard. + * Data stream aliases don’t support this parameter. + */ routing?: Routing + /** + * Value used to route search operations to a specific shard. + * If specified, this overwrites the `routing` value for search operations. + * Data stream aliases don’t support this parameter. + */ search_routing?: Routing } } diff --git a/specification/indices/put_data_lifecycle/IndicesPutDataLifecycleRequest.ts b/specification/indices/put_data_lifecycle/IndicesPutDataLifecycleRequest.ts index 8ba9b50420..a508b0eca1 100644 --- a/specification/indices/put_data_lifecycle/IndicesPutDataLifecycleRequest.ts +++ b/specification/indices/put_data_lifecycle/IndicesPutDataLifecycleRequest.ts @@ -29,14 +29,41 @@ import { Duration } from '@_types/Time' */ export interface Request extends RequestBase { path_parts: { + /** + * Comma-separated list of data streams used to limit the request. + * Supports wildcards (`*`). + * To target all data streams use `*` or `_all`. + */ name: DataStreamNames } query_parameters: { + /** + * Type of data stream that wildcard patterns can match. + * Supports comma-separated values, such as `open,hidden`. + * Valid values are: `all`, `hidden`, `open`, `closed`, `none`. + * @server_default open + */ expand_wildcards?: ExpandWildcards + /** + * Period to wait for a connection to the master node. If no response is + * received before the timeout expires, the request fails and returns an + * error. + * @server_default 30s + */ master_timeout?: Duration + /** + * Period to wait for a response. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ timeout?: Duration } body: { + /** + * If defined, every document added to this data stream will be stored at least for this time frame. + * Any time after this duration the document could be deleted. + * When empty, every document in this data stream will be stored indefinitely. + */ data_retention?: Duration } } diff --git a/specification/indices/put_index_template/IndicesPutIndexTemplateRequest.ts b/specification/indices/put_index_template/IndicesPutIndexTemplateRequest.ts index 411f076b90..c99ff7681f 100644 --- a/specification/indices/put_index_template/IndicesPutIndexTemplateRequest.ts +++ b/specification/indices/put_index_template/IndicesPutIndexTemplateRequest.ts @@ -34,6 +34,8 @@ import { integer } from '@_types/Numeric' import { DataLifecycle } from '@indices/_types/DataLifecycle' /** + * Creates or updates an index template. + * Index templates define settings, mappings, and aliases that can be applied automatically to new indices. * @rest_spec_name indices.put_index_template * @availability stack since=7.9.0 stability=stable * @availability serverless stability=stable visibility=public @@ -44,23 +46,70 @@ export interface Request extends RequestBase { name: Name } body: { + /** + * Name of the index template to create. + */ index_patterns?: Indices + /** + * An ordered list of component template names. + * Component templates are merged in the order specified, meaning that the last component template specified has the highest precedence. + */ composed_of?: Name[] + /** + * Template to be applied. + * It may optionally include an `aliases`, `mappings`, or `settings` configuration. + */ template?: IndexTemplateMapping + /** + * If this object is included, the template is used to create data streams and their backing indices. + * Supports an empty object. + * Data streams require a matching index template with a `data_stream` object. + */ data_stream?: DataStreamVisibility + /** + * Priority to determine index template precedence when a new data stream or index is created. + * The index template with the highest priority is chosen. + * If no priority is specified the template is treated as though it is of priority 0 (lowest priority). + * This number is not automatically generated by Elasticsearch. + */ priority?: integer + /** + * Version number used to manage index templates externally. + * This number is not automatically generated by Elasticsearch. + */ version?: VersionNumber - /** @doc_id mapping-meta-field */ + /** + * Optional user metadata about the index template. + * May have any contents. + * This map is not automatically generated by Elasticsearch. + * @doc_id mapping-meta-field */ _meta?: Metadata } query_parameters: { + /** + * If `true`, this request cannot replace or update existing index templates. + * @server_default false + */ create?: boolean } } export class IndexTemplateMapping { + /** + * Aliases to add. + * If the index template includes a `data_stream` object, these are data stream aliases. + * Otherwise, these are index aliases. + * Data stream aliases ignore the `index_routing`, `routing`, and `search_routing` options. + */ aliases?: Dictionary + /** + * Mapping for fields in the index. + * If specified, this mapping can include field names, field data types, and mapping parameters. + */ mappings?: TypeMapping + /** + * Configuration options for the index. + */ settings?: IndexSettings /** * @availability stack since=8.8.0 stability=experimental diff --git a/specification/indices/put_mapping/IndicesPutMappingRequest.ts b/specification/indices/put_mapping/IndicesPutMappingRequest.ts index a14a39e72b..44168f74fd 100644 --- a/specification/indices/put_mapping/IndicesPutMappingRequest.ts +++ b/specification/indices/put_mapping/IndicesPutMappingRequest.ts @@ -40,6 +40,9 @@ import { RuntimeFields } from '@_types/mapping/RuntimeFields' import { Duration } from '@_types/Time' /** + * Adds new fields to an existing data stream or index. + * You can also use this API to change the search settings of existing fields. + * For data streams, these changes are applied to all backing indices by default. * @rest_spec_name indices.put_mapping * @availability stack since=0.0.0 stability=stable * @availability serverless stability=stable visibility=public @@ -49,11 +52,41 @@ export interface Request extends RequestBase { index: Indices } query_parameters: { + /** + * If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. + * This behavior applies even if the request targets other open indices. + * @server_default true + */ allow_no_indices?: boolean + /** + * Type of index that wildcard patterns can match. + * If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. + * Supports comma-separated values, such as `open,hidden`. + * Valid values are: `all`, `open`, `closed`, `hidden`, `none`. + * @server_default open + */ expand_wildcards?: ExpandWildcards + /** + * If `false`, the request returns an error if it targets a missing or closed index. + * @server_default false + */ ignore_unavailable?: boolean + /** + * Period to wait for a connection to the master node. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ master_timeout?: Duration + /** + * Period to wait for a response. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ timeout?: Duration + /** + * If `true`, the mappings are applied only to the current write index for the target. + * @server_default false + */ write_index_only?: boolean } body: { diff --git a/specification/indices/put_template/IndicesPutTemplateRequest.ts b/specification/indices/put_template/IndicesPutTemplateRequest.ts index d0d7ef7dd4..f201434e4f 100644 --- a/specification/indices/put_template/IndicesPutTemplateRequest.ts +++ b/specification/indices/put_template/IndicesPutTemplateRequest.ts @@ -27,6 +27,8 @@ import { integer } from '@_types/Numeric' import { Duration } from '@_types/Time' /** + * Creates or updates an index template. + * Index templates define settings, mappings, and aliases that can be applied automatically to new indices. * @rest_spec_name indices.put_template * @availability stack since=0.0.0 stability=stable * @availability serverless stability=stable visibility=public @@ -41,6 +43,11 @@ export interface Request extends RequestBase { * @server_default false */ create?: boolean + /** + * If `true`, returns settings in flat format. + * @server_default false + * + */ flat_settings?: boolean /** * Period to wait for a connection to the master node. If no response is @@ -48,6 +55,11 @@ export interface Request extends RequestBase { * @server_default 30s */ master_timeout?: Duration + /** + * Period to wait for a response. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ timeout?: Duration /** * Order in which Elasticsearch applies this template if index diff --git a/specification/indices/recovery/IndicesRecoveryRequest.ts b/specification/indices/recovery/IndicesRecoveryRequest.ts index e0fc8f9e91..1c8694ba6d 100644 --- a/specification/indices/recovery/IndicesRecoveryRequest.ts +++ b/specification/indices/recovery/IndicesRecoveryRequest.ts @@ -21,16 +21,31 @@ import { RequestBase } from '@_types/Base' import { Indices } from '@_types/common' /** + * Returns information about ongoing and completed shard recoveries for one or more indices. + * For data streams, the API returns information for the stream’s backing indices. * @rest_spec_name indices.recovery * @availability stack since=0.0.0 stability=stable * @availability serverless stability=stable visibility=private */ export interface Request extends RequestBase { path_parts: { + /** + * Comma-separated list of data streams, indices, and aliases used to limit the request. + * Supports wildcards (`*`). + * To target all data streams and indices, omit this parameter or use `*` or `_all`. + */ index?: Indices } query_parameters: { + /** + * If `true`, the response only includes ongoing shard recoveries. + * @server_default false + */ active_only?: boolean + /** + * If `true`, the response includes detailed information about shard recoveries. + * @server_default false + */ detailed?: boolean } } diff --git a/specification/indices/refresh/IndicesRefreshRequest.ts b/specification/indices/refresh/IndicesRefreshRequest.ts index eb26e3cf91..ee8dd995ad 100644 --- a/specification/indices/refresh/IndicesRefreshRequest.ts +++ b/specification/indices/refresh/IndicesRefreshRequest.ts @@ -21,16 +21,39 @@ import { RequestBase } from '@_types/Base' import { ExpandWildcards, Indices } from '@_types/common' /** + * A refresh makes recent operations performed on one or more indices available for search. + * For data streams, the API runs the refresh operation on the stream’s backing indices. * @rest_spec_name indices.refresh * @availability stack since=0.0.0 stability=stable */ export interface Request extends RequestBase { path_parts: { + /** + * Comma-separated list of data streams, indices, and aliases used to limit the request. + * Supports wildcards (`*`). + * To target all data streams and indices, omit this parameter or use `*` or `_all`. + */ index?: Indices } query_parameters: { + /** + * If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. + * This behavior applies even if the request targets other open indices. + * @server_default true + */ allow_no_indices?: boolean + /** + * Type of index that wildcard patterns can match. + * If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. + * Supports comma-separated values, such as `open,hidden`. + * Valid values are: `all`, `open`, `closed`, `hidden`, `none`. + * @server_default open + */ expand_wildcards?: ExpandWildcards + /** + * If `false`, the request returns an error if it targets a missing or closed index. + * @server_default false + */ ignore_unavailable?: boolean } } diff --git a/specification/indices/resolve_index/ResolveIndexRequest.ts b/specification/indices/resolve_index/ResolveIndexRequest.ts index 060dbdc63b..1909052904 100644 --- a/specification/indices/resolve_index/ResolveIndexRequest.ts +++ b/specification/indices/resolve_index/ResolveIndexRequest.ts @@ -21,15 +21,28 @@ import { RequestBase } from '@_types/Base' import { ExpandWildcards, Names } from '@_types/common' /** + * Resolves the specified name(s) and/or index patterns for indices, aliases, and data streams. + * Multiple patterns and remote clusters are supported. * @rest_spec_name indices.resolve_index * @availability stack since=7.9.0 stability=stable * @availability serverless stability=stable visibility=public */ export interface Request extends RequestBase { path_parts: { + /** + * Comma-separated name(s) or index pattern(s) of the indices, aliases, and data streams to resolve. + * Resources on remote clusters can be specified using the ``:`` syntax. + */ name: Names } query_parameters: { + /** + * Type of index that wildcard patterns can match. + * If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. + * Supports comma-separated values, such as `open,hidden`. + * Valid values are: `all`, `open`, `closed`, `hidden`, `none`. + * @server_default open + */ expand_wildcards?: ExpandWildcards } } diff --git a/specification/indices/rollover/IndicesRolloverRequest.ts b/specification/indices/rollover/IndicesRolloverRequest.ts index 20546267fc..6f74c1d7a9 100644 --- a/specification/indices/rollover/IndicesRolloverRequest.ts +++ b/specification/indices/rollover/IndicesRolloverRequest.ts @@ -27,25 +27,73 @@ import { Duration } from '@_types/Time' import { RolloverConditions } from './types' /** + * Creates a new index for a data stream or index alias. + * @doc_id indices-rollover-index * @rest_spec_name indices.rollover * @availability stack since=5.0.0 stability=stable * @availability serverless stability=stable visibility=public */ export interface Request extends RequestBase { path_parts: { + /** + * Name of the data stream or index alias to roll over. + */ alias: IndexAlias + /** + * Name of the index to create. + * Supports date math. + * Data streams do not support this parameter. + */ new_index?: IndexName } query_parameters: { + /** + * If `true`, checks whether the current index satisfies the specified conditions but does not perform a rollover. + * @server_default false + */ dry_run?: boolean + /** + * Period to wait for a connection to the master node. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ master_timeout?: Duration + /** + * Period to wait for a response. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ timeout?: Duration + /** + * The number of shard copies that must be active before proceeding with the operation. + * Set to all or any positive integer up to the total number of shards in the index (`number_of_replicas+1`). + * @server_default 1 + */ wait_for_active_shards?: WaitForActiveShards } body: { + /** + * Aliases for the target index. + * Data streams do not support this parameter. + */ aliases?: Dictionary + /** + * Conditions for the rollover. + * If specified, Elasticsearch only performs the rollover if the current index satisfies these conditions. + * If this parameter is not specified, Elasticsearch performs the rollover unconditionally. + * If conditions are specified, at least one of them must be a `max_*` condition. + * The index will rollover if any `max_*` condition is satisfied and all `min_*` conditions are satisfied. + */ conditions?: RolloverConditions + /** + * Mapping for fields in the index. + * If specified, this mapping can include field names, field data types, and mapping paramaters. + */ mappings?: TypeMapping + /** + * Configuration options for the index. + * Data streams do not support this parameter. + */ settings?: Dictionary } } diff --git a/specification/indices/segments/IndicesSegmentsRequest.ts b/specification/indices/segments/IndicesSegmentsRequest.ts index bce8e99009..55319f984c 100644 --- a/specification/indices/segments/IndicesSegmentsRequest.ts +++ b/specification/indices/segments/IndicesSegmentsRequest.ts @@ -20,18 +20,44 @@ import { RequestBase } from '@_types/Base' import { ExpandWildcards, Indices } from '@_types/common' -/** +/** Returns low-level information about the Lucene segments in index shards. + * For data streams, the API returns information about the stream’s backing indices. * @rest_spec_name indices.segments * @availability stack since=0.0.0 stability=stable */ export interface Request extends RequestBase { path_parts: { + /** + * Comma-separated list of data streams, indices, and aliases used to limit the request. + * Supports wildcards (`*`). + * To target all data streams and indices, omit this parameter or use `*` or `_all`. + */ index?: Indices } query_parameters: { + /** + * If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. + * This behavior applies even if the request targets other open indices. + * @server_default true + */ allow_no_indices?: boolean + /** + * Type of index that wildcard patterns can match. + * If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. + * Supports comma-separated values, such as `open,hidden`. + * Valid values are: `all`, `open`, `closed`, `hidden`, `none`. + * @server_default open + */ expand_wildcards?: ExpandWildcards + /** + * If `false`, the request returns an error if it targets a missing or closed index. + * @server_default false + */ ignore_unavailable?: boolean + /** + * If `true`, the request returns a verbose response. + * @server_default false + */ verbose?: boolean } } diff --git a/specification/indices/shard_stores/IndicesShardStoresRequest.ts b/specification/indices/shard_stores/IndicesShardStoresRequest.ts index 1980da3895..79df2984dd 100644 --- a/specification/indices/shard_stores/IndicesShardStoresRequest.ts +++ b/specification/indices/shard_stores/IndicesShardStoresRequest.ts @@ -22,6 +22,8 @@ import { ExpandWildcards, Indices } from '@_types/common' import { ShardStoreStatus } from './types' /** + * Retrieves store information about replica shards in one or more indices. + * For data streams, the API retrieves store information for the stream’s backing indices. * @rest_spec_name indices.shard_stores * @availability stack since=0.0.0 stability=stable */ diff --git a/specification/indices/shrink/IndicesShrinkRequest.ts b/specification/indices/shrink/IndicesShrinkRequest.ts index d5c281f3c4..22a6573669 100644 --- a/specification/indices/shrink/IndicesShrinkRequest.ts +++ b/specification/indices/shrink/IndicesShrinkRequest.ts @@ -25,21 +25,51 @@ import { IndexName, WaitForActiveShards } from '@_types/common' import { Duration } from '@_types/Time' /** + * Shrinks an existing index into a new index with fewer primary shards. + * @doc_id indices-shrink-index * @rest_spec_name indices.shrink * @availability stack since=5.0.0 stability=stable */ export interface Request extends RequestBase { path_parts: { + /** + * Name of the source index to shrink. + */ index: IndexName + /** + * Name of the target index to create. + */ target: IndexName } query_parameters: { + /** + * Period to wait for a connection to the master node. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ master_timeout?: Duration + /** + * Period to wait for a response. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ timeout?: Duration + /** + * The number of shard copies that must be active before proceeding with the operation. + * Set to `all` or any positive integer up to the total number of shards in the index (`number_of_replicas+1`). + * @server_default 1 + */ wait_for_active_shards?: WaitForActiveShards } body: { + /** + * The key is the alias name. + * Index alias names support date math. + */ aliases?: Dictionary + /** + * Configuration options for the target index. + */ settings?: Dictionary } } diff --git a/specification/indices/simulate_index_template/IndicesSimulateIndexTemplateRequest.ts b/specification/indices/simulate_index_template/IndicesSimulateIndexTemplateRequest.ts index 84259d36c3..9e8965a4f1 100644 --- a/specification/indices/simulate_index_template/IndicesSimulateIndexTemplateRequest.ts +++ b/specification/indices/simulate_index_template/IndicesSimulateIndexTemplateRequest.ts @@ -31,6 +31,7 @@ import { integer } from '@_types/Numeric' import { IndexTemplateMapping } from '../put_index_template/IndicesPutIndexTemplateRequest' /** + * * @rest_spec_name indices.simulate_index_template * @availability stack since=7.9.0 stability=stable * @availability serverless stability=stable visibility=public @@ -65,14 +66,50 @@ export interface Request extends RequestBase { include_defaults?: boolean } body: { + /** + * This setting overrides the value of the `action.auto_create_index` cluster setting. + * If set to `true` in a template, then indices can be automatically created using that template even if auto-creation of indices is disabled via `actions.auto_create_index`. + * If set to `false`, then indices or data streams matching the template must always be explicitly created, and may never be automatically created. + */ allow_auto_create?: boolean + /** + * Array of wildcard (`*`) expressions used to match the names of data streams and indices during creation. + * @doc_id avoid-index-pattern-collisions + */ index_patterns?: Indices + /** + * An ordered list of component template names. + * Component templates are merged in the order specified, meaning that the last component template specified has the highest precedence. + */ composed_of?: Name[] + /** + * Template to be applied. + * It may optionally include an `aliases`, `mappings`, or `settings` configuration. + */ template?: IndexTemplateMapping + /** + * If this object is included, the template is used to create data streams and their backing indices. + * Supports an empty object. + * Data streams require a matching index template with a `data_stream` object. + */ data_stream?: DataStreamVisibility + /** + * Priority to determine index template precedence when a new data stream or index is created. + * The index template with the highest priority is chosen. + * If no priority is specified the template is treated as though it is of priority 0 (lowest priority). + * This number is not automatically generated by Elasticsearch. + */ priority?: integer + /** + * Version number used to manage index templates externally. + * This number is not automatically generated by Elasticsearch. + */ version?: VersionNumber - /** @doc_id mapping-meta-field */ + /** + * Optional user metadata about the index template. + * May have any contents. + * This map is not automatically generated by Elasticsearch. + * @doc_id mapping-meta-field */ _meta?: Metadata } } diff --git a/specification/indices/split/IndicesSplitRequest.ts b/specification/indices/split/IndicesSplitRequest.ts index 56a94d37ad..7bb87417a7 100644 --- a/specification/indices/split/IndicesSplitRequest.ts +++ b/specification/indices/split/IndicesSplitRequest.ts @@ -25,21 +25,50 @@ import { IndexName, WaitForActiveShards } from '@_types/common' import { Duration } from '@_types/Time' /** + * Splits an existing index into a new index with more primary shards. + * @doc_id indices-split-index * @rest_spec_name indices.split * @availability stack since=6.1.0 stability=stable */ export interface Request extends RequestBase { path_parts: { + /** + * Name of the source index to split. + */ index: IndexName + /** + * Name of the target index to create. + */ target: IndexName } query_parameters: { + /** + * Period to wait for a connection to the master node. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ master_timeout?: Duration + /** + * Period to wait for a response. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ timeout?: Duration + /** + * The number of shard copies that must be active before proceeding with the operation. + * Set to `all` or any positive integer up to the total number of shards in the index (`number_of_replicas+1`). + * @server_default 1 + */ wait_for_active_shards?: WaitForActiveShards } body: { + /** + * Aliases for the resulting index. + */ aliases?: Dictionary + /** + * Configuration options for the target index. + */ settings?: Dictionary } } diff --git a/specification/indices/stats/IndicesStatsRequest.ts b/specification/indices/stats/IndicesStatsRequest.ts index 135a7e8196..9ccceaf4ee 100644 --- a/specification/indices/stats/IndicesStatsRequest.ts +++ b/specification/indices/stats/IndicesStatsRequest.ts @@ -27,6 +27,8 @@ import { } from '@_types/common' /** + * Returns statistics for one or more indices. + * For data streams, the API retrieves statistics for the stream’s backing indices. * @rest_spec_name indices.stats * @availability stack since=1.3.0 stability=stable * @availability serverless stability=stable visibility=private diff --git a/specification/indices/unfreeze/IndicesUnfreezeRequest.ts b/specification/indices/unfreeze/IndicesUnfreezeRequest.ts index 0bc76cb0be..81dfc394a3 100644 --- a/specification/indices/unfreeze/IndicesUnfreezeRequest.ts +++ b/specification/indices/unfreeze/IndicesUnfreezeRequest.ts @@ -22,19 +22,54 @@ import { ExpandWildcards, IndexName } from '@_types/common' import { Duration } from '@_types/Time' /** + * Unfreezes an index. * @rest_spec_name indices.unfreeze * @availability stack since=6.6.0 stability=stable */ export interface Request extends RequestBase { path_parts: { + /** + * Identifier for the index. + */ index: IndexName } query_parameters: { + /** + * If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. + * This behavior applies even if the request targets other open indices. + * @server_default true + */ allow_no_indices?: boolean + /** + * Type of index that wildcard patterns can match. + * If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. + * Supports comma-separated values, such as `open,hidden`. + * Valid values are: `all`, `open`, `closed`, `hidden`, `none`. + * @server_default open + */ expand_wildcards?: ExpandWildcards + /** + * If `false`, the request returns an error if it targets a missing or closed index. + * @server_default false + */ ignore_unavailable?: boolean + /** + * Period to wait for a connection to the master node. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ master_timeout?: Duration + /** + * Period to wait for a response. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ timeout?: Duration + /** + * The number of shard copies that must be active before proceeding with the operation. + * Set to `all` or any positive integer up to the total number of shards in the index (`number_of_replicas+1`). + * @server_default 1 + */ wait_for_active_shards?: string } } diff --git a/specification/indices/update_aliases/IndicesUpdateAliasesRequest.ts b/specification/indices/update_aliases/IndicesUpdateAliasesRequest.ts index b65038ecf0..db3c7737fc 100644 --- a/specification/indices/update_aliases/IndicesUpdateAliasesRequest.ts +++ b/specification/indices/update_aliases/IndicesUpdateAliasesRequest.ts @@ -22,16 +22,30 @@ import { Duration } from '@_types/Time' import { Action } from './types' /** + * Adds a data stream or index to an alias. * @rest_spec_name indices.update_aliases * @availability stack since=1.3.0 stability=stable * @availability serverless stability=stable visibility=public */ export interface Request extends RequestBase { query_parameters: { + /** + * Period to wait for a connection to the master node. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ master_timeout?: Duration + /** + * Period to wait for a response. + * If no response is received before the timeout expires, the request fails and returns an error. + * @server_default 30s + */ timeout?: Duration } body: { + /** + * Actions to perform. + */ actions?: Action[] } } diff --git a/specification/indices/update_aliases/types.ts b/specification/indices/update_aliases/types.ts index d046eb12b3..f284cfc3af 100644 --- a/specification/indices/update_aliases/types.ts +++ b/specification/indices/update_aliases/types.ts @@ -22,39 +22,118 @@ import { QueryContainer } from '@_types/query_dsl/abstractions' /** @variants container */ export class Action { + /** + * Adds a data stream or index to an alias. + * If the alias doesn’t exist, the `add` action creates it. + */ add?: AddAction + /** + * Removes a data stream or index from an alias. + */ remove?: RemoveAction + /** + * Deletes an index. + * You cannot use this action on aliases or data streams. + */ remove_index?: RemoveIndexAction } export class AddAction { + /** + * Alias for the action. + * Index alias names support date math. + */ alias?: IndexAlias + /** + * Aliases for the action. + * Index alias names support date math. + */ aliases?: IndexAlias | IndexAlias[] + /** + * Query used to limit documents the alias can access. + */ filter?: QueryContainer + /** + * Data stream or index for the action. + * Supports wildcards (`*`). + */ index?: IndexName + /** + * Data streams or indices for the action. + * Supports wildcards (`*`). + */ indices?: Indices + /** + * Value used to route indexing operations to a specific shard. + * If specified, this overwrites the `routing` value for indexing operations. + * Data stream aliases don’t support this parameter. + */ index_routing?: Routing - /** @server_default false */ + /** + * If `true`, the alias is hidden. + * @server_default false */ is_hidden?: boolean + /** + * If `true`, sets the write index or data stream for the alias. + */ is_write_index?: boolean + /** + * Value used to route indexing and search operations to a specific shard. + * Data stream aliases don’t support this parameter. + */ routing?: Routing + /** + * Value used to route search operations to a specific shard. + * If specified, this overwrites the `routing` value for search operations. + * Data stream aliases don’t support this parameter. + */ search_routing?: Routing - /** @server_default false */ + /** + * If `true`, the alias must exist to perform the action. + * @server_default false */ must_exist?: boolean } export class RemoveAction { + /** + * Alias for the action. + * Index alias names support date math. + */ alias?: IndexAlias + /** + * Aliases for the action. + * Index alias names support date math. + */ aliases?: IndexAlias | IndexAlias[] + /** + * Data stream or index for the action. + * Supports wildcards (`*`). + */ index?: IndexName + /** + * Data streams or indices for the action. + * Supports wildcards (`*`). + */ indices?: Indices - /** @server_default false */ + /** + * If `true`, the alias must exist to perform the action. + * @server_default false */ must_exist?: boolean } export class RemoveIndexAction { + /** + * Data stream or index for the action. + * Supports wildcards (`*`). + */ index?: IndexName + /** + * Data streams or indices for the action. + * Supports wildcards (`*`). + */ indices?: Indices - /** @server_default false */ + /** + * If `true`, the alias must exist to perform the action. + * @server_default false */ must_exist?: boolean } diff --git a/specification/indices/validate_query/IndicesValidateQueryRequest.ts b/specification/indices/validate_query/IndicesValidateQueryRequest.ts index cc357c4a7d..d41002c5ef 100644 --- a/specification/indices/validate_query/IndicesValidateQueryRequest.ts +++ b/specification/indices/validate_query/IndicesValidateQueryRequest.ts @@ -23,29 +23,89 @@ import { QueryContainer } from '@_types/query_dsl/abstractions' import { Operator } from '@_types/query_dsl/Operator' /** + * Validates a potentially expensive query without executing it. * @rest_spec_name indices.validate_query * @availability stack since=1.3.0 stability=stable * @availability serverless stability=stable visibility=public */ export interface Request extends RequestBase { path_parts: { + /** + * Comma-separated list of data streams, indices, and aliases to search. + * Supports wildcards (`*`). + * To search all data streams or indices, omit this parameter or use `*` or `_all`. + */ index?: Indices } query_parameters: { + /** + * If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. + * This behavior applies even if the request targets other open indices. + * @server_default true + */ allow_no_indices?: boolean + /** + * If `true`, the validation is executed on all shards instead of one random shard per index. + * @server_default false + */ all_shards?: boolean + /** + * Analyzer to use for the query string. + * This parameter can only be used when the `q` query string parameter is specified. + */ analyzer?: string + /** + * If `true`, wildcard and prefix queries are analyzed. + * @server_default false + */ analyze_wildcard?: boolean + /** + * The default operator for query string query: `AND` or `OR`. + * @server_default OR + */ default_operator?: Operator + /** + * Field to use as default where no field prefix is given in the query string. + * This parameter can only be used when the `q` query string parameter is specified. + */ df?: string + /** + * Type of index that wildcard patterns can match. + * If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. + * Supports comma-separated values, such as `open,hidden`. + * Valid values are: `all`, `open`, `closed`, `hidden`, `none`. + * @server_default open + */ expand_wildcards?: ExpandWildcards + /** + * If `true`, the response returns detailed information if an error has occurred. + * @server_default false + */ explain?: boolean + /** + * If `false`, the request returns an error if it targets a missing or closed index. + * @server_default false + */ ignore_unavailable?: boolean + /** + * If `true`, format-based query failures (such as providing text to a numeric field) in the query string will be ignored. + * @server_default false + */ lenient?: boolean + /** + * If `true`, returns a more detailed explanation showing the actual Lucene query that will be executed. + * @server_default false + */ rewrite?: boolean + /** + * Query in the Lucene query string syntax. + */ q?: string } body: { + /** + * Query in the Lucene query string syntax. + */ query?: QueryContainer } }