From 26b700b83209b1d2d2915ff9522c7f0cd7c7232e Mon Sep 17 00:00:00 2001 From: delvedor Date: Thu, 3 Mar 2022 11:18:33 +0100 Subject: [PATCH 1/3] Update API reference for v8 --- docs/reference.asciidoc | 12420 +++++++------------------------------- 1 file changed, 2110 insertions(+), 10310 deletions(-) diff --git a/docs/reference.asciidoc b/docs/reference.asciidoc index 7bbdfbfb7..c13867584 100644 --- a/docs/reference.asciidoc +++ b/docs/reference.asciidoc @@ -1,11807 +1,3607 @@ [[api-reference]] +//////// +=========================================================================================================================== +|| || +|| || +|| || +|| ██████╗ ███████╗ █████╗ ██████╗ ███╗ ███╗███████╗ || +|| ██╔══██╗██╔════╝██╔══██╗██╔══██╗████╗ ████║██╔════╝ || +|| ██████╔╝█████╗ ███████║██║ ██║██╔████╔██║█████╗ || +|| ██╔══██╗██╔══╝ ██╔══██║██║ ██║██║╚██╔╝██║██╔══╝ || +|| ██║ ██║███████╗██║ ██║██████╔╝██║ ╚═╝ ██║███████╗ || +|| ╚═╝ ╚═╝╚══════╝╚═╝ ╚═╝╚═════╝ ╚═╝ ╚═╝╚══════╝ || +|| || +|| || +|| This file is autogenerated, DO NOT send pull requests that changes this file directly. || +|| You should update the script that does the generation, which can be found in: || +|| https://github.com/elastic/elastic-client-generator-js || +|| || +|| You can run the script with the following command: || +|| npm run elasticsearch -- --version || +|| || +|| || +|| || +=========================================================================================================================== +//////// +== API Reference -//////// - - - -=========================================================================================================================== -|| || -|| || -|| || -|| ██████╗ ███████╗ █████╗ ██████╗ ███╗ ███╗███████╗ || -|| ██╔══██╗██╔════╝██╔══██╗██╔══██╗████╗ ████║██╔════╝ || -|| ██████╔╝█████╗ ███████║██║ ██║██╔████╔██║█████╗ || -|| ██╔══██╗██╔══╝ ██╔══██║██║ ██║██║╚██╔╝██║██╔══╝ || -|| ██║ ██║███████╗██║ ██║██████╔╝██║ ╚═╝ ██║███████╗ || -|| ╚═╝ ╚═╝╚══════╝╚═╝ ╚═╝╚═════╝ ╚═╝ ╚═╝╚══════╝ || -|| || -|| || -|| This file is autogenerated, DO NOT send pull requests that changes this file directly. || -|| You should update the script that does the generation, which can be found in '/scripts/utils/generateDocs.js'. || -|| || -|| You can run the script with the following command: || -|| node scripts/generate --branch || -|| or || -|| node scripts/generate --tag || -|| || -|| || -|| || -=========================================================================================================================== - - - -//////// - -== API Reference - -This document contains the entire list of the Elasticsearch API supported by the client, both OSS and commercial. The client is entirely licensed under Apache 2.0. - -Elasticsearch exposes an HTTP layer to communicate with, and the client is a library that will help you do this. Because of this reason, you will see HTTP related parameters, such as `body` or `headers`. - -Every API can accept two objects, the first contains all the parameters that will be sent to Elasticsearch, while the second includes the request specific parameters, such as timeouts, headers, and so on. -In the first object, every parameter but the body will be sent via querystring or url parameter, depending on the API, and every unrecognized parameter will be sent as querystring. - -[source,js] ----- -// promise API -const result = await client.search({ - index: 'my-index', - from: 20, - size: 10, - body: { foo: 'bar' } -}, { - ignore: [404], - maxRetries: 3 -}) - -// callback API -client.search({ - index: 'my-index', - from: 20, - size: 10, - body: { foo: 'bar' } -}, { - ignore: [404], - maxRetries: 3 -}, (err, result) => { - if (err) console.log(err) -}) ----- - -In this document, you will find the reference of every parameter accepted by the querystring or the url. If you also need to send the body, you can find the documentation of its format in the reference link that is present along with every endpoint. - - - -[discrete] -=== Common parameters -Parameters that are accepted by all API endpoints. - -link:{ref}/common-options.html[Documentation] -[cols=2*] -|=== -|`pretty` -|`boolean` - Pretty format the returned JSON response. - -|`human` -|`boolean` - Return human readable values for statistics. + - _Default:_ `true` - -|`error_trace` or `errorTrace` -|`boolean` - Include the stack trace of returned errors. - -|`source` -|`string` - The URL-encoded request definition. Useful for libraries that do not accept a request body for non-POST requests. - -|`filter_path` or `filterPath` -|`list` - A comma-separated list of filters used to reduce the response. - -|=== -[discrete] -=== asyncSearch.delete - -[source,ts] ----- -client.asyncSearch.delete({ - id: string -}) ----- -link:{ref}/async-search.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The async search ID - -|=== - -[discrete] -=== asyncSearch.get - -[source,ts] ----- -client.asyncSearch.get({ - id: string, - wait_for_completion_timeout: string, - keep_alive: string, - typed_keys: boolean -}) ----- -link:{ref}/async-search.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The async search ID - -|`wait_for_completion_timeout` or `waitForCompletionTimeout` -|`string` - Specify the time that the request should block waiting for the final response - -|`keep_alive` or `keepAlive` -|`string` - Specify the time interval in which the results (partial or final) for this search will be available - -|`typed_keys` or `typedKeys` -|`boolean` - Specify whether aggregation and suggester names should be prefixed by their respective types in the response - -|=== - -[discrete] -=== asyncSearch.status - -[source,ts] ----- -client.asyncSearch.status({ - id: string -}) ----- -link:{ref}/async-search.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The async search ID - -|=== - -[discrete] -=== asyncSearch.submit - -[source,ts] ----- -client.asyncSearch.submit({ - index: string | string[], - wait_for_completion_timeout: string, - keep_on_completion: boolean, - keep_alive: string, - batched_reduce_size: number, - request_cache: boolean, - analyzer: string, - analyze_wildcard: boolean, - default_operator: 'AND' | 'OR', - df: string, - explain: boolean, - stored_fields: string | string[], - docvalue_fields: string | string[], - from: number, - ignore_unavailable: boolean, - ignore_throttled: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - lenient: boolean, - preference: string, - q: string, - routing: string | string[], - search_type: 'query_then_fetch' | 'dfs_query_then_fetch', - size: number, - sort: string | string[], - _source: string | string[], - _source_excludes: string | string[], - _source_includes: string | string[], - terminate_after: number, - stats: string | string[], - suggest_field: string, - suggest_mode: 'missing' | 'popular' | 'always', - suggest_size: number, - suggest_text: string, - timeout: string, - track_scores: boolean, - track_total_hits: boolean|long, - allow_partial_search_results: boolean, - typed_keys: boolean, - version: boolean, - seq_no_primary_term: boolean, - max_concurrent_shard_requests: number, - body: object -}) ----- -link:{ref}/async-search.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to search; use `_all` or empty string to perform the operation on all indices - -|`wait_for_completion_timeout` or `waitForCompletionTimeout` -|`string` - Specify the time that the request should block waiting for the final response + -_Default:_ `1s` - -|`keep_on_completion` or `keepOnCompletion` -|`boolean` - Control whether the response should be stored in the cluster if it completed within the provided [wait_for_completion] time (default: false) - -|`keep_alive` or `keepAlive` -|`string` - Update the time interval in which the results (partial or final) for this search will be available + -_Default:_ `5d` - -|`batched_reduce_size` or `batchedReduceSize` -|`number` - The number of shard results that should be reduced at once on the coordinating node. This value should be used as the granularity at which progress results will be made available. + -_Default:_ `5` - -|`request_cache` or `requestCache` -|`boolean` - Specify if request cache should be used for this request or not, defaults to true - -|`analyzer` -|`string` - The analyzer to use for the query string - -|`analyze_wildcard` or `analyzeWildcard` -|`boolean` - Specify whether wildcard and prefix queries should be analyzed (default: false) - -|`default_operator` or `defaultOperator` -|`'AND' \| 'OR'` - The default operator for query string query (AND or OR) + -_Default:_ `OR` - -|`df` -|`string` - The field to use as default where no field prefix is given in the query string - -|`explain` -|`boolean` - Specify whether to return detailed information about score computation as part of a hit - -|`stored_fields` or `storedFields` -|`string \| string[]` - A comma-separated list of stored fields to return as part of a hit - -|`docvalue_fields` or `docvalueFields` -|`string \| string[]` - A comma-separated list of fields to return as the docvalue representation of a field for each hit - -|`from` -|`number` - Starting offset (default: 0) - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`ignore_throttled` or `ignoreThrottled` -|`boolean` - Whether specified concrete, expanded or aliased indices should be ignored when throttled - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`lenient` -|`boolean` - Specify whether format-based query failures (such as providing text to a numeric field) should be ignored - -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) - -|`q` -|`string` - Query in the Lucene query string syntax - -|`routing` -|`string \| string[]` - A comma-separated list of specific routing values - -|`search_type` or `searchType` -|`'query_then_fetch' \| 'dfs_query_then_fetch'` - Search operation type - -|`size` -|`number` - Number of hits to return (default: 10) - -|`sort` -|`string \| string[]` - A comma-separated list of : pairs - -|`_source` -|`string \| string[]` - True or false to return the _source field or not, or a list of fields to return - -|`_source_excludes` or `_sourceExcludes` -|`string \| string[]` - A list of fields to exclude from the returned _source field - -|`_source_includes` or `_sourceIncludes` -|`string \| string[]` - A list of fields to extract and return from the _source field - -|`terminate_after` or `terminateAfter` -|`number` - The maximum number of documents to collect for each shard, upon reaching which the query execution will terminate early. - -|`stats` -|`string \| string[]` - Specific 'tag' of the request for logging and statistical purposes - -|`suggest_field` or `suggestField` -|`string` - Specify which field to use for suggestions - -|`suggest_mode` or `suggestMode` -|`'missing' \| 'popular' \| 'always'` - Specify suggest mode + -_Default:_ `missing` - -|`suggest_size` or `suggestSize` -|`number` - How many suggestions to return in response - -|`suggest_text` or `suggestText` -|`string` - The source text for which the suggestions should be returned - -|`timeout` -|`string` - Explicit operation timeout - -|`track_scores` or `trackScores` -|`boolean` - Whether to calculate and return scores even if they are not used for sorting - -|`track_total_hits` or `trackTotalHits` -|`boolean\|long` - Indicate if the number of documents that match the query should be tracked. A number can also be specified, to accurately track the total hit count up to the number. - -|`allow_partial_search_results` or `allowPartialSearchResults` -|`boolean` - Indicate if an error should be returned if there is a partial search failure or timeout + -_Default:_ `true` - -|`typed_keys` or `typedKeys` -|`boolean` - Specify whether aggregation and suggester names should be prefixed by their respective types in the response - -|`version` -|`boolean` - Specify whether to return document version as part of a hit - -|`seq_no_primary_term` or `seqNoPrimaryTerm` -|`boolean` - Specify whether to return sequence number and primary term of the last modification of each hit - -|`max_concurrent_shard_requests` or `maxConcurrentShardRequests` -|`number` - The number of concurrent shard requests per node this search executes concurrently. This value should be used to limit the impact of the search on the cluster in order to limit the number of concurrent shard requests + -_Default:_ `5` - -|`body` -|`object` - The search definition using the Query DSL - -|=== - -[discrete] -=== autoscaling.deleteAutoscalingPolicy - -[source,ts] ----- -client.autoscaling.deleteAutoscalingPolicy({ - name: string -}) ----- -link:{ref}/autoscaling-delete-autoscaling-policy.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - the name of the autoscaling policy - -|=== - -[discrete] -=== autoscaling.getAutoscalingCapacity - -[source,ts] ----- -client.autoscaling.getAutoscalingCapacity() ----- -link:{ref}/autoscaling-get-autoscaling-capacity.html[Documentation] + - - -[discrete] -=== autoscaling.getAutoscalingPolicy - -[source,ts] ----- -client.autoscaling.getAutoscalingPolicy({ - name: string -}) ----- -link:{ref}/autoscaling-get-autoscaling-policy.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - the name of the autoscaling policy - -|=== - -[discrete] -=== autoscaling.putAutoscalingPolicy - -[source,ts] ----- -client.autoscaling.putAutoscalingPolicy({ - name: string, - body: object -}) ----- -link:{ref}/autoscaling-put-autoscaling-policy.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - the name of the autoscaling policy - -|`body` -|`object` - the specification of the autoscaling policy - -|=== - -[discrete] -=== bulk - -[source,ts] ----- -client.bulk({ - index: string, - type: string, - wait_for_active_shards: string, - refresh: 'true' | 'false' | 'wait_for', - routing: string, - timeout: string, - _source: string | string[], - _source_excludes: string | string[], - _source_includes: string | string[], - pipeline: string, - require_alias: boolean, - body: object -}) ----- -link:{ref}/docs-bulk.html[Documentation] + -{jsclient}/bulk_examples.html[Code Example] + -[cols=2*] -|=== -|`index` -|`string` - Default index for items which don't provide one - -|`type` -|`string` - Default document type for items which don't provide one - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Sets the number of shard copies that must be active before proceeding with the bulk operation. Defaults to 1, meaning the primary shard only. Set to `all` for all shard copies, otherwise set to any non-negative value less than or equal to the total number of copies for the shard (number of replicas + 1) - -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` (the default) then do nothing with refreshes. - -|`routing` -|`string` - Specific routing value - -|`timeout` -|`string` - Explicit operation timeout - -|`_source` -|`string \| string[]` - True or false to return the _source field or not, or default list of fields to return, can be overridden on each sub-request - -|`_source_excludes` or `_sourceExcludes` -|`string \| string[]` - Default list of fields to exclude from the returned _source field, can be overridden on each sub-request - -|`_source_includes` or `_sourceIncludes` -|`string \| string[]` - Default list of fields to extract and return from the _source field, can be overridden on each sub-request - -|`pipeline` -|`string` - The pipeline id to preprocess incoming documents with - -|`require_alias` or `requireAlias` -|`boolean` - Sets require_alias for all incoming documents. Defaults to unset (false) - -|`body` -|`object` - The operation definition and data (action-data pairs), separated by newlines - -|=== - -[discrete] -=== cat.aliases - -[source,ts] ----- -client.cat.aliases({ - name: string | string[], - format: string, - local: boolean, - h: string | string[], - help: boolean, - s: string | string[], - v: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) ----- -link:{ref}/cat-alias.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - A comma-separated list of alias names to return - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`v` -|`boolean` - Verbose mode. Display column headers - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `all` - -|=== - -[discrete] -=== cat.allocation - -[source,ts] ----- -client.cat.allocation({ - node_id: string | string[], - format: string, - bytes: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb', - local: boolean, - master_timeout: string, - h: string | string[], - help: boolean, - s: string | string[], - v: boolean -}) ----- -link:{ref}/cat-allocation.html[Documentation] + -[cols=2*] -|=== -|`node_id` or `nodeId` -|`string \| string[]` - A comma-separated list of node IDs or names to limit the returned information - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`bytes` -|`'b' \| 'k' \| 'kb' \| 'm' \| 'mb' \| 'g' \| 'gb' \| 't' \| 'tb' \| 'p' \| 'pb'` - The unit in which to display byte values - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.count - -[source,ts] ----- -client.cat.count({ - index: string | string[], - format: string, - h: string | string[], - help: boolean, - s: string | string[], - v: boolean -}) ----- -link:{ref}/cat-count.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to limit the returned information - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.fielddata - -[source,ts] ----- -client.cat.fielddata({ - fields: string | string[], - format: string, - bytes: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb', - h: string | string[], - help: boolean, - s: string | string[], - v: boolean -}) ----- -link:{ref}/cat-fielddata.html[Documentation] + -[cols=2*] -|=== -|`fields` -|`string \| string[]` - A comma-separated list of fields to return the fielddata size - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`bytes` -|`'b' \| 'k' \| 'kb' \| 'm' \| 'mb' \| 'g' \| 'gb' \| 't' \| 'tb' \| 'p' \| 'pb'` - The unit in which to display byte values - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.health - -[source,ts] ----- -client.cat.health({ - format: string, - h: string | string[], - help: boolean, - s: string | string[], - time: 'd' | 'h' | 'm' | 's' | 'ms' | 'micros' | 'nanos', - ts: boolean, - v: boolean -}) ----- -link:{ref}/cat-health.html[Documentation] + -[cols=2*] -|=== -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`time` -|`'d' \| 'h' \| 'm' \| 's' \| 'ms' \| 'micros' \| 'nanos'` - The unit in which to display time values - -|`ts` -|`boolean` - Set to false to disable timestamping + -_Default:_ `true` - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.help - -[source,ts] ----- -client.cat.help({ - help: boolean, - s: string | string[] -}) ----- -link:{ref}/cat.html[Documentation] + -[cols=2*] -|=== -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|=== - -[discrete] -=== cat.indices - -[source,ts] ----- -client.cat.indices({ - index: string | string[], - format: string, - bytes: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb', - master_timeout: string, - h: string | string[], - health: 'green' | 'yellow' | 'red', - help: boolean, - pri: boolean, - s: string | string[], - time: 'd' | 'h' | 'm' | 's' | 'ms' | 'micros' | 'nanos', - v: boolean, - include_unloaded_segments: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) ----- -link:{ref}/cat-indices.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to limit the returned information - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`bytes` -|`'b' \| 'k' \| 'kb' \| 'm' \| 'mb' \| 'g' \| 'gb' \| 't' \| 'tb' \| 'p' \| 'pb'` - The unit in which to display byte values - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`health` -|`'green' \| 'yellow' \| 'red'` - A health status ("green", "yellow", or "red" to filter only indices matching the specified health status - -|`help` -|`boolean` - Return help information - -|`pri` -|`boolean` - Set to true to return stats only for primary shards - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`time` -|`'d' \| 'h' \| 'm' \| 's' \| 'ms' \| 'micros' \| 'nanos'` - The unit in which to display time values - -|`v` -|`boolean` - Verbose mode. Display column headers - -|`include_unloaded_segments` or `includeUnloadedSegments` -|`boolean` - If set to true segment stats will include stats for segments that are not currently loaded into memory - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `all` - -|=== - -[discrete] -=== cat.master - -[source,ts] ----- -client.cat.master({ - format: string, - local: boolean, - master_timeout: string, - h: string | string[], - help: boolean, - s: string | string[], - v: boolean -}) ----- -link:{ref}/cat-master.html[Documentation] + -[cols=2*] -|=== -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.mlDataFrameAnalytics - -[source,ts] ----- -client.cat.mlDataFrameAnalytics({ - id: string, - allow_no_match: boolean, - bytes: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb', - format: string, - h: string | string[], - help: boolean, - s: string | string[], - time: 'd' | 'h' | 'm' | 's' | 'ms' | 'micros' | 'nanos', - v: boolean -}) ----- -link:{ref}/cat-dfanalytics.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the data frame analytics to fetch - -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no configs. (This includes `_all` string or when no configs have been specified) - -|`bytes` -|`'b' \| 'k' \| 'kb' \| 'm' \| 'mb' \| 'g' \| 'gb' \| 't' \| 'tb' \| 'p' \| 'pb'` - The unit in which to display byte values - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`time` -|`'d' \| 'h' \| 'm' \| 's' \| 'ms' \| 'micros' \| 'nanos'` - The unit in which to display time values - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.mlDatafeeds - -[source,ts] ----- -client.cat.mlDatafeeds({ - datafeed_id: string, - allow_no_match: boolean, - allow_no_datafeeds: boolean, - format: string, - h: string | string[], - help: boolean, - s: string | string[], - time: 'd' | 'h' | 'm' | 's' | 'ms' | 'micros' | 'nanos', - v: boolean -}) ----- -link:{ref}/cat-datafeeds.html[Documentation] + -[cols=2*] -|=== -|`datafeed_id` or `datafeedId` -|`string` - The ID of the datafeeds stats to fetch - -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no datafeeds. (This includes `_all` string or when no datafeeds have been specified) - -|`allow_no_datafeeds` or `allowNoDatafeeds` -|`boolean` - Whether to ignore if a wildcard expression matches no datafeeds. (This includes `_all` string or when no datafeeds have been specified) + - -WARNING: This parameter has been deprecated. - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`time` -|`'d' \| 'h' \| 'm' \| 's' \| 'ms' \| 'micros' \| 'nanos'` - The unit in which to display time values - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.mlJobs - -[source,ts] ----- -client.cat.mlJobs({ - job_id: string, - allow_no_match: boolean, - allow_no_jobs: boolean, - bytes: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb', - format: string, - h: string | string[], - help: boolean, - s: string | string[], - time: 'd' | 'h' | 'm' | 's' | 'ms' | 'micros' | 'nanos', - v: boolean -}) ----- -link:{ref}/cat-anomaly-detectors.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the jobs stats to fetch - -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no jobs. (This includes `_all` string or when no jobs have been specified) - -|`allow_no_jobs` or `allowNoJobs` -|`boolean` - Whether to ignore if a wildcard expression matches no jobs. (This includes `_all` string or when no jobs have been specified) + - -WARNING: This parameter has been deprecated. - -|`bytes` -|`'b' \| 'k' \| 'kb' \| 'm' \| 'mb' \| 'g' \| 'gb' \| 't' \| 'tb' \| 'p' \| 'pb'` - The unit in which to display byte values - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`time` -|`'d' \| 'h' \| 'm' \| 's' \| 'ms' \| 'micros' \| 'nanos'` - The unit in which to display time values - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.mlTrainedModels - -[source,ts] ----- -client.cat.mlTrainedModels({ - model_id: string, - allow_no_match: boolean, - from: number, - size: number, - bytes: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb', - format: string, - h: string | string[], - help: boolean, - s: string | string[], - time: 'd' | 'h' | 'm' | 's' | 'ms' | 'micros' | 'nanos', - v: boolean -}) ----- -link:{ref}/cat-trained-model.html[Documentation] + -[cols=2*] -|=== -|`model_id` or `modelId` -|`string` - The ID of the trained models stats to fetch - -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no trained models. (This includes `_all` string or when no trained models have been specified) + -_Default:_ `true` - -|`from` -|`number` - skips a number of trained models - -|`size` -|`number` - specifies a max number of trained models to get + -_Default:_ `100` - -|`bytes` -|`'b' \| 'k' \| 'kb' \| 'm' \| 'mb' \| 'g' \| 'gb' \| 't' \| 'tb' \| 'p' \| 'pb'` - The unit in which to display byte values - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`time` -|`'d' \| 'h' \| 'm' \| 's' \| 'ms' \| 'micros' \| 'nanos'` - The unit in which to display time values - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.nodeattrs - -[source,ts] ----- -client.cat.nodeattrs({ - format: string, - local: boolean, - master_timeout: string, - h: string | string[], - help: boolean, - s: string | string[], - v: boolean -}) ----- -link:{ref}/cat-nodeattrs.html[Documentation] + -[cols=2*] -|=== -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.nodes - -[source,ts] ----- -client.cat.nodes({ - bytes: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb', - format: string, - full_id: boolean, - master_timeout: string, - h: string | string[], - help: boolean, - s: string | string[], - time: 'd' | 'h' | 'm' | 's' | 'ms' | 'micros' | 'nanos', - v: boolean, - include_unloaded_segments: boolean -}) ----- -link:{ref}/cat-nodes.html[Documentation] + -[cols=2*] -|=== -|`bytes` -|`'b' \| 'k' \| 'kb' \| 'm' \| 'mb' \| 'g' \| 'gb' \| 't' \| 'tb' \| 'p' \| 'pb'` - The unit in which to display byte values - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`full_id` or `fullId` -|`boolean` - Return the full node ID instead of the shortened version (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`time` -|`'d' \| 'h' \| 'm' \| 's' \| 'ms' \| 'micros' \| 'nanos'` - The unit in which to display time values - -|`v` -|`boolean` - Verbose mode. Display column headers - -|`include_unloaded_segments` or `includeUnloadedSegments` -|`boolean` - If set to true segment stats will include stats for segments that are not currently loaded into memory - -|=== - -[discrete] -=== cat.pendingTasks - -[source,ts] ----- -client.cat.pendingTasks({ - format: string, - local: boolean, - master_timeout: string, - h: string | string[], - help: boolean, - s: string | string[], - time: 'd' | 'h' | 'm' | 's' | 'ms' | 'micros' | 'nanos', - v: boolean -}) ----- -link:{ref}/cat-pending-tasks.html[Documentation] + -[cols=2*] -|=== -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`time` -|`'d' \| 'h' \| 'm' \| 's' \| 'ms' \| 'micros' \| 'nanos'` - The unit in which to display time values - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.plugins - -[source,ts] ----- -client.cat.plugins({ - format: string, - local: boolean, - master_timeout: string, - h: string | string[], - help: boolean, - include_bootstrap: boolean, - s: string | string[], - v: boolean -}) ----- -link:{ref}/cat-plugins.html[Documentation] + -[cols=2*] -|=== -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`include_bootstrap` or `includeBootstrap` -|`boolean` - Include bootstrap plugins in the response - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.recovery - -[source,ts] ----- -client.cat.recovery({ - index: string | string[], - format: string, - active_only: boolean, - bytes: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb', - detailed: boolean, - h: string | string[], - help: boolean, - s: string | string[], - time: 'd' | 'h' | 'm' | 's' | 'ms' | 'micros' | 'nanos', - v: boolean -}) ----- -link:{ref}/cat-recovery.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - Comma-separated list or wildcard expression of index names to limit the returned information - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`active_only` or `activeOnly` -|`boolean` - If `true`, the response only includes ongoing shard recoveries - -|`bytes` -|`'b' \| 'k' \| 'kb' \| 'm' \| 'mb' \| 'g' \| 'gb' \| 't' \| 'tb' \| 'p' \| 'pb'` - The unit in which to display byte values - -|`detailed` -|`boolean` - If `true`, the response includes detailed information about shard recoveries - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`time` -|`'d' \| 'h' \| 'm' \| 's' \| 'ms' \| 'micros' \| 'nanos'` - The unit in which to display time values - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.repositories - -[source,ts] ----- -client.cat.repositories({ - format: string, - local: boolean, - master_timeout: string, - h: string | string[], - help: boolean, - s: string | string[], - v: boolean -}) ----- -link:{ref}/cat-repositories.html[Documentation] + -[cols=2*] -|=== -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.segments - -[source,ts] ----- -client.cat.segments({ - index: string | string[], - format: string, - bytes: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb', - h: string | string[], - help: boolean, - s: string | string[], - v: boolean -}) ----- -link:{ref}/cat-segments.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to limit the returned information - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`bytes` -|`'b' \| 'k' \| 'kb' \| 'm' \| 'mb' \| 'g' \| 'gb' \| 't' \| 'tb' \| 'p' \| 'pb'` - The unit in which to display byte values - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.shards - -[source,ts] ----- -client.cat.shards({ - index: string | string[], - format: string, - bytes: 'b' | 'k' | 'kb' | 'm' | 'mb' | 'g' | 'gb' | 't' | 'tb' | 'p' | 'pb', - master_timeout: string, - h: string | string[], - help: boolean, - s: string | string[], - time: 'd' | 'h' | 'm' | 's' | 'ms' | 'micros' | 'nanos', - v: boolean -}) ----- -link:{ref}/cat-shards.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to limit the returned information - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`bytes` -|`'b' \| 'k' \| 'kb' \| 'm' \| 'mb' \| 'g' \| 'gb' \| 't' \| 'tb' \| 'p' \| 'pb'` - The unit in which to display byte values - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`time` -|`'d' \| 'h' \| 'm' \| 's' \| 'ms' \| 'micros' \| 'nanos'` - The unit in which to display time values - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.snapshots - -[source,ts] ----- -client.cat.snapshots({ - repository: string | string[], - format: string, - ignore_unavailable: boolean, - master_timeout: string, - h: string | string[], - help: boolean, - s: string | string[], - time: 'd' | 'h' | 'm' | 's' | 'ms' | 'micros' | 'nanos', - v: boolean -}) ----- -link:{ref}/cat-snapshots.html[Documentation] + -[cols=2*] -|=== -|`repository` -|`string \| string[]` - Name of repository from which to fetch the snapshot information - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Set to true to ignore unavailable snapshots - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`time` -|`'d' \| 'h' \| 'm' \| 's' \| 'ms' \| 'micros' \| 'nanos'` - The unit in which to display time values - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.tasks -*Stability:* experimental -[source,ts] ----- -client.cat.tasks({ - format: string, - nodes: string | string[], - actions: string | string[], - detailed: boolean, - parent_task_id: string, - h: string | string[], - help: boolean, - s: string | string[], - time: 'd' | 'h' | 'm' | 's' | 'ms' | 'micros' | 'nanos', - v: boolean -}) ----- -link:{ref}/tasks.html[Documentation] + -[cols=2*] -|=== -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`nodes` -|`string \| string[]` - A comma-separated list of node IDs or names to limit the returned information; use `_local` to return information from the node you're connecting to, leave empty to get information from all nodes - -|`actions` -|`string \| string[]` - A comma-separated list of actions that should be returned. Leave empty to return all. - -|`detailed` -|`boolean` - Return detailed task information (default: false) - -|`parent_task_id` or `parentTaskId` -|`string` - Return tasks with specified parent task id (node_id:task_number). Set to -1 to return all. - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`time` -|`'d' \| 'h' \| 'm' \| 's' \| 'ms' \| 'micros' \| 'nanos'` - The unit in which to display time values - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.templates - -[source,ts] ----- -client.cat.templates({ - name: string, - format: string, - local: boolean, - master_timeout: string, - h: string | string[], - help: boolean, - s: string | string[], - v: boolean -}) ----- -link:{ref}/cat-templates.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - A pattern that returned template names must match - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.threadPool - -[source,ts] ----- -client.cat.threadPool({ - thread_pool_patterns: string | string[], - format: string, - time: 'd' | 'h' | 'm' | 's' | 'ms' | 'micros' | 'nanos', - local: boolean, - master_timeout: string, - h: string | string[], - help: boolean, - s: string | string[], - v: boolean -}) ----- -link:{ref}/cat-thread-pool.html[Documentation] + -[cols=2*] -|=== -|`thread_pool_patterns` or `threadPoolPatterns` -|`string \| string[]` - A comma-separated list of regular-expressions to filter the thread pools in the output - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`time` -|`'d' \| 'h' \| 'm' \| 's' \| 'ms' \| 'micros' \| 'nanos'` - The unit in which to display time values - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== cat.transforms - -[source,ts] ----- -client.cat.transforms({ - transform_id: string, - from: number, - size: number, - allow_no_match: boolean, - format: string, - h: string | string[], - help: boolean, - s: string | string[], - time: 'd' | 'h' | 'm' | 's' | 'ms' | 'micros' | 'nanos', - v: boolean -}) ----- -link:{ref}/cat-transforms.html[Documentation] + -[cols=2*] -|=== -|`transform_id` or `transformId` -|`string` - The id of the transform for which to get stats. '_all' or '*' implies all transforms - -|`from` -|`number` - skips a number of transform configs, defaults to 0 - -|`size` -|`number` - specifies a max number of transforms to get, defaults to 100 - -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no transforms. (This includes `_all` string or when no transforms have been specified) - -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`h` -|`string \| string[]` - Comma-separated list of column names to display - -|`help` -|`boolean` - Return help information - -|`s` -|`string \| string[]` - Comma-separated list of column names or column aliases to sort by - -|`time` -|`'d' \| 'h' \| 'm' \| 's' \| 'ms' \| 'micros' \| 'nanos'` - The unit in which to display time values - -|`v` -|`boolean` - Verbose mode. Display column headers - -|=== - -[discrete] -=== ccr.deleteAutoFollowPattern - -[source,ts] ----- -client.ccr.deleteAutoFollowPattern({ - name: string -}) ----- -link:{ref}/ccr-delete-auto-follow-pattern.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the auto follow pattern. - -|=== - -[discrete] -=== ccr.follow - -[source,ts] ----- -client.ccr.follow({ - index: string, - wait_for_active_shards: string, - body: object -}) ----- -link:{ref}/ccr-put-follow.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the follower index - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Sets the number of shard copies that must be active before returning. Defaults to 0. Set to `all` for all shard copies, otherwise set to any non-negative value less than or equal to the total number of copies for the shard (number of replicas + 1) + -_Default:_ `0` - -|`body` -|`object` - The name of the leader index and other optional ccr related parameters - -|=== - -[discrete] -=== ccr.followInfo - -[source,ts] ----- -client.ccr.followInfo({ - index: string | string[] -}) ----- -link:{ref}/ccr-get-follow-info.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index patterns; use `_all` to perform the operation on all indices - -|=== - -[discrete] -=== ccr.followStats - -[source,ts] ----- -client.ccr.followStats({ - index: string | string[] -}) ----- -link:{ref}/ccr-get-follow-stats.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index patterns; use `_all` to perform the operation on all indices - -|=== - -[discrete] -=== ccr.forgetFollower - -[source,ts] ----- -client.ccr.forgetFollower({ - index: string, - body: object -}) ----- -link:{ref}/ccr-post-forget-follower.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - the name of the leader index for which specified follower retention leases should be removed - -|`body` -|`object` - the name and UUID of the follower index, the name of the cluster containing the follower index, and the alias from the perspective of that cluster for the remote cluster containing the leader index - -|=== - -[discrete] -=== ccr.getAutoFollowPattern - -[source,ts] ----- -client.ccr.getAutoFollowPattern({ - name: string -}) ----- -link:{ref}/ccr-get-auto-follow-pattern.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the auto follow pattern. - -|=== - -[discrete] -=== ccr.pauseAutoFollowPattern - -[source,ts] ----- -client.ccr.pauseAutoFollowPattern({ - name: string -}) ----- -link:{ref}/ccr-pause-auto-follow-pattern.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the auto follow pattern that should pause discovering new indices to follow. - -|=== - -[discrete] -=== ccr.pauseFollow - -[source,ts] ----- -client.ccr.pauseFollow({ - index: string -}) ----- -link:{ref}/ccr-post-pause-follow.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the follower index that should pause following its leader index. - -|=== - -[discrete] -=== ccr.putAutoFollowPattern - -[source,ts] ----- -client.ccr.putAutoFollowPattern({ - name: string, - body: object -}) ----- -link:{ref}/ccr-put-auto-follow-pattern.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the auto follow pattern. - -|`body` -|`object` - The specification of the auto follow pattern - -|=== - -[discrete] -=== ccr.resumeAutoFollowPattern - -[source,ts] ----- -client.ccr.resumeAutoFollowPattern({ - name: string -}) ----- -link:{ref}/ccr-resume-auto-follow-pattern.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the auto follow pattern to resume discovering new indices to follow. - -|=== - -[discrete] -=== ccr.resumeFollow - -[source,ts] ----- -client.ccr.resumeFollow({ - index: string, - body: object -}) ----- -link:{ref}/ccr-post-resume-follow.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the follow index to resume following. - -|`body` -|`object` - The name of the leader index and other optional ccr related parameters - -|=== - -[discrete] -=== ccr.stats - -[source,ts] ----- -client.ccr.stats() ----- -link:{ref}/ccr-get-stats.html[Documentation] + - - -[discrete] -=== ccr.unfollow - -[source,ts] ----- -client.ccr.unfollow({ - index: string -}) ----- -link:{ref}/ccr-post-unfollow.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the follower index that should be turned into a regular index. - -|=== - -[discrete] -=== clearScroll - -[source,ts] ----- -client.clearScroll({ - scroll_id: string | string[], - body: object -}) ----- -link:{ref}/clear-scroll-api.html[Documentation] + -[cols=2*] -|=== -|`scroll_id` or `scrollId` -|`string \| string[]` - A comma-separated list of scroll IDs to clear + - -WARNING: This parameter has been deprecated. - -|`body` -|`object` - A comma-separated list of scroll IDs to clear if none was specified via the scroll_id parameter - -|=== - -[discrete] -=== closePointInTime - -[source,ts] ----- -client.closePointInTime({ - body: object -}) ----- -link:{ref}/point-in-time-api.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - a point-in-time id to close - -|=== - -[discrete] -=== cluster.allocationExplain - -[source,ts] ----- -client.cluster.allocationExplain({ - include_yes_decisions: boolean, - include_disk_info: boolean, - body: object -}) ----- -link:{ref}/cluster-allocation-explain.html[Documentation] + -[cols=2*] -|=== -|`include_yes_decisions` or `includeYesDecisions` -|`boolean` - Return 'YES' decisions in explanation (default: false) - -|`include_disk_info` or `includeDiskInfo` -|`boolean` - Return information about disk usage and shard sizes (default: false) - -|`body` -|`object` - The index, shard, and primary flag to explain. Empty means 'explain a randomly-chosen unassigned shard' - -|=== - -[discrete] -=== cluster.deleteComponentTemplate - -[source,ts] ----- -client.cluster.deleteComponentTemplate({ - name: string, - timeout: string, - master_timeout: string -}) ----- -link:{ref}/indices-component-template.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the template - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|=== - -[discrete] -=== cluster.deleteVotingConfigExclusions - -[source,ts] ----- -client.cluster.deleteVotingConfigExclusions({ - wait_for_removal: boolean -}) ----- -link:{ref}/voting-config-exclusions.html[Documentation] + -[cols=2*] -|=== -|`wait_for_removal` or `waitForRemoval` -|`boolean` - Specifies whether to wait for all excluded nodes to be removed from the cluster before clearing the voting configuration exclusions list. + -_Default:_ `true` - -|=== - -[discrete] -=== cluster.existsComponentTemplate - -[source,ts] ----- -client.cluster.existsComponentTemplate({ - name: string, - master_timeout: string, - local: boolean -}) ----- -link:{ref}/indices-component-template.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the template - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|=== - -[discrete] -=== cluster.getComponentTemplate - -[source,ts] ----- -client.cluster.getComponentTemplate({ - name: string | string[], - master_timeout: string, - local: boolean -}) ----- -link:{ref}/indices-component-template.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - The comma separated names of the component templates - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|=== - -[discrete] -=== cluster.getSettings - -[source,ts] ----- -client.cluster.getSettings({ - flat_settings: boolean, - master_timeout: string, - timeout: string, - include_defaults: boolean -}) ----- -link:{ref}/cluster-get-settings.html[Documentation] + -[cols=2*] -|=== -|`flat_settings` or `flatSettings` -|`boolean` - Return settings in flat format (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`timeout` -|`string` - Explicit operation timeout - -|`include_defaults` or `includeDefaults` -|`boolean` - Whether to return all default clusters setting. - -|=== - -[discrete] -=== cluster.health - -[source,ts] ----- -client.cluster.health({ - index: string | string[], - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - level: 'cluster' | 'indices' | 'shards', - local: boolean, - master_timeout: string, - timeout: string, - wait_for_active_shards: string, - wait_for_nodes: string, - wait_for_events: 'immediate' | 'urgent' | 'high' | 'normal' | 'low' | 'languid', - wait_for_no_relocating_shards: boolean, - wait_for_no_initializing_shards: boolean, - wait_for_status: 'green' | 'yellow' | 'red' -}) ----- -link:{ref}/cluster-health.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - Limit the information returned to a specific index - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `all` - -|`level` -|`'cluster' \| 'indices' \| 'shards'` - Specify the level of detail for returned information + -_Default:_ `cluster` - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`timeout` -|`string` - Explicit operation timeout - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Wait until the specified number of shards is active - -|`wait_for_nodes` or `waitForNodes` -|`string` - Wait until the specified number of nodes is available - -|`wait_for_events` or `waitForEvents` -|`'immediate' \| 'urgent' \| 'high' \| 'normal' \| 'low' \| 'languid'` - Wait until all currently queued events with the given priority are processed - -|`wait_for_no_relocating_shards` or `waitForNoRelocatingShards` -|`boolean` - Whether to wait until there are no relocating shards in the cluster - -|`wait_for_no_initializing_shards` or `waitForNoInitializingShards` -|`boolean` - Whether to wait until there are no initializing shards in the cluster - -|`wait_for_status` or `waitForStatus` -|`'green' \| 'yellow' \| 'red'` - Wait until cluster is in a specific state - -|=== - -[discrete] -=== cluster.pendingTasks - -[source,ts] ----- -client.cluster.pendingTasks({ - local: boolean, - master_timeout: string -}) ----- -link:{ref}/cluster-pending.html[Documentation] + -[cols=2*] -|=== -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|=== - -[discrete] -=== cluster.postVotingConfigExclusions - -[source,ts] ----- -client.cluster.postVotingConfigExclusions({ - node_ids: string, - node_names: string, - timeout: string -}) ----- -link:{ref}/voting-config-exclusions.html[Documentation] + -[cols=2*] -|=== -|`node_ids` or `nodeIds` -|`string` - A comma-separated list of the persistent ids of the nodes to exclude from the voting configuration. If specified, you may not also specify ?node_names. - -|`node_names` or `nodeNames` -|`string` - A comma-separated list of the names of the nodes to exclude from the voting configuration. If specified, you may not also specify ?node_ids. - -|`timeout` -|`string` - Explicit operation timeout + -_Default:_ `30s` - -|=== - -[discrete] -=== cluster.putComponentTemplate - -[source,ts] ----- -client.cluster.putComponentTemplate({ - name: string, - create: boolean, - timeout: string, - master_timeout: string, - body: object -}) ----- -link:{ref}/indices-component-template.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the template - -|`create` -|`boolean` - Whether the index template should only be added if new or can also replace an existing one - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`body` -|`object` - The template definition - -|=== - -[discrete] -=== cluster.putSettings - -[source,ts] ----- -client.cluster.putSettings({ - flat_settings: boolean, - master_timeout: string, - timeout: string, - body: object -}) ----- -link:{ref}/cluster-update-settings.html[Documentation] + -[cols=2*] -|=== -|`flat_settings` or `flatSettings` -|`boolean` - Return settings in flat format (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`timeout` -|`string` - Explicit operation timeout - -|`body` -|`object` - The settings to be updated. Can be either `transient` or `persistent` (survives cluster restart). - -|=== - -[discrete] -=== cluster.remoteInfo - -[source,ts] ----- -client.cluster.remoteInfo() ----- -link:{ref}/cluster-remote-info.html[Documentation] + - - -[discrete] -=== cluster.reroute - -[source,ts] ----- -client.cluster.reroute({ - dry_run: boolean, - explain: boolean, - retry_failed: boolean, - metric: string | string[], - master_timeout: string, - timeout: string, - body: object -}) ----- -link:{ref}/cluster-reroute.html[Documentation] + -[cols=2*] -|=== -|`dry_run` or `dryRun` -|`boolean` - Simulate the operation only and return the resulting state - -|`explain` -|`boolean` - Return an explanation of why the commands can or cannot be executed - -|`retry_failed` or `retryFailed` -|`boolean` - Retries allocation of shards that are blocked due to too many subsequent allocation failures - -|`metric` -|`string \| string[]` - Limit the information returned to the specified metrics. Defaults to all but metadata - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`timeout` -|`string` - Explicit operation timeout - -|`body` -|`object` - The definition of `commands` to perform (`move`, `cancel`, `allocate`) - -|=== - -[discrete] -=== cluster.state - -[source,ts] ----- -client.cluster.state({ - index: string | string[], - metric: string | string[], - local: boolean, - master_timeout: string, - flat_settings: boolean, - wait_for_metadata_version: number, - wait_for_timeout: string, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) ----- -link:{ref}/cluster-state.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices - -|`metric` -|`string \| string[]` - Limit the information returned to the specified metrics - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`flat_settings` or `flatSettings` -|`boolean` - Return settings in flat format (default: false) - -|`wait_for_metadata_version` or `waitForMetadataVersion` -|`number` - Wait for the metadata version to be equal or greater than the specified metadata version - -|`wait_for_timeout` or `waitForTimeout` -|`string` - The maximum time to wait for wait_for_metadata_version before timing out - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|=== - -[discrete] -=== cluster.stats - -[source,ts] ----- -client.cluster.stats({ - node_id: string | string[], - flat_settings: boolean, - timeout: string -}) ----- -link:{ref}/cluster-stats.html[Documentation] + -[cols=2*] -|=== -|`node_id` or `nodeId` -|`string \| string[]` - A comma-separated list of node IDs or names to limit the returned information; use `_local` to return information from the node you're connecting to, leave empty to get information from all nodes - -|`flat_settings` or `flatSettings` -|`boolean` - Return settings in flat format (default: false) - -|`timeout` -|`string` - Explicit operation timeout - -|=== - -[discrete] -=== count - -[source,ts] ----- -client.count({ - index: string | string[], - ignore_unavailable: boolean, - ignore_throttled: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - min_score: number, - preference: string, - routing: string | string[], - q: string, - analyzer: string, - analyze_wildcard: boolean, - default_operator: 'AND' | 'OR', - df: string, - lenient: boolean, - terminate_after: number, - body: object -}) ----- -link:{ref}/search-count.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of indices to restrict the results - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`ignore_throttled` or `ignoreThrottled` -|`boolean` - Whether specified concrete, expanded or aliased indices should be ignored when throttled - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`min_score` or `minScore` -|`number` - Include only documents with a specific `_score` value in the result - -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) - -|`routing` -|`string \| string[]` - A comma-separated list of specific routing values - -|`q` -|`string` - Query in the Lucene query string syntax - -|`analyzer` -|`string` - The analyzer to use for the query string - -|`analyze_wildcard` or `analyzeWildcard` -|`boolean` - Specify whether wildcard and prefix queries should be analyzed (default: false) - -|`default_operator` or `defaultOperator` -|`'AND' \| 'OR'` - The default operator for query string query (AND or OR) + -_Default:_ `OR` - -|`df` -|`string` - The field to use as default where no field prefix is given in the query string - -|`lenient` -|`boolean` - Specify whether format-based query failures (such as providing text to a numeric field) should be ignored - -|`terminate_after` or `terminateAfter` -|`number` - The maximum count for each shard, upon reaching which the query execution will terminate early - -|`body` -|`object` - A query to restrict the results specified with the Query DSL (optional) - -|=== - -[discrete] -=== create - -[source,ts] ----- -client.create({ - id: string, - index: string, - type: string, - wait_for_active_shards: string, - refresh: 'true' | 'false' | 'wait_for', - routing: string, - timeout: string, - version: number, - version_type: 'internal' | 'external' | 'external_gte', - pipeline: string, - body: object -}) ----- -link:{ref}/docs-index_.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - Document ID - -|`index` -|`string` - The name of the index - -|`type` -|`string` - The type of the document + - -WARNING: This parameter has been deprecated. - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Sets the number of shard copies that must be active before proceeding with the index operation. Defaults to 1, meaning the primary shard only. Set to `all` for all shard copies, otherwise set to any non-negative value less than or equal to the total number of copies for the shard (number of replicas + 1) - -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` (the default) then do nothing with refreshes. - -|`routing` -|`string` - Specific routing value - -|`timeout` -|`string` - Explicit operation timeout - -|`version` -|`number` - Explicit version number for concurrency control - -|`version_type` or `versionType` -|`'internal' \| 'external' \| 'external_gte'` - Specific version type - -|`pipeline` -|`string` - The pipeline id to preprocess incoming documents with - -|`body` -|`object` - The document - -|=== - -[discrete] -=== danglingIndices.deleteDanglingIndex - -[source,ts] ----- -client.danglingIndices.deleteDanglingIndex({ - index_uuid: string, - accept_data_loss: boolean, - timeout: string, - master_timeout: string -}) ----- -link:{ref}/modules-gateway-dangling-indices.html[Documentation] + -[cols=2*] -|=== -|`index_uuid` or `indexUuid` -|`string` - The UUID of the dangling index - -|`accept_data_loss` or `acceptDataLoss` -|`boolean` - Must be set to true in order to delete the dangling index - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|=== - -[discrete] -=== danglingIndices.importDanglingIndex - -[source,ts] ----- -client.danglingIndices.importDanglingIndex({ - index_uuid: string, - accept_data_loss: boolean, - timeout: string, - master_timeout: string -}) ----- -link:{ref}/modules-gateway-dangling-indices.html[Documentation] + -[cols=2*] -|=== -|`index_uuid` or `indexUuid` -|`string` - The UUID of the dangling index - -|`accept_data_loss` or `acceptDataLoss` -|`boolean` - Must be set to true in order to import the dangling index - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|=== - -[discrete] -=== danglingIndices.listDanglingIndices - -[source,ts] ----- -client.danglingIndices.listDanglingIndices() ----- -link:{ref}/modules-gateway-dangling-indices.html[Documentation] + - - -[discrete] -=== delete - -[source,ts] ----- -client.delete({ - id: string, - index: string, - type: string, - wait_for_active_shards: string, - refresh: 'true' | 'false' | 'wait_for', - routing: string, - timeout: string, - if_seq_no: number, - if_primary_term: number, - version: number, - version_type: 'internal' | 'external' | 'external_gte' -}) ----- -link:{ref}/docs-delete.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The document ID - -|`index` -|`string` - The name of the index - -|`type` -|`string` - The type of the document + - -WARNING: This parameter has been deprecated. - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Sets the number of shard copies that must be active before proceeding with the delete operation. Defaults to 1, meaning the primary shard only. Set to `all` for all shard copies, otherwise set to any non-negative value less than or equal to the total number of copies for the shard (number of replicas + 1) - -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` (the default) then do nothing with refreshes. - -|`routing` -|`string` - Specific routing value - -|`timeout` -|`string` - Explicit operation timeout - -|`if_seq_no` or `ifSeqNo` -|`number` - only perform the delete operation if the last operation that has changed the document has the specified sequence number - -|`if_primary_term` or `ifPrimaryTerm` -|`number` - only perform the delete operation if the last operation that has changed the document has the specified primary term - -|`version` -|`number` - Explicit version number for concurrency control - -|`version_type` or `versionType` -|`'internal' \| 'external' \| 'external_gte'` - Specific version type - -|=== - -[discrete] -=== deleteByQuery - -[source,ts] ----- -client.deleteByQuery({ - index: string | string[], - analyzer: string, - analyze_wildcard: boolean, - default_operator: 'AND' | 'OR', - df: string, - from: number, - ignore_unavailable: boolean, - allow_no_indices: boolean, - conflicts: 'abort' | 'proceed', - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - lenient: boolean, - preference: string, - q: string, - routing: string | string[], - scroll: string, - search_type: 'query_then_fetch' | 'dfs_query_then_fetch', - search_timeout: string, - max_docs: number, - sort: string | string[], - _source: string | string[], - _source_excludes: string | string[], - _source_includes: string | string[], - terminate_after: number, - stats: string | string[], - version: boolean, - request_cache: boolean, - refresh: boolean, - timeout: string, - wait_for_active_shards: string, - scroll_size: number, - wait_for_completion: boolean, - requests_per_second: number, - slices: number|string, - body: object -}) ----- -link:{ref}/docs-delete-by-query.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to search; use `_all` or empty string to perform the operation on all indices - -|`analyzer` -|`string` - The analyzer to use for the query string - -|`analyze_wildcard` or `analyzeWildcard` -|`boolean` - Specify whether wildcard and prefix queries should be analyzed (default: false) - -|`default_operator` or `defaultOperator` -|`'AND' \| 'OR'` - The default operator for query string query (AND or OR) + -_Default:_ `OR` - -|`df` -|`string` - The field to use as default where no field prefix is given in the query string - -|`from` -|`number` - Starting offset (default: 0) - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`conflicts` -|`'abort' \| 'proceed'` - What to do when the delete by query hits version conflicts? + -_Default:_ `abort` - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`lenient` -|`boolean` - Specify whether format-based query failures (such as providing text to a numeric field) should be ignored - -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) - -|`q` -|`string` - Query in the Lucene query string syntax - -|`routing` -|`string \| string[]` - A comma-separated list of specific routing values - -|`scroll` -|`string` - Specify how long a consistent view of the index should be maintained for scrolled search - -|`search_type` or `searchType` -|`'query_then_fetch' \| 'dfs_query_then_fetch'` - Search operation type - -|`search_timeout` or `searchTimeout` -|`string` - Explicit timeout for each search request. Defaults to no timeout. - -|`max_docs` or `maxDocs` -|`number` - Maximum number of documents to process (default: all documents) - -|`sort` -|`string \| string[]` - A comma-separated list of : pairs - -|`_source` -|`string \| string[]` - True or false to return the _source field or not, or a list of fields to return - -|`_source_excludes` or `_sourceExcludes` -|`string \| string[]` - A list of fields to exclude from the returned _source field - -|`_source_includes` or `_sourceIncludes` -|`string \| string[]` - A list of fields to extract and return from the _source field - -|`terminate_after` or `terminateAfter` -|`number` - The maximum number of documents to collect for each shard, upon reaching which the query execution will terminate early. - -|`stats` -|`string \| string[]` - Specific 'tag' of the request for logging and statistical purposes - -|`version` -|`boolean` - Specify whether to return document version as part of a hit - -|`request_cache` or `requestCache` -|`boolean` - Specify if request cache should be used for this request or not, defaults to index level setting - -|`refresh` -|`boolean` - Should the affected indexes be refreshed? - -|`timeout` -|`string` - Time each individual bulk request should wait for shards that are unavailable. + -_Default:_ `1m` - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Sets the number of shard copies that must be active before proceeding with the delete by query operation. Defaults to 1, meaning the primary shard only. Set to `all` for all shard copies, otherwise set to any non-negative value less than or equal to the total number of copies for the shard (number of replicas + 1) - -|`scroll_size` or `scrollSize` -|`number` - Size on the scroll request powering the delete by query + -_Default:_ `100` - -|`wait_for_completion` or `waitForCompletion` -|`boolean` - Should the request should block until the delete by query is complete. + -_Default:_ `true` - -|`requests_per_second` or `requestsPerSecond` -|`number` - The throttle for this request in sub-requests per second. -1 means no throttle. - -|`slices` -|`number\|string` - The number of slices this task should be divided into. Defaults to 1, meaning the task isn't sliced into subtasks. Can be set to `auto`. + -_Default:_ `1` - -|`body` -|`object` - The search definition using the Query DSL - -|=== - -[discrete] -=== deleteByQueryRethrottle - -[source,ts] ----- -client.deleteByQueryRethrottle({ - task_id: string, - requests_per_second: number -}) ----- -link:{ref}/docs-delete-by-query.html[Documentation] + -[cols=2*] -|=== -|`task_id` or `taskId` -|`string` - The task id to rethrottle - -|`requests_per_second` or `requestsPerSecond` -|`number` - The throttle to set on this request in floating sub-requests per second. -1 means set no throttle. - -|=== - -[discrete] -=== deleteScript - -[source,ts] ----- -client.deleteScript({ - id: string, - timeout: string, - master_timeout: string -}) ----- -link:{ref}/modules-scripting.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - Script ID - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|=== - -[discrete] -=== enrich.deletePolicy - -[source,ts] ----- -client.enrich.deletePolicy({ - name: string -}) ----- -link:{ref}/delete-enrich-policy-api.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the enrich policy - -|=== - -[discrete] -=== enrich.executePolicy - -[source,ts] ----- -client.enrich.executePolicy({ - name: string, - wait_for_completion: boolean -}) ----- -link:{ref}/execute-enrich-policy-api.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the enrich policy - -|`wait_for_completion` or `waitForCompletion` -|`boolean` - Should the request should block until the execution is complete. + -_Default:_ `true` - -|=== - -[discrete] -=== enrich.getPolicy - -[source,ts] ----- -client.enrich.getPolicy({ - name: string | string[] -}) ----- -link:{ref}/get-enrich-policy-api.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - A comma-separated list of enrich policy names - -|=== - -[discrete] -=== enrich.putPolicy - -[source,ts] ----- -client.enrich.putPolicy({ - name: string, - body: object -}) ----- -link:{ref}/put-enrich-policy-api.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the enrich policy - -|`body` -|`object` - The enrich policy to register - -|=== - -[discrete] -=== enrich.stats - -[source,ts] ----- -client.enrich.stats() ----- -link:{ref}/enrich-stats-api.html[Documentation] + - - -[discrete] -=== eql.delete - -[source,ts] ----- -client.eql.delete({ - id: string -}) ----- -link:{ref}/eql-search-api.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The async search ID - -|=== - -[discrete] -=== eql.get - -[source,ts] ----- -client.eql.get({ - id: string, - wait_for_completion_timeout: string, - keep_alive: string -}) ----- -link:{ref}/eql-search-api.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The async search ID - -|`wait_for_completion_timeout` or `waitForCompletionTimeout` -|`string` - Specify the time that the request should block waiting for the final response - -|`keep_alive` or `keepAlive` -|`string` - Update the time interval in which the results (partial or final) for this search will be available + -_Default:_ `5d` - -|=== - -[discrete] -=== eql.getStatus - -[source,ts] ----- -client.eql.getStatus({ - id: string -}) ----- -link:{ref}/eql-search-api.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The async search ID - -|=== - -[discrete] -=== eql.search - -[source,ts] ----- -client.eql.search({ - index: string, - wait_for_completion_timeout: string, - keep_on_completion: boolean, - keep_alive: string, - body: object -}) ----- -link:{ref}/eql-search-api.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the index to scope the operation - -|`wait_for_completion_timeout` or `waitForCompletionTimeout` -|`string` - Specify the time that the request should block waiting for the final response - -|`keep_on_completion` or `keepOnCompletion` -|`boolean` - Control whether the response should be stored in the cluster if it completed within the provided [wait_for_completion] time (default: false) - -|`keep_alive` or `keepAlive` -|`string` - Update the time interval in which the results (partial or final) for this search will be available + -_Default:_ `5d` - -|`body` -|`object` - Eql request body. Use the `query` to limit the query scope. - -|=== - -[discrete] -=== exists - -[source,ts] ----- -client.exists({ - id: string, - index: string, - stored_fields: string | string[], - preference: string, - realtime: boolean, - refresh: boolean, - routing: string, - _source: string | string[], - _source_excludes: string | string[], - _source_includes: string | string[], - version: number, - version_type: 'internal' | 'external' | 'external_gte' -}) ----- -link:{ref}/docs-get.html[Documentation] + -{jsclient}/exists_examples.html[Code Example] + -[cols=2*] -|=== -|`id` -|`string` - The document ID - -|`index` -|`string` - The name of the index - -|`stored_fields` or `storedFields` -|`string \| string[]` - A comma-separated list of stored fields to return in the response - -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) - -|`realtime` -|`boolean` - Specify whether to perform the operation in realtime or search mode - -|`refresh` -|`boolean` - Refresh the shard containing the document before performing the operation - -|`routing` -|`string` - Specific routing value - -|`_source` -|`string \| string[]` - True or false to return the _source field or not, or a list of fields to return - -|`_source_excludes` or `_sourceExcludes` -|`string \| string[]` - A list of fields to exclude from the returned _source field - -|`_source_includes` or `_sourceIncludes` -|`string \| string[]` - A list of fields to extract and return from the _source field - -|`version` -|`number` - Explicit version number for concurrency control - -|`version_type` or `versionType` -|`'internal' \| 'external' \| 'external_gte'` - Specific version type - -|=== - -[discrete] -=== existsSource - -[source,ts] ----- -client.existsSource({ - id: string, - index: string, - type: string, - preference: string, - realtime: boolean, - refresh: boolean, - routing: string, - _source: string | string[], - _source_excludes: string | string[], - _source_includes: string | string[], - version: number, - version_type: 'internal' | 'external' | 'external_gte' -}) ----- -link:{ref}/docs-get.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The document ID - -|`index` -|`string` - The name of the index - -|`type` -|`string` - The type of the document; deprecated and optional starting with 7.0 + - -WARNING: This parameter has been deprecated. - -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) - -|`realtime` -|`boolean` - Specify whether to perform the operation in realtime or search mode - -|`refresh` -|`boolean` - Refresh the shard containing the document before performing the operation - -|`routing` -|`string` - Specific routing value - -|`_source` -|`string \| string[]` - True or false to return the _source field or not, or a list of fields to return - -|`_source_excludes` or `_sourceExcludes` -|`string \| string[]` - A list of fields to exclude from the returned _source field - -|`_source_includes` or `_sourceIncludes` -|`string \| string[]` - A list of fields to extract and return from the _source field - -|`version` -|`number` - Explicit version number for concurrency control - -|`version_type` or `versionType` -|`'internal' \| 'external' \| 'external_gte'` - Specific version type - -|=== - -[discrete] -=== explain - -[source,ts] ----- -client.explain({ - id: string, - index: string, - analyze_wildcard: boolean, - analyzer: string, - default_operator: 'AND' | 'OR', - df: string, - stored_fields: string | string[], - lenient: boolean, - preference: string, - q: string, - routing: string, - _source: string | string[], - _source_excludes: string | string[], - _source_includes: string | string[], - body: object -}) ----- -link:{ref}/search-explain.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The document ID - -|`index` -|`string` - The name of the index - -|`analyze_wildcard` or `analyzeWildcard` -|`boolean` - Specify whether wildcards and prefix queries in the query string query should be analyzed (default: false) - -|`analyzer` -|`string` - The analyzer for the query string query - -|`default_operator` or `defaultOperator` -|`'AND' \| 'OR'` - The default operator for query string query (AND or OR) + -_Default:_ `OR` - -|`df` -|`string` - The default field for query string query (default: _all) - -|`stored_fields` or `storedFields` -|`string \| string[]` - A comma-separated list of stored fields to return in the response - -|`lenient` -|`boolean` - Specify whether format-based query failures (such as providing text to a numeric field) should be ignored - -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) - -|`q` -|`string` - Query in the Lucene query string syntax - -|`routing` -|`string` - Specific routing value - -|`_source` -|`string \| string[]` - True or false to return the _source field or not, or a list of fields to return - -|`_source_excludes` or `_sourceExcludes` -|`string \| string[]` - A list of fields to exclude from the returned _source field - -|`_source_includes` or `_sourceIncludes` -|`string \| string[]` - A list of fields to extract and return from the _source field - -|`body` -|`object` - The query definition using the Query DSL - -|=== - -[discrete] -=== features.getFeatures - -[source,ts] ----- -client.features.getFeatures({ - master_timeout: string -}) ----- -link:{ref}/get-features-api.html[Documentation] + -[cols=2*] -|=== -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|=== - -[discrete] -=== features.resetFeatures -*Stability:* experimental -[source,ts] ----- -client.features.resetFeatures() ----- -link:{ref}/modules-snapshots.html[Documentation] + - - -[discrete] -=== fieldCaps - -[source,ts] ----- -client.fieldCaps({ - index: string | string[], - fields: string | string[], - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - include_unmapped: boolean, - body: object -}) ----- -link:{ref}/search-field-caps.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices - -|`fields` -|`string \| string[]` - A comma-separated list of field names - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`include_unmapped` or `includeUnmapped` -|`boolean` - Indicates whether unmapped fields should be included in the response. - -|`body` -|`object` - An index filter specified with the Query DSL - -|=== - -[discrete] -=== fleet.globalCheckpoints -*Stability:* experimental -[source,ts] ----- -client.fleet.globalCheckpoints({ - index: string, - wait_for_advance: boolean, - wait_for_index: boolean, - checkpoints: string | string[], - timeout: string -}) ----- -[cols=2*] -|=== -|`index` -|`string` - The name of the index. - -|`wait_for_advance` or `waitForAdvance` -|`boolean` - Whether to wait for the global checkpoint to advance past the specified current checkpoints + -_Default:_ `false` - -|`wait_for_index` or `waitForIndex` -|`boolean` - Whether to wait for the target index to exist and all primary shards be active + -_Default:_ `false` - -|`checkpoints` -|`string \| string[]` - Comma separated list of checkpoints - -|`timeout` -|`string` - Timeout to wait for global checkpoint to advance + -_Default:_ `30s` - -|=== - -[discrete] -=== get - -[source,ts] ----- -client.get({ - id: string, - index: string, - stored_fields: string | string[], - preference: string, - realtime: boolean, - refresh: boolean, - routing: string, - _source: string | string[], - _source_excludes: string | string[], - _source_includes: string | string[], - version: number, - version_type: 'internal' | 'external' | 'external_gte' -}) ----- -link:{ref}/docs-get.html[Documentation] + -{jsclient}/get_examples.html[Code Example] + -[cols=2*] -|=== -|`id` -|`string` - The document ID - -|`index` -|`string` - The name of the index - -|`stored_fields` or `storedFields` -|`string \| string[]` - A comma-separated list of stored fields to return in the response - -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) - -|`realtime` -|`boolean` - Specify whether to perform the operation in realtime or search mode - -|`refresh` -|`boolean` - Refresh the shard containing the document before performing the operation - -|`routing` -|`string` - Specific routing value - -|`_source` -|`string \| string[]` - True or false to return the _source field or not, or a list of fields to return - -|`_source_excludes` or `_sourceExcludes` -|`string \| string[]` - A list of fields to exclude from the returned _source field - -|`_source_includes` or `_sourceIncludes` -|`string \| string[]` - A list of fields to extract and return from the _source field - -|`version` -|`number` - Explicit version number for concurrency control - -|`version_type` or `versionType` -|`'internal' \| 'external' \| 'external_gte'` - Specific version type - -|=== - -[discrete] -=== getScript - -[source,ts] ----- -client.getScript({ - id: string, - master_timeout: string -}) ----- -link:{ref}/modules-scripting.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - Script ID - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|=== - -[discrete] -=== getScriptContext -*Stability:* experimental -[source,ts] ----- -client.getScriptContext() ----- -link:https://www.elastic.co/guide/en/elasticsearch/painless/master/painless-contexts.html[Documentation] + - - -[discrete] -=== getScriptLanguages -*Stability:* experimental -[source,ts] ----- -client.getScriptLanguages() ----- -link:{ref}/modules-scripting.html[Documentation] + - - -[discrete] -=== getSource - -[source,ts] ----- -client.getSource({ - id: string, - index: string, - preference: string, - realtime: boolean, - refresh: boolean, - routing: string, - _source: string | string[], - _source_excludes: string | string[], - _source_includes: string | string[], - version: number, - version_type: 'internal' | 'external' | 'external_gte' -}) ----- -link:{ref}/docs-get.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The document ID - -|`index` -|`string` - The name of the index - -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) - -|`realtime` -|`boolean` - Specify whether to perform the operation in realtime or search mode - -|`refresh` -|`boolean` - Refresh the shard containing the document before performing the operation - -|`routing` -|`string` - Specific routing value - -|`_source` -|`string \| string[]` - True or false to return the _source field or not, or a list of fields to return - -|`_source_excludes` or `_sourceExcludes` -|`string \| string[]` - A list of fields to exclude from the returned _source field - -|`_source_includes` or `_sourceIncludes` -|`string \| string[]` - A list of fields to extract and return from the _source field - -|`version` -|`number` - Explicit version number for concurrency control - -|`version_type` or `versionType` -|`'internal' \| 'external' \| 'external_gte'` - Specific version type - -|=== - -[discrete] -=== graph.explore - -[source,ts] ----- -client.graph.explore({ - index: string | string[], - routing: string, - timeout: string, - body: object -}) ----- -link:{ref}/graph-explore-api.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to search; use `_all` or empty string to perform the operation on all indices - -|`routing` -|`string` - Specific routing value - -|`timeout` -|`string` - Explicit operation timeout - -|`body` -|`object` - Graph Query DSL - -|=== - -[discrete] -=== ilm.deleteLifecycle - -[source,ts] ----- -client.ilm.deleteLifecycle({ - policy: string -}) ----- -link:{ref}/ilm-delete-lifecycle.html[Documentation] + -[cols=2*] -|=== -|`policy` -|`string` - The name of the index lifecycle policy - -|=== - -[discrete] -=== ilm.explainLifecycle - -[source,ts] ----- -client.ilm.explainLifecycle({ - index: string, - only_managed: boolean, - only_errors: boolean -}) ----- -link:{ref}/ilm-explain-lifecycle.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the index to explain - -|`only_managed` or `onlyManaged` -|`boolean` - filters the indices included in the response to ones managed by ILM - -|`only_errors` or `onlyErrors` -|`boolean` - filters the indices included in the response to ones in an ILM error state, implies only_managed - -|=== - -[discrete] -=== ilm.getLifecycle - -[source,ts] ----- -client.ilm.getLifecycle({ - policy: string -}) ----- -link:{ref}/ilm-get-lifecycle.html[Documentation] + -[cols=2*] -|=== -|`policy` -|`string` - The name of the index lifecycle policy - -|=== - -[discrete] -=== ilm.getStatus - -[source,ts] ----- -client.ilm.getStatus() ----- -link:{ref}/ilm-get-status.html[Documentation] + - - -[discrete] -=== ilm.migrateToDataTiers - -[source,ts] ----- -client.ilm.migrateToDataTiers({ - dry_run: boolean, - body: object -}) ----- -link:{ref}/ilm-migrate-to-data-tiers.html[Documentation] + -[cols=2*] -|=== -|`dry_run` or `dryRun` -|`boolean` - If set to true it will simulate the migration, providing a way to retrieve the ILM policies and indices that need to be migrated. The default is false - -|`body` -|`object` - Optionally specify a legacy index template name to delete and optionally specify a node attribute name used for index shard routing (defaults to "data") - -|=== - -[discrete] -=== ilm.moveToStep - -[source,ts] ----- -client.ilm.moveToStep({ - index: string, - body: object -}) ----- -link:{ref}/ilm-move-to-step.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the index whose lifecycle step is to change - -|`body` -|`object` - The new lifecycle step to move to - -|=== - -[discrete] -=== ilm.putLifecycle - -[source,ts] ----- -client.ilm.putLifecycle({ - policy: string, - body: object -}) ----- -link:{ref}/ilm-put-lifecycle.html[Documentation] + -[cols=2*] -|=== -|`policy` -|`string` - The name of the index lifecycle policy - -|`body` -|`object` - The lifecycle policy definition to register - -|=== - -[discrete] -=== ilm.removePolicy - -[source,ts] ----- -client.ilm.removePolicy({ - index: string -}) ----- -link:{ref}/ilm-remove-policy.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the index to remove policy on - -|=== - -[discrete] -=== ilm.retry - -[source,ts] ----- -client.ilm.retry({ - index: string -}) ----- -link:{ref}/ilm-retry-policy.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the indices (comma-separated) whose failed lifecycle step is to be retry - -|=== - -[discrete] -=== ilm.start - -[source,ts] ----- -client.ilm.start() ----- -link:{ref}/ilm-start.html[Documentation] + - - -[discrete] -=== ilm.stop - -[source,ts] ----- -client.ilm.stop() ----- -link:{ref}/ilm-stop.html[Documentation] + - - -[discrete] -=== index - -[source,ts] ----- -client.index({ - id: string, - index: string, - wait_for_active_shards: string, - op_type: 'index' | 'create', - refresh: 'true' | 'false' | 'wait_for', - routing: string, - timeout: string, - version: number, - version_type: 'internal' | 'external' | 'external_gte', - if_seq_no: number, - if_primary_term: number, - pipeline: string, - require_alias: boolean, - body: object -}) ----- -link:{ref}/docs-index_.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - Document ID - -|`index` -|`string` - The name of the index - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Sets the number of shard copies that must be active before proceeding with the index operation. Defaults to 1, meaning the primary shard only. Set to `all` for all shard copies, otherwise set to any non-negative value less than or equal to the total number of copies for the shard (number of replicas + 1) - -|`op_type` or `opType` -|`'index' \| 'create'` - Explicit operation type. Defaults to `index` for requests with an explicit document ID, and to `create`for requests without an explicit document ID - -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` (the default) then do nothing with refreshes. - -|`routing` -|`string` - Specific routing value - -|`timeout` -|`string` - Explicit operation timeout - -|`version` -|`number` - Explicit version number for concurrency control - -|`version_type` or `versionType` -|`'internal' \| 'external' \| 'external_gte'` - Specific version type - -|`if_seq_no` or `ifSeqNo` -|`number` - only perform the index operation if the last operation that has changed the document has the specified sequence number - -|`if_primary_term` or `ifPrimaryTerm` -|`number` - only perform the index operation if the last operation that has changed the document has the specified primary term - -|`pipeline` -|`string` - The pipeline id to preprocess incoming documents with - -|`require_alias` or `requireAlias` -|`boolean` - When true, requires destination to be an alias. Default is false - -|`body` -|`object` - The document - -|=== - -[discrete] -=== indices.addBlock - -[source,ts] ----- -client.indices.addBlock({ - index: string | string[], - block: string, - timeout: string, - master_timeout: string, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) ----- -link:{ref}/index-modules-blocks.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma separated list of indices to add a block to - -|`block` -|`string` - The block to add (one of read, write, read_only or metadata) - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|=== - -[discrete] -=== indices.analyze - -[source,ts] ----- -client.indices.analyze({ - index: string, - body: object -}) ----- -link:{ref}/indices-analyze.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the index to scope the operation - -|`body` -|`object` - Define analyzer/tokenizer parameters and the text on which the analysis should be performed - -|=== - -[discrete] -=== indices.clearCache - -[source,ts] ----- -client.indices.clearCache({ - index: string | string[], - fielddata: boolean, - fields: string | string[], - query: boolean, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - request: boolean -}) ----- -link:{ref}/indices-clearcache.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index name to limit the operation - -|`fielddata` -|`boolean` - Clear field data - -|`fields` -|`string \| string[]` - A comma-separated list of fields to clear when using the `fielddata` parameter (default: all) - -|`query` -|`boolean` - Clear query caches - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`request` -|`boolean` - Clear request cache - -|=== - -[discrete] -=== indices.clone - -[source,ts] ----- -client.indices.clone({ - index: string, - target: string, - timeout: string, - master_timeout: string, - wait_for_active_shards: string, - body: object -}) ----- -link:{ref}/indices-clone-index.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the source index to clone - -|`target` -|`string` - The name of the target index to clone into - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Set the number of active shards to wait for on the cloned index before the operation returns. - -|`body` -|`object` - The configuration for the target index (`settings` and `aliases`) - -|=== - -[discrete] -=== indices.close - -[source,ts] ----- -client.indices.close({ - index: string | string[], - timeout: string, - master_timeout: string, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - wait_for_active_shards: string -}) ----- -link:{ref}/indices-open-close.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma separated list of indices to close - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Sets the number of active shards to wait for before the operation returns. - -|=== - -[discrete] -=== indices.create - -[source,ts] ----- -client.indices.create({ - index: string, - wait_for_active_shards: string, - timeout: string, - master_timeout: string, - body: object -}) ----- -link:{ref}/indices-create-index.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the index - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Set the number of active shards to wait for before the operation returns. - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`body` -|`object` - The configuration for the index (`settings` and `mappings`) - -|=== - -[discrete] -=== indices.createDataStream - -[source,ts] ----- -client.indices.createDataStream({ - name: string -}) ----- -link:{ref}/data-streams.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the data stream - -|=== - -[discrete] -=== indices.dataStreamsStats - -[source,ts] ----- -client.indices.dataStreamsStats({ - name: string | string[] -}) ----- -link:{ref}/data-streams.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - A comma-separated list of data stream names; use `_all` or empty string to perform the operation on all data streams - -|=== - -[discrete] -=== indices.delete - -[source,ts] ----- -client.indices.delete({ - index: string | string[], - timeout: string, - master_timeout: string, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) ----- -link:{ref}/indices-delete-index.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of indices to delete; use `_all` or `*` string to delete all indices - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Ignore unavailable indexes (default: false) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Ignore if a wildcard expression resolves to no concrete indices (default: false) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether wildcard expressions should get expanded to open or closed indices (default: open) + -_Default:_ `open` - -|=== - -[discrete] -=== indices.deleteAlias - -[source,ts] ----- -client.indices.deleteAlias({ - index: string | string[], - name: string | string[], - timeout: string, - master_timeout: string -}) ----- -link:{ref}/indices-aliases.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names (supports wildcards); use `_all` for all indices - -|`name` -|`string \| string[]` - A comma-separated list of aliases to delete (supports wildcards); use `_all` to delete all aliases for the specified indices. - -|`timeout` -|`string` - Explicit timestamp for the document - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|=== - -[discrete] -=== indices.deleteDataStream - -[source,ts] ----- -client.indices.deleteDataStream({ - name: string | string[], - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) ----- -link:{ref}/data-streams.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - A comma-separated list of data streams to delete; use `*` to delete all data streams - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether wildcard expressions should get expanded to open or closed indices (default: open) + -_Default:_ `open` - -|=== - -[discrete] -=== indices.deleteIndexTemplate - -[source,ts] ----- -client.indices.deleteIndexTemplate({ - name: string, - timeout: string, - master_timeout: string -}) ----- -link:{ref}/indices-templates.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the template - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|=== - -[discrete] -=== indices.deleteTemplate - -[source,ts] ----- -client.indices.deleteTemplate({ - name: string, - timeout: string, - master_timeout: string -}) ----- -link:{ref}/indices-templates.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the template - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|=== - -[discrete] -=== indices.diskUsage -*Stability:* experimental -[source,ts] ----- -client.indices.diskUsage({ - index: string, - run_expensive_tasks: boolean, - flush: boolean, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) ----- -link:{ref}/indices-disk-usage.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - Comma-separated list of indices or data streams to analyze the disk usage - -|`run_expensive_tasks` or `runExpensiveTasks` -|`boolean` - Must be set to [true] in order for the task to be performed. Defaults to false. - -|`flush` -|`boolean` - Whether flush or not before analyzing the index disk usage. Defaults to true - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|=== - -[discrete] -=== indices.exists - -[source,ts] ----- -client.indices.exists({ - index: string | string[], - local: boolean, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - flat_settings: boolean, - include_defaults: boolean -}) ----- -link:{ref}/indices-exists.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Ignore unavailable indexes (default: false) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Ignore if a wildcard expression resolves to no concrete indices (default: false) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether wildcard expressions should get expanded to open or closed indices (default: open) + -_Default:_ `open` - -|`flat_settings` or `flatSettings` -|`boolean` - Return settings in flat format (default: false) - -|`include_defaults` or `includeDefaults` -|`boolean` - Whether to return all default setting for each of the indices. - -|=== - -[discrete] -=== indices.existsAlias - -[source,ts] ----- -client.indices.existsAlias({ - name: string | string[], - index: string | string[], - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - local: boolean -}) ----- -link:{ref}/indices-aliases.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - A comma-separated list of alias names to return - -|`index` -|`string \| string[]` - A comma-separated list of index names to filter aliases - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `all` - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|=== - -[discrete] -=== indices.existsIndexTemplate - -[source,ts] ----- -client.indices.existsIndexTemplate({ - name: string, - flat_settings: boolean, - master_timeout: string, - local: boolean -}) ----- -link:{ref}/indices-templates.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the template - -|`flat_settings` or `flatSettings` -|`boolean` - Return settings in flat format (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|=== - -[discrete] -=== indices.existsTemplate - -[source,ts] ----- -client.indices.existsTemplate({ - name: string | string[], - flat_settings: boolean, - master_timeout: string, - local: boolean -}) ----- -link:{ref}/indices-templates.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - The comma separated names of the index templates - -|`flat_settings` or `flatSettings` -|`boolean` - Return settings in flat format (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|=== - -[discrete] -=== indices.existsType - -[source,ts] ----- -client.indices.existsType({ - index: string | string[], - type: string | string[], - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - local: boolean -}) ----- -link:{ref}/indices-types-exists.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names; use `_all` to check the types across all indices - -|`type` -|`string \| string[]` - A comma-separated list of document types to check - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|=== - -[discrete] -=== indices.fieldUsageStats -*Stability:* experimental -[source,ts] ----- -client.indices.fieldUsageStats({ - index: string, - fields: string | string[], - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) ----- -link:{ref}/field-usage-stats.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices - -|`fields` -|`string \| string[]` - A comma-separated list of fields to include in the stats if only a subset of fields should be returned (supports wildcards) - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|=== - -[discrete] -=== indices.flush - -[source,ts] ----- -client.indices.flush({ - index: string | string[], - force: boolean, - wait_if_ongoing: boolean, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) ----- -link:{ref}/indices-flush.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names; use `_all` or empty string for all indices - -|`force` -|`boolean` - Whether a flush should be forced even if it is not necessarily needed ie. if no changes will be committed to the index. This is useful if transaction log IDs should be incremented even if no uncommitted changes are present. (This setting can be considered as internal) - -|`wait_if_ongoing` or `waitIfOngoing` -|`boolean` - If set to true the flush operation will block until the flush can be executed if another flush operation is already executing. The default is true. If set to false the flush will be skipped iff if another flush operation is already running. - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|=== - -[discrete] -=== indices.forcemerge - -[source,ts] ----- -client.indices.forcemerge({ - index: string | string[], - flush: boolean, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - max_num_segments: number, - only_expunge_deletes: boolean -}) ----- -link:{ref}/indices-forcemerge.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices - -|`flush` -|`boolean` - Specify whether the index should be flushed after performing the operation (default: true) - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`max_num_segments` or `maxNumSegments` -|`number` - The number of segments the index should be merged into (default: dynamic) - -|`only_expunge_deletes` or `onlyExpungeDeletes` -|`boolean` - Specify whether the operation should only expunge deleted documents - -|=== - -[discrete] -=== indices.freeze - -[source,ts] ----- -client.indices.freeze({ - index: string, - timeout: string, - master_timeout: string, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - wait_for_active_shards: string -}) ----- -link:{ref}/freeze-index-api.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the index to freeze - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `closed` - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Sets the number of active shards to wait for before the operation returns. - -|=== - -[discrete] -=== indices.get - -[source,ts] ----- -client.indices.get({ - index: string | string[], - local: boolean, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - flat_settings: boolean, - include_defaults: boolean, - master_timeout: string -}) ----- -link:{ref}/indices-get-index.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Ignore unavailable indexes (default: false) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Ignore if a wildcard expression resolves to no concrete indices (default: false) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether wildcard expressions should get expanded to open or closed indices (default: open) + -_Default:_ `open` - -|`flat_settings` or `flatSettings` -|`boolean` - Return settings in flat format (default: false) - -|`include_defaults` or `includeDefaults` -|`boolean` - Whether to return all default setting for each of the indices. - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|=== - -[discrete] -=== indices.getAlias - -[source,ts] ----- -client.indices.getAlias({ - name: string | string[], - index: string | string[], - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - local: boolean -}) ----- -link:{ref}/indices-aliases.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - A comma-separated list of alias names to return - -|`index` -|`string \| string[]` - A comma-separated list of index names to filter aliases - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `all` - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|=== - -[discrete] -=== indices.getDataStream - -[source,ts] ----- -client.indices.getDataStream({ - name: string | string[], - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) ----- -link:{ref}/data-streams.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - A comma-separated list of data streams to get; use `*` to get all data streams - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether wildcard expressions should get expanded to open or closed indices (default: open) + -_Default:_ `open` - -|=== - -[discrete] -=== indices.getFieldMapping - -[source,ts] ----- -client.indices.getFieldMapping({ - fields: string | string[], - index: string | string[], - include_defaults: boolean, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - local: boolean -}) ----- -link:{ref}/indices-get-field-mapping.html[Documentation] + -[cols=2*] -|=== -|`fields` -|`string \| string[]` - A comma-separated list of fields - -|`index` -|`string \| string[]` - A comma-separated list of index names - -|`include_defaults` or `includeDefaults` -|`boolean` - Whether the default mapping values should be returned as well - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|=== - -[discrete] -=== indices.getIndexTemplate - -[source,ts] ----- -client.indices.getIndexTemplate({ - name: string | string[], - flat_settings: boolean, - master_timeout: string, - local: boolean -}) ----- -link:{ref}/indices-templates.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - The comma separated names of the index templates - -|`flat_settings` or `flatSettings` -|`boolean` - Return settings in flat format (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|=== - -[discrete] -=== indices.getMapping - -[source,ts] ----- -client.indices.getMapping({ - index: string | string[], - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - master_timeout: string, - local: boolean -}) ----- -link:{ref}/indices-get-mapping.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) + - -WARNING: This parameter has been deprecated. - -|=== - -[discrete] -=== indices.getSettings - -[source,ts] ----- -client.indices.getSettings({ - index: string | string[], - name: string | string[], - master_timeout: string, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - flat_settings: boolean, - local: boolean, - include_defaults: boolean -}) ----- -link:{ref}/indices-get-settings.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices - -|`name` -|`string \| string[]` - The name of the settings that should be included - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `all` - -|`flat_settings` or `flatSettings` -|`boolean` - Return settings in flat format (default: false) - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`include_defaults` or `includeDefaults` -|`boolean` - Whether to return all default setting for each of the indices. - -|=== - -[discrete] -=== indices.getTemplate - -[source,ts] ----- -client.indices.getTemplate({ - name: string | string[], - flat_settings: boolean, - master_timeout: string, - local: boolean -}) ----- -link:{ref}/indices-templates.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - The comma separated names of the index templates - -|`flat_settings` or `flatSettings` -|`boolean` - Return settings in flat format (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|=== - -[discrete] -=== indices.migrateToDataStream - -[source,ts] ----- -client.indices.migrateToDataStream({ - name: string -}) ----- -link:{ref}/data-streams.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the alias to migrate - -|=== - -[discrete] -=== indices.open - -[source,ts] ----- -client.indices.open({ - index: string | string[], - timeout: string, - master_timeout: string, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - wait_for_active_shards: string -}) ----- -link:{ref}/indices-open-close.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma separated list of indices to open - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `closed` - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Sets the number of active shards to wait for before the operation returns. - -|=== - -[discrete] -=== indices.promoteDataStream - -[source,ts] ----- -client.indices.promoteDataStream({ - name: string -}) ----- -link:{ref}/data-streams.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the data stream - -|=== - -[discrete] -=== indices.putAlias - -[source,ts] ----- -client.indices.putAlias({ - index: string | string[], - name: string, - timeout: string, - master_timeout: string, - body: object -}) ----- -link:{ref}/indices-aliases.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names the alias should point to (supports wildcards); use `_all` to perform the operation on all indices. - -|`name` -|`string` - The name of the alias to be created or updated - -|`timeout` -|`string` - Explicit timestamp for the document - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`body` -|`object` - The settings for the alias, such as `routing` or `filter` - -|=== - -[discrete] -=== indices.putIndexTemplate - -[source,ts] ----- -client.indices.putIndexTemplate({ - name: string, - create: boolean, - cause: string, - master_timeout: string, - body: object -}) ----- -link:{ref}/indices-templates.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the template - -|`create` -|`boolean` - Whether the index template should only be added if new or can also replace an existing one - -|`cause` -|`string` - User defined reason for creating/updating the index template - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`body` -|`object` - The template definition - -|=== - -[discrete] -=== indices.putMapping - -[source,ts] ----- -client.indices.putMapping({ - index: string | string[], - timeout: string, - master_timeout: string, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - write_index_only: boolean, - body: object -}) ----- -link:{ref}/indices-put-mapping.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names the mapping should be added to (supports wildcards); use `_all` or omit to add the mapping on all indices. - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`write_index_only` or `writeIndexOnly` -|`boolean` - When true, applies mappings only to the write index of an alias or data stream - -|`body` -|`object` - The mapping definition - -|=== - -[discrete] -=== indices.putSettings - -[source,ts] ----- -client.indices.putSettings({ - index: string | string[], - master_timeout: string, - timeout: string, - preserve_existing: boolean, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - flat_settings: boolean, - body: object -}) ----- -link:{ref}/indices-update-settings.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`timeout` -|`string` - Explicit operation timeout - -|`preserve_existing` or `preserveExisting` -|`boolean` - Whether to update existing settings. If set to `true` existing settings on an index remain unchanged, the default is `false` - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`flat_settings` or `flatSettings` -|`boolean` - Return settings in flat format (default: false) - -|`body` -|`object` - The index settings to be updated - -|=== - -[discrete] -=== indices.putTemplate - -[source,ts] ----- -client.indices.putTemplate({ - name: string, - order: number, - create: boolean, - master_timeout: string, - body: object -}) ----- -link:{ref}/indices-templates.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the template - -|`order` -|`number` - The order for this template when merging multiple matching ones (higher numbers are merged later, overriding the lower numbers) - -|`create` -|`boolean` - Whether the index template should only be added if new or can also replace an existing one - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`body` -|`object` - The template definition - -|=== - -[discrete] -=== indices.recovery - -[source,ts] ----- -client.indices.recovery({ - index: string | string[], - detailed: boolean, - active_only: boolean -}) ----- -link:{ref}/indices-recovery.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices - -|`detailed` -|`boolean` - Whether to display detailed information about shard recovery - -|`active_only` or `activeOnly` -|`boolean` - Display only those recoveries that are currently on-going - -|=== - -[discrete] -=== indices.refresh - -[source,ts] ----- -client.indices.refresh({ - index: string | string[], - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) ----- -link:{ref}/indices-refresh.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|=== - -[discrete] -=== indices.reloadSearchAnalyzers +==== bulk +Allows to perform multiple index/update/delete operations in a single request. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-bulk.html[Endpoint documentation] [source,ts] ---- -client.indices.reloadSearchAnalyzers({ - index: string | string[], - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) +client.bulk(...) ---- -link:{ref}/indices-reload-analyzers.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to reload analyzers for -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) +==== clear_scroll +Explicitly clears the search context for a scroll. -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|=== - -[discrete] -=== indices.resolveIndex -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/master/clear-scroll-api.html[Endpoint documentation] [source,ts] ---- -client.indices.resolveIndex({ - name: string | string[], - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) +client.clearScroll(...) ---- -link:{ref}/indices-resolve-index-api.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - A comma-separated list of names or wildcard expressions - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether wildcard expressions should get expanded to open or closed indices (default: open) + -_Default:_ `open` -|=== - -[discrete] -=== indices.rollover +==== close_point_in_time +Close a point in time +https://www.elastic.co/guide/en/elasticsearch/reference/master/point-in-time-api.html[Endpoint documentation] [source,ts] ---- -client.indices.rollover({ - alias: string, - new_index: string, - timeout: string, - dry_run: boolean, - master_timeout: string, - wait_for_active_shards: string, - body: object -}) +client.closePointInTime(...) ---- -link:{ref}/indices-rollover-index.html[Documentation] + -[cols=2*] -|=== -|`alias` -|`string` - The name of the alias to rollover - -|`new_index` or `newIndex` -|`string` - The name of the rollover index - -|`timeout` -|`string` - Explicit operation timeout - -|`dry_run` or `dryRun` -|`boolean` - If set to true the rollover action will only be validated but not actually performed even if a condition matches. The default is false -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Set the number of active shards to wait for on the newly created rollover index before the operation returns. - -|`body` -|`object` - The conditions that needs to be met for executing rollover - -|=== - -[discrete] -=== indices.segments +==== count +Returns number of documents matching a query. +https://www.elastic.co/guide/en/elasticsearch/reference/master/search-count.html[Endpoint documentation] [source,ts] ---- -client.indices.segments({ - index: string | string[], - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - verbose: boolean -}) +client.count(...) ---- -link:{ref}/indices-segments.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`verbose` -|`boolean` - Includes detailed memory usage by Lucene. -|=== +==== create +Creates a new document in the index. -[discrete] -=== indices.shardStores +Returns a 409 response when a document with a same ID already exists in the index. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-index_.html[Endpoint documentation] [source,ts] ---- -client.indices.shardStores({ - index: string | string[], - status: string | string[], - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) +client.create(...) ---- -link:{ref}/indices-shards-stores.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices -|`status` -|`string \| string[]` - A comma-separated list of statuses used to filter on shards to get store information for - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|=== - -[discrete] -=== indices.shrink +==== delete +Removes a document from the index. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-delete.html[Endpoint documentation] [source,ts] ---- -client.indices.shrink({ - index: string, - target: string, - timeout: string, - master_timeout: string, - wait_for_active_shards: string, - body: object -}) +client.delete(...) ---- -link:{ref}/indices-shrink-index.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the source index to shrink - -|`target` -|`string` - The name of the target index to shrink into - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Set the number of active shards to wait for on the shrunken index before the operation returns. - -|`body` -|`object` - The configuration for the target index (`settings` and `aliases`) - -|=== - -[discrete] -=== indices.simulateIndexTemplate +==== delete_by_query +Deletes documents matching the provided query. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-delete-by-query.html[Endpoint documentation] [source,ts] ---- -client.indices.simulateIndexTemplate({ - name: string, - create: boolean, - cause: string, - master_timeout: string, - body: object -}) +client.deleteByQuery(...) ---- -link:{ref}/indices-templates.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the index (it must be a concrete index name) - -|`create` -|`boolean` - Whether the index template we optionally defined in the body should only be dry-run added if new or can also replace an existing one - -|`cause` -|`string` - User defined reason for dry-run creating the new template for simulation purposes - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`body` -|`object` - New index template definition, which will be included in the simulation, as if it already exists in the system - -|=== -[discrete] -=== indices.simulateTemplate +==== delete_by_query_rethrottle +Changes the number of requests per second for a particular Delete By Query operation. +https://www.elastic.co/guide/en/elasticsearch/reference/current/docs-delete-by-query.html[Endpoint documentation] [source,ts] ---- -client.indices.simulateTemplate({ - name: string, - create: boolean, - cause: string, - master_timeout: string, - body: object -}) +client.deleteByQueryRethrottle(...) ---- -link:{ref}/indices-templates.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - The name of the index template -|`create` -|`boolean` - Whether the index template we optionally defined in the body should only be dry-run added if new or can also replace an existing one - -|`cause` -|`string` - User defined reason for dry-run creating the new template for simulation purposes - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`body` -|`object` - New index template definition to be simulated, if no index template name is specified - -|=== - -[discrete] -=== indices.split +==== delete_script +Deletes a script. +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting.html[Endpoint documentation] [source,ts] ---- -client.indices.split({ - index: string, - target: string, - timeout: string, - master_timeout: string, - wait_for_active_shards: string, - body: object -}) +client.deleteScript(...) ---- -link:{ref}/indices-split-index.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the source index to split - -|`target` -|`string` - The name of the target index to split into - -|`timeout` -|`string` - Explicit operation timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Set the number of active shards to wait for on the shrunken index before the operation returns. - -|`body` -|`object` - The configuration for the target index (`settings` and `aliases`) - -|=== - -[discrete] -=== indices.stats +==== exists +Returns information about whether a document exists in an index. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html[Endpoint documentation] [source,ts] ---- -client.indices.stats({ - metric: string | string[], - index: string | string[], - completion_fields: string | string[], - fielddata_fields: string | string[], - fields: string | string[], - groups: string | string[], - level: 'cluster' | 'indices' | 'shards', - types: string | string[], - include_segment_file_sizes: boolean, - include_unloaded_segments: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - forbid_closed_indices: boolean -}) +client.exists(...) ---- -link:{ref}/indices-stats.html[Documentation] + -[cols=2*] -|=== -|`metric` -|`string \| string[]` - Limit the information returned the specific metrics. - -|`index` -|`string \| string[]` - A comma-separated list of index names; use `_all` or empty string to perform the operation on all indices - -|`completion_fields` or `completionFields` -|`string \| string[]` - A comma-separated list of fields for the `completion` index metric (supports wildcards) - -|`fielddata_fields` or `fielddataFields` -|`string \| string[]` - A comma-separated list of fields for the `fielddata` index metric (supports wildcards) - -|`fields` -|`string \| string[]` - A comma-separated list of fields for `fielddata` and `completion` index metric (supports wildcards) - -|`groups` -|`string \| string[]` - A comma-separated list of search groups for `search` index metric -|`level` -|`'cluster' \| 'indices' \| 'shards'` - Return stats aggregated at cluster, index or shard level + -_Default:_ `indices` - -|`types` -|`string \| string[]` - A comma-separated list of document types for the `indexing` index metric - -|`include_segment_file_sizes` or `includeSegmentFileSizes` -|`boolean` - Whether to report the aggregated disk usage of each one of the Lucene index files (only applies if segment stats are requested) - -|`include_unloaded_segments` or `includeUnloadedSegments` -|`boolean` - If set to true segment stats will include stats for segments that are not currently loaded into memory - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`forbid_closed_indices` or `forbidClosedIndices` -|`boolean` - If set to false stats will also collected from closed indices if explicitly specified or if expand_wildcards expands to closed indices + -_Default:_ `true` - -|=== - -[discrete] -=== indices.unfreeze +==== exists_source +Returns information about whether a document source exists in an index. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html[Endpoint documentation] [source,ts] ---- -client.indices.unfreeze({ - index: string, - timeout: string, - master_timeout: string, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - wait_for_active_shards: string -}) +client.existsSource(...) ---- -link:{ref}/unfreeze-index-api.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the index to unfreeze - -|`timeout` -|`string` - Explicit operation timeout -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `closed` - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Sets the number of active shards to wait for before the operation returns. - -|=== - -[discrete] -=== indices.updateAliases +==== explain +Returns information about why a specific matches (or doesn't match) a query. +https://www.elastic.co/guide/en/elasticsearch/reference/master/search-explain.html[Endpoint documentation] [source,ts] ---- -client.indices.updateAliases({ - timeout: string, - master_timeout: string, - body: object -}) +client.explain(...) ---- -link:{ref}/indices-aliases.html[Documentation] + -[cols=2*] -|=== -|`timeout` -|`string` - Request timeout - -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master - -|`body` -|`object` - The definition of `actions` to perform -|=== - -[discrete] -=== indices.validateQuery +==== field_caps +Returns the information about the capabilities of fields among multiple indices. +https://www.elastic.co/guide/en/elasticsearch/reference/master/search-field-caps.html[Endpoint documentation] [source,ts] ---- -client.indices.validateQuery({ - index: string | string[], - type: string | string[], - explain: boolean, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - q: string, - analyzer: string, - analyze_wildcard: boolean, - default_operator: 'AND' | 'OR', - df: string, - lenient: boolean, - rewrite: boolean, - all_shards: boolean, - body: object -}) +client.fieldCaps(...) ---- -link:{ref}/search-validate.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to restrict the operation; use `_all` or empty string to perform the operation on all indices - -|`type` -|`string \| string[]` - A comma-separated list of document types to restrict the operation; leave empty to perform the operation on all types + - -WARNING: This parameter has been deprecated. - -|`explain` -|`boolean` - Return detailed information about the error - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`q` -|`string` - Query in the Lucene query string syntax -|`analyzer` -|`string` - The analyzer to use for the query string - -|`analyze_wildcard` or `analyzeWildcard` -|`boolean` - Specify whether wildcard and prefix queries should be analyzed (default: false) - -|`default_operator` or `defaultOperator` -|`'AND' \| 'OR'` - The default operator for query string query (AND or OR) + -_Default:_ `OR` - -|`df` -|`string` - The field to use as default where no field prefix is given in the query string - -|`lenient` -|`boolean` - Specify whether format-based query failures (such as providing text to a numeric field) should be ignored - -|`rewrite` -|`boolean` - Provide a more detailed explanation showing the actual Lucene query that will be executed. - -|`all_shards` or `allShards` -|`boolean` - Execute validation on all shards instead of one random shard per index - -|`body` -|`object` - The query definition specified with the Query DSL - -|=== - -[discrete] -=== info +==== get +Returns a document. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html[Endpoint documentation] [source,ts] ---- -client.info() +client.get(...) ---- -link:{ref}/index.html[Documentation] + - -[discrete] -=== ingest.deletePipeline +==== get_script +Returns a script. +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting.html[Endpoint documentation] [source,ts] ---- -client.ingest.deletePipeline({ - id: string, - master_timeout: string, - timeout: string -}) +client.getScript(...) ---- -link:{ref}/delete-pipeline-api.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - Pipeline ID - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`timeout` -|`string` - Explicit operation timeout -|=== - -[discrete] -=== ingest.geoIpStats +==== get_script_context +Returns all script contexts. +https://www.elastic.co/guide/en/elasticsearch/painless/master/painless-contexts.html[Endpoint documentation] [source,ts] ---- -client.ingest.geoIpStats() +client.getScriptContext(...) ---- -link:{ref}/geoip-stats-api.html[Documentation] + - -[discrete] -=== ingest.getPipeline +==== get_script_languages +Returns available script types, languages and contexts +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting.html[Endpoint documentation] [source,ts] ---- -client.ingest.getPipeline({ - id: string, - summary: boolean, - master_timeout: string -}) +client.getScriptLanguages(...) ---- -link:{ref}/get-pipeline-api.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - Comma separated list of pipeline ids. Wildcards supported - -|`summary` -|`boolean` - Return pipelines without their definitions (default: false) - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node -|=== - -[discrete] -=== ingest.processorGrok +==== get_source +Returns the source of a document. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html[Endpoint documentation] [source,ts] ---- -client.ingest.processorGrok() +client.getSource(...) ---- -link:{ref}/grok-processor.html#grok-processor-rest-get[Documentation] + - -[discrete] -=== ingest.putPipeline +==== index +Creates or updates a document in an index. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-index_.html[Endpoint documentation] [source,ts] ---- -client.ingest.putPipeline({ - id: string, - master_timeout: string, - timeout: string, - body: object -}) +client.index(...) ---- -link:{ref}/put-pipeline-api.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - Pipeline ID - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`timeout` -|`string` - Explicit operation timeout -|`body` -|`object` - The ingest definition - -|=== - -[discrete] -=== ingest.simulate +==== info +Returns basic information about the cluster. +https://www.elastic.co/guide/en/elasticsearch/reference/current/index.html[Endpoint documentation] [source,ts] ---- -client.ingest.simulate({ - id: string, - verbose: boolean, - body: object -}) +client.info(...) ---- -link:{ref}/simulate-pipeline-api.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - Pipeline ID - -|`verbose` -|`boolean` - Verbose mode. Display data output for each processor in executed pipeline - -|`body` -|`object` - The simulate definition -|=== - -[discrete] -=== license.delete +==== knn_search +Performs a kNN search. +https://www.elastic.co/guide/en/elasticsearch/reference/master/search-search.html[Endpoint documentation] [source,ts] ---- -client.license.delete() +client.knnSearch(...) ---- -link:{ref}/delete-license.html[Documentation] + - -[discrete] -=== license.get +==== mget +Allows to get multiple documents in one request. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-multi-get.html[Endpoint documentation] [source,ts] ---- -client.license.get({ - local: boolean, - accept_enterprise: boolean -}) +client.mget(...) ---- -link:{ref}/get-license.html[Documentation] + -[cols=2*] -|=== -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|`accept_enterprise` or `acceptEnterprise` -|`boolean` - Supported for backwards compatibility with 7.x. If this param is used it must be set to true + - -WARNING: This parameter has been deprecated. -|=== - -[discrete] -=== license.getBasicStatus +==== msearch +Allows to execute several search operations in one request. +https://www.elastic.co/guide/en/elasticsearch/reference/master/search-multi-search.html[Endpoint documentation] [source,ts] ---- -client.license.getBasicStatus() +client.msearch(...) ---- -link:{ref}/get-basic-status.html[Documentation] + - -[discrete] -=== license.getTrialStatus +==== msearch_template +Allows to execute several search template operations in one request. +https://www.elastic.co/guide/en/elasticsearch/reference/current/search-multi-search.html[Endpoint documentation] [source,ts] ---- -client.license.getTrialStatus() +client.msearchTemplate(...) ---- -link:{ref}/get-trial-status.html[Documentation] + +==== mtermvectors +Returns multiple termvectors in one request. -[discrete] -=== license.post - +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-multi-termvectors.html[Endpoint documentation] [source,ts] ---- -client.license.post({ - acknowledge: boolean, - body: object -}) +client.mtermvectors(...) ---- -link:{ref}/update-license.html[Documentation] + -[cols=2*] -|=== -|`acknowledge` -|`boolean` - whether the user has acknowledged acknowledge messages (default: false) - -|`body` -|`object` - licenses to be installed -|=== - -[discrete] -=== license.postStartBasic +==== open_point_in_time +Open a point in time that can be used in subsequent searches +https://www.elastic.co/guide/en/elasticsearch/reference/master/point-in-time-api.html[Endpoint documentation] [source,ts] ---- -client.license.postStartBasic({ - acknowledge: boolean -}) +client.openPointInTime(...) ---- -link:{ref}/start-basic.html[Documentation] + -[cols=2*] -|=== -|`acknowledge` -|`boolean` - whether the user has acknowledged acknowledge messages (default: false) - -|=== -[discrete] -=== license.postStartTrial +==== ping +Returns whether the cluster is running. +https://www.elastic.co/guide/en/elasticsearch/reference/current/index.html[Endpoint documentation] [source,ts] ---- -client.license.postStartTrial({ - type: string, - acknowledge: boolean -}) +client.ping(...) ---- -link:{ref}/start-trial.html[Documentation] + -[cols=2*] -|=== -|`type` -|`string` - The type of trial license to generate (default: "trial") - -|`acknowledge` -|`boolean` - whether the user has acknowledged acknowledge messages (default: false) - -|=== -[discrete] -=== logstash.deletePipeline +==== put_script +Creates or updates a script. +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting.html[Endpoint documentation] [source,ts] ---- -client.logstash.deletePipeline({ - id: string -}) +client.putScript(...) ---- -link:{ref}/logstash-api-delete-pipeline.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the Pipeline -|=== - -[discrete] -=== logstash.getPipeline +==== rank_eval +Allows to evaluate the quality of ranked search results over a set of typical search queries +https://www.elastic.co/guide/en/elasticsearch/reference/master/search-rank-eval.html[Endpoint documentation] [source,ts] ---- -client.logstash.getPipeline({ - id: string -}) +client.rankEval(...) ---- -link:{ref}/logstash-api-get-pipeline.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - A comma-separated list of Pipeline IDs - -|=== -[discrete] -=== logstash.putPipeline +==== reindex +Allows to copy documents from one index to another, optionally filtering the source +documents by a query, changing the destination index settings, or fetching the +documents from a remote cluster. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-reindex.html[Endpoint documentation] [source,ts] ---- -client.logstash.putPipeline({ - id: string, - body: object -}) +client.reindex(...) ---- -link:{ref}/logstash-api-put-pipeline.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the Pipeline - -|`body` -|`object` - The Pipeline to add or update - -|=== -[discrete] -=== mget +==== reindex_rethrottle +Changes the number of requests per second for a particular Reindex operation. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-reindex.html[Endpoint documentation] [source,ts] ---- -client.mget({ - index: string, - stored_fields: string | string[], - preference: string, - realtime: boolean, - refresh: boolean, - routing: string, - _source: string | string[], - _source_excludes: string | string[], - _source_includes: string | string[], - body: object -}) +client.reindexRethrottle(...) ---- -link:{ref}/docs-multi-get.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The name of the index - -|`stored_fields` or `storedFields` -|`string \| string[]` - A comma-separated list of stored fields to return in the response - -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) - -|`realtime` -|`boolean` - Specify whether to perform the operation in realtime or search mode - -|`refresh` -|`boolean` - Refresh the shard containing the document before performing the operation - -|`routing` -|`string` - Specific routing value - -|`_source` -|`string \| string[]` - True or false to return the _source field or not, or a list of fields to return - -|`_source_excludes` or `_sourceExcludes` -|`string \| string[]` - A list of fields to exclude from the returned _source field - -|`_source_includes` or `_sourceIncludes` -|`string \| string[]` - A list of fields to extract and return from the _source field -|`body` -|`object` - Document identifiers; can be either `docs` (containing full document information) or `ids` (when index is provided in the URL. - -|=== - -[discrete] -=== migration.deprecations +==== render_search_template +Allows to use the Mustache language to pre-render a search definition. +https://www.elastic.co/guide/en/elasticsearch/reference/current/render-search-template-api.html[Endpoint documentation] [source,ts] ---- -client.migration.deprecations({ - index: string -}) +client.renderSearchTemplate(...) ---- -link:{ref}/migration-api-deprecation.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - Index pattern -|=== - -[discrete] -=== ml.closeJob +==== scripts_painless_execute +Allows an arbitrary script to be executed and a result to be returned +https://www.elastic.co/guide/en/elasticsearch/painless/master/painless-execute-api.html[Endpoint documentation] [source,ts] ---- -client.ml.closeJob({ - job_id: string, - allow_no_match: boolean, - allow_no_jobs: boolean, - force: boolean, - timeout: string, - body: object -}) +client.scriptsPainlessExecute(...) ---- -link:{ref}/ml-close-job.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The name of the job to close - -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no jobs. (This includes `_all` string or when no jobs have been specified) - -|`allow_no_jobs` or `allowNoJobs` -|`boolean` - Whether to ignore if a wildcard expression matches no jobs. (This includes `_all` string or when no jobs have been specified) + - -WARNING: This parameter has been deprecated. - -|`force` -|`boolean` - True if the job should be forcefully closed - -|`timeout` -|`string` - Controls the time to wait until a job has closed. Default to 30 minutes -|`body` -|`object` - The URL params optionally sent in the body - -|=== - -[discrete] -=== ml.deleteCalendar +==== scroll +Allows to retrieve a large numbers of results from a single search request. +https://www.elastic.co/guide/en/elasticsearch/reference/master/search-request-body.html#request-body-search-scroll[Endpoint documentation] [source,ts] ---- -client.ml.deleteCalendar({ - calendar_id: string -}) +client.scroll(...) ---- -link:{ref}/ml-delete-calendar.html[Documentation] + -[cols=2*] -|=== -|`calendar_id` or `calendarId` -|`string` - The ID of the calendar to delete -|=== - -[discrete] -=== ml.deleteCalendarEvent +==== search +Returns results matching a query. +https://www.elastic.co/guide/en/elasticsearch/reference/master/search-search.html[Endpoint documentation] [source,ts] ---- -client.ml.deleteCalendarEvent({ - calendar_id: string, - event_id: string -}) +client.search(...) ---- -link:{ref}/ml-delete-calendar-event.html[Documentation] + -[cols=2*] -|=== -|`calendar_id` or `calendarId` -|`string` - The ID of the calendar to modify - -|`event_id` or `eventId` -|`string` - The ID of the event to remove from the calendar -|=== - -[discrete] -=== ml.deleteCalendarJob +==== search_mvt +Searches a vector tile for geospatial values. Returns results as a binary Mapbox vector tile. +https://www.elastic.co/guide/en/elasticsearch/reference/master/search-vector-tile-api.html[Endpoint documentation] [source,ts] ---- -client.ml.deleteCalendarJob({ - calendar_id: string, - job_id: string -}) +client.searchMvt(...) ---- -link:{ref}/ml-delete-calendar-job.html[Documentation] + -[cols=2*] -|=== -|`calendar_id` or `calendarId` -|`string` - The ID of the calendar to modify - -|`job_id` or `jobId` -|`string` - The ID of the job to remove from the calendar -|=== - -[discrete] -=== ml.deleteDataFrameAnalytics +==== search_shards +Returns information about the indices and shards that a search request would be executed against. +https://www.elastic.co/guide/en/elasticsearch/reference/master/search-shards.html[Endpoint documentation] [source,ts] ---- -client.ml.deleteDataFrameAnalytics({ - id: string, - force: boolean, - timeout: string -}) +client.searchShards(...) ---- -link:{ref}/delete-dfanalytics.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the data frame analytics to delete - -|`force` -|`boolean` - True if the job should be forcefully deleted -|`timeout` -|`string` - Controls the time to wait until a job is deleted. Defaults to 1 minute - -|=== - -[discrete] -=== ml.deleteDatafeed +==== search_template +Allows to use the Mustache language to pre-render a search definition. +https://www.elastic.co/guide/en/elasticsearch/reference/current/search-template.html[Endpoint documentation] [source,ts] ---- -client.ml.deleteDatafeed({ - datafeed_id: string, - force: boolean -}) +client.searchTemplate(...) ---- -link:{ref}/ml-delete-datafeed.html[Documentation] + -[cols=2*] -|=== -|`datafeed_id` or `datafeedId` -|`string` - The ID of the datafeed to delete - -|`force` -|`boolean` - True if the datafeed should be forcefully deleted - -|=== -[discrete] -=== ml.deleteExpiredData +==== terms_enum +The terms enum API can be used to discover terms in the index that begin with the provided string. It is designed for low-latency look-ups used in auto-complete scenarios. +https://www.elastic.co/guide/en/elasticsearch/reference/current/search-terms-enum.html[Endpoint documentation] [source,ts] ---- -client.ml.deleteExpiredData({ - job_id: string, - requests_per_second: number, - timeout: string, - body: object -}) +client.termsEnum(...) ---- -link:{ref}/ml-delete-expired-data.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the job(s) to perform expired data hygiene for - -|`requests_per_second` or `requestsPerSecond` -|`number` - The desired requests per second for the deletion processes. - -|`timeout` -|`string` - How long can the underlying delete processes run until they are canceled - -|`body` -|`object` - deleting expired data parameters - -|=== -[discrete] -=== ml.deleteFilter +==== termvectors +Returns information and statistics about terms in the fields of a particular document. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-termvectors.html[Endpoint documentation] [source,ts] ---- -client.ml.deleteFilter({ - filter_id: string -}) +client.termvectors(...) ---- -link:{ref}/ml-delete-filter.html[Documentation] + -[cols=2*] -|=== -|`filter_id` or `filterId` -|`string` - The ID of the filter to delete -|=== - -[discrete] -=== ml.deleteForecast +==== update +Updates a document with a script or partial document. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-update.html[Endpoint documentation] [source,ts] ---- -client.ml.deleteForecast({ - job_id: string, - forecast_id: string, - allow_no_forecasts: boolean, - timeout: string -}) +client.update(...) ---- -link:{ref}/ml-delete-forecast.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the job from which to delete forecasts - -|`forecast_id` or `forecastId` -|`string` - The ID of the forecast to delete, can be comma delimited list. Leaving blank implies `_all` - -|`allow_no_forecasts` or `allowNoForecasts` -|`boolean` - Whether to ignore if `_all` matches no forecasts - -|`timeout` -|`string` - Controls the time to wait until the forecast(s) are deleted. Default to 30 seconds -|=== - -[discrete] -=== ml.deleteJob +==== update_by_query +Performs an update on every document in the index without changing the source, +for example to pick up a mapping change. +https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-update-by-query.html[Endpoint documentation] [source,ts] ---- -client.ml.deleteJob({ - job_id: string, - force: boolean, - wait_for_completion: boolean -}) +client.updateByQuery(...) ---- -link:{ref}/ml-delete-job.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the job to delete - -|`force` -|`boolean` - True if the job should be forcefully deleted - -|`wait_for_completion` or `waitForCompletion` -|`boolean` - Should this request wait until the operation has completed before returning + -_Default:_ `true` - -|=== -[discrete] -=== ml.deleteModelSnapshot +==== update_by_query_rethrottle +Changes the number of requests per second for a particular Update By Query operation. +https://www.elastic.co/guide/en/elasticsearch/reference/current/docs-update-by-query.html[Endpoint documentation] [source,ts] ---- -client.ml.deleteModelSnapshot({ - job_id: string, - snapshot_id: string -}) +client.updateByQueryRethrottle(...) ---- -link:{ref}/ml-delete-snapshot.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the job to fetch -|`snapshot_id` or `snapshotId` -|`string` - The ID of the snapshot to delete - -|=== - -[discrete] -=== ml.deleteTrainedModel +=== async_search +==== delete +Deletes an async search by ID. If the search is still running, the search request will be cancelled. Otherwise, the saved search results are deleted. +https://www.elastic.co/guide/en/elasticsearch/reference/master/async-search.html[Endpoint documentation] [source,ts] ---- -client.ml.deleteTrainedModel({ - model_id: string -}) +client.asyncSearch.delete(...) ---- -link:{ref}/delete-trained-models.html[Documentation] + -[cols=2*] -|=== -|`model_id` or `modelId` -|`string` - The ID of the trained model to delete -|=== - -[discrete] -=== ml.deleteTrainedModelAlias +==== get +Retrieves the results of a previously submitted async search request given its ID. +https://www.elastic.co/guide/en/elasticsearch/reference/master/async-search.html[Endpoint documentation] [source,ts] ---- -client.ml.deleteTrainedModelAlias({ - model_alias: string, - model_id: string -}) +client.asyncSearch.get(...) ---- -link:{ref}/delete-trained-models-aliases.html[Documentation] + -[cols=2*] -|=== -|`model_alias` or `modelAlias` -|`string` - The trained model alias to delete - -|`model_id` or `modelId` -|`string` - The trained model where the model alias is assigned -|=== - -[discrete] -=== ml.estimateModelMemory +==== status +Retrieves the status of a previously submitted async search request given its ID. +https://www.elastic.co/guide/en/elasticsearch/reference/master/async-search.html[Endpoint documentation] [source,ts] ---- -client.ml.estimateModelMemory({ - body: object -}) +client.asyncSearch.status(...) ---- -link:{ref}/ml-apis.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - The analysis config, plus cardinality estimates for fields it references - -|=== -[discrete] -=== ml.evaluateDataFrame +==== submit +Executes a search request asynchronously. +https://www.elastic.co/guide/en/elasticsearch/reference/master/async-search.html[Endpoint documentation] [source,ts] ---- -client.ml.evaluateDataFrame({ - body: object -}) +client.asyncSearch.submit(...) ---- -link:{ref}/evaluate-dfanalytics.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - The evaluation definition -|=== - -[discrete] -=== ml.explainDataFrameAnalytics +=== cat +==== aliases +Shows information about currently configured aliases to indices including filter and routing infos. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-alias.html[Endpoint documentation] [source,ts] ---- -client.ml.explainDataFrameAnalytics({ - id: string, - body: object -}) +client.cat.aliases(...) ---- -link:{ref}/explain-dfanalytics.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the data frame analytics to explain - -|`body` -|`object` - The data frame analytics config to explain -|=== - -[discrete] -=== ml.flushJob +==== allocation +Provides a snapshot of how many shards are allocated to each data node and how much disk space they are using. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-allocation.html[Endpoint documentation] [source,ts] ---- -client.ml.flushJob({ - job_id: string, - calc_interim: boolean, - start: string, - end: string, - advance_time: string, - skip_time: string, - body: object -}) +client.cat.allocation(...) ---- -link:{ref}/ml-flush-job.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The name of the job to flush - -|`calc_interim` or `calcInterim` -|`boolean` - Calculates interim results for the most recent bucket or all buckets within the latency period - -|`start` -|`string` - When used in conjunction with calc_interim, specifies the range of buckets on which to calculate interim results - -|`end` -|`string` - When used in conjunction with calc_interim, specifies the range of buckets on which to calculate interim results - -|`advance_time` or `advanceTime` -|`string` - Advances time to the given value generating results and updating the model for the advanced interval - -|`skip_time` or `skipTime` -|`string` - Skips time to the given value without generating results or updating the model for the skipped interval - -|`body` -|`object` - Flush parameters - -|=== -[discrete] -=== ml.forecast +==== count +Provides quick access to the document count of the entire cluster, or individual indices. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-count.html[Endpoint documentation] [source,ts] ---- -client.ml.forecast({ - job_id: string, - duration: string, - expires_in: string, - max_model_memory: string -}) +client.cat.count(...) ---- -link:{ref}/ml-forecast.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the job to forecast for -|`duration` -|`string` - The duration of the forecast - -|`expires_in` or `expiresIn` -|`string` - The time interval after which the forecast expires. Expired forecasts will be deleted at the first opportunity. - -|`max_model_memory` or `maxModelMemory` -|`string` - The max memory able to be used by the forecast. Default is 20mb. - -|=== - -[discrete] -=== ml.getBuckets +==== fielddata +Shows how much heap memory is currently being used by fielddata on every data node in the cluster. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-fielddata.html[Endpoint documentation] [source,ts] ---- -client.ml.getBuckets({ - job_id: string, - timestamp: string, - expand: boolean, - exclude_interim: boolean, - from: number, - size: number, - start: string, - end: string, - anomaly_score: number, - sort: string, - desc: boolean, - body: object -}) +client.cat.fielddata(...) ---- -link:{ref}/ml-get-bucket.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - ID of the job to get bucket results from - -|`timestamp` -|`string` - The timestamp of the desired single bucket result - -|`expand` -|`boolean` - Include anomaly records - -|`exclude_interim` or `excludeInterim` -|`boolean` - Exclude interim results - -|`from` -|`number` - skips a number of buckets - -|`size` -|`number` - specifies a max number of buckets to get - -|`start` -|`string` - Start time filter for buckets - -|`end` -|`string` - End time filter for buckets - -|`anomaly_score` or `anomalyScore` -|`number` - Filter for the most anomalous buckets - -|`sort` -|`string` - Sort buckets by a particular field - -|`desc` -|`boolean` - Set the sort direction - -|`body` -|`object` - Bucket selection details if not provided in URI - -|=== -[discrete] -=== ml.getCalendarEvents +==== health +Returns a concise representation of the cluster health. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-health.html[Endpoint documentation] [source,ts] ---- -client.ml.getCalendarEvents({ - calendar_id: string, - job_id: string, - start: string, - end: string, - from: number, - size: number -}) +client.cat.health(...) ---- -link:{ref}/ml-get-calendar-event.html[Documentation] + -[cols=2*] -|=== -|`calendar_id` or `calendarId` -|`string` - The ID of the calendar containing the events -|`job_id` or `jobId` -|`string` - Get events for the job. When this option is used calendar_id must be '_all' - -|`start` -|`string` - Get events after this time - -|`end` -|`string` - Get events before this time - -|`from` -|`number` - Skips a number of events - -|`size` -|`number` - Specifies a max number of events to get - -|=== - -[discrete] -=== ml.getCalendars +==== help +Returns help for the Cat APIs. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat.html[Endpoint documentation] [source,ts] ---- -client.ml.getCalendars({ - calendar_id: string, - from: number, - size: number, - body: object -}) +client.cat.help(...) ---- -link:{ref}/ml-get-calendar.html[Documentation] + -[cols=2*] -|=== -|`calendar_id` or `calendarId` -|`string` - The ID of the calendar to fetch - -|`from` -|`number` - skips a number of calendars - -|`size` -|`number` - specifies a max number of calendars to get -|`body` -|`object` - The from and size parameters optionally sent in the body - -|=== - -[discrete] -=== ml.getCategories +==== indices +Returns information about indices: number of primaries and replicas, document counts, disk size, ... +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-indices.html[Endpoint documentation] [source,ts] ---- -client.ml.getCategories({ - job_id: string, - category_id: number, - from: number, - size: number, - partition_field_value: string, - body: object -}) +client.cat.indices(...) ---- -link:{ref}/ml-get-category.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The name of the job - -|`category_id` or `categoryId` -|`number` - The identifier of the category definition of interest - -|`from` -|`number` - skips a number of categories - -|`size` -|`number` - specifies a max number of categories to get - -|`partition_field_value` or `partitionFieldValue` -|`string` - Specifies the partition to retrieve categories for. This is optional, and should never be used for jobs where per-partition categorization is disabled. - -|`body` -|`object` - Category selection details if not provided in URI - -|=== -[discrete] -=== ml.getDataFrameAnalytics +==== master +Returns information about the master node. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-master.html[Endpoint documentation] [source,ts] ---- -client.ml.getDataFrameAnalytics({ - id: string, - allow_no_match: boolean, - from: number, - size: number, - exclude_generated: boolean -}) +client.cat.master(...) ---- -link:{ref}/get-dfanalytics.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the data frame analytics to fetch -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no data frame analytics. (This includes `_all` string or when no data frame analytics have been specified) + -_Default:_ `true` - -|`from` -|`number` - skips a number of analytics - -|`size` -|`number` - specifies a max number of analytics to get + -_Default:_ `100` - -|`exclude_generated` or `excludeGenerated` -|`boolean` - Omits fields that are illegal to set on data frame analytics PUT - -|=== - -[discrete] -=== ml.getDataFrameAnalyticsStats +==== ml_data_frame_analytics +Gets configuration and usage information about data frame analytics jobs. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-dfanalytics.html[Endpoint documentation] [source,ts] ---- -client.ml.getDataFrameAnalyticsStats({ - id: string, - allow_no_match: boolean, - from: number, - size: number, - verbose: boolean -}) +client.cat.mlDataFrameAnalytics(...) ---- -link:{ref}/get-dfanalytics-stats.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the data frame analytics stats to fetch - -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no data frame analytics. (This includes `_all` string or when no data frame analytics have been specified) + -_Default:_ `true` - -|`from` -|`number` - skips a number of analytics - -|`size` -|`number` - specifies a max number of analytics to get + -_Default:_ `100` -|`verbose` -|`boolean` - whether the stats response should be verbose - -|=== - -[discrete] -=== ml.getDatafeedStats +==== ml_datafeeds +Gets configuration and usage information about datafeeds. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-datafeeds.html[Endpoint documentation] [source,ts] ---- -client.ml.getDatafeedStats({ - datafeed_id: string, - allow_no_match: boolean, - allow_no_datafeeds: boolean -}) +client.cat.mlDatafeeds(...) ---- -link:{ref}/ml-get-datafeed-stats.html[Documentation] + -[cols=2*] -|=== -|`datafeed_id` or `datafeedId` -|`string` - The ID of the datafeeds stats to fetch - -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no datafeeds. (This includes `_all` string or when no datafeeds have been specified) - -|`allow_no_datafeeds` or `allowNoDatafeeds` -|`boolean` - Whether to ignore if a wildcard expression matches no datafeeds. (This includes `_all` string or when no datafeeds have been specified) + -WARNING: This parameter has been deprecated. - -|=== - -[discrete] -=== ml.getDatafeeds +==== ml_jobs +Gets configuration and usage information about anomaly detection jobs. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-anomaly-detectors.html[Endpoint documentation] [source,ts] ---- -client.ml.getDatafeeds({ - datafeed_id: string, - allow_no_match: boolean, - allow_no_datafeeds: boolean, - exclude_generated: boolean -}) +client.cat.mlJobs(...) ---- -link:{ref}/ml-get-datafeed.html[Documentation] + -[cols=2*] -|=== -|`datafeed_id` or `datafeedId` -|`string` - The ID of the datafeeds to fetch - -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no datafeeds. (This includes `_all` string or when no datafeeds have been specified) - -|`allow_no_datafeeds` or `allowNoDatafeeds` -|`boolean` - Whether to ignore if a wildcard expression matches no datafeeds. (This includes `_all` string or when no datafeeds have been specified) + -WARNING: This parameter has been deprecated. - -|`exclude_generated` or `excludeGenerated` -|`boolean` - Omits fields that are illegal to set on datafeed PUT - -|=== - -[discrete] -=== ml.getFilters +==== ml_trained_models +Gets configuration and usage information about inference trained models. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-trained-model.html[Endpoint documentation] [source,ts] ---- -client.ml.getFilters({ - filter_id: string, - from: number, - size: number -}) +client.cat.mlTrainedModels(...) ---- -link:{ref}/ml-get-filter.html[Documentation] + -[cols=2*] -|=== -|`filter_id` or `filterId` -|`string` - The ID of the filter to fetch - -|`from` -|`number` - skips a number of filters -|`size` -|`number` - specifies a max number of filters to get - -|=== - -[discrete] -=== ml.getInfluencers +==== nodeattrs +Returns information about custom node attributes. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-nodeattrs.html[Endpoint documentation] [source,ts] ---- -client.ml.getInfluencers({ - job_id: string, - exclude_interim: boolean, - from: number, - size: number, - start: string, - end: string, - influencer_score: number, - sort: string, - desc: boolean, - body: object -}) +client.cat.nodeattrs(...) ---- -link:{ref}/ml-get-influencer.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - Identifier for the anomaly detection job - -|`exclude_interim` or `excludeInterim` -|`boolean` - Exclude interim results - -|`from` -|`number` - skips a number of influencers - -|`size` -|`number` - specifies a max number of influencers to get - -|`start` -|`string` - start timestamp for the requested influencers - -|`end` -|`string` - end timestamp for the requested influencers - -|`influencer_score` or `influencerScore` -|`number` - influencer score threshold for the requested influencers - -|`sort` -|`string` - sort field for the requested influencers - -|`desc` -|`boolean` - whether the results should be sorted in decending order - -|`body` -|`object` - Influencer selection criteria - -|=== -[discrete] -=== ml.getJobStats +==== nodes +Returns basic statistics about performance of cluster nodes. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-nodes.html[Endpoint documentation] [source,ts] ---- -client.ml.getJobStats({ - job_id: string, - allow_no_match: boolean, - allow_no_jobs: boolean -}) +client.cat.nodes(...) ---- -link:{ref}/ml-get-job-stats.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the jobs stats to fetch -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no jobs. (This includes `_all` string or when no jobs have been specified) +==== pending_tasks +Returns a concise representation of the cluster pending tasks. -|`allow_no_jobs` or `allowNoJobs` -|`boolean` - Whether to ignore if a wildcard expression matches no jobs. (This includes `_all` string or when no jobs have been specified) + +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-pending-tasks.html[Endpoint documentation] +[source,ts] +---- +client.cat.pendingTasks(...) +---- -WARNING: This parameter has been deprecated. +==== plugins +Returns information about installed plugins across nodes node. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-plugins.html[Endpoint documentation] +[source,ts] +---- +client.cat.plugins(...) +---- -[discrete] -=== ml.getJobs +==== recovery +Returns information about index shard recoveries, both on-going completed. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-recovery.html[Endpoint documentation] [source,ts] ---- -client.ml.getJobs({ - job_id: string, - allow_no_match: boolean, - allow_no_jobs: boolean, - exclude_generated: boolean -}) +client.cat.recovery(...) ---- -link:{ref}/ml-get-job.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the jobs to fetch -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no jobs. (This includes `_all` string or when no jobs have been specified) +==== repositories +Returns information about snapshot repositories registered in the cluster. -|`allow_no_jobs` or `allowNoJobs` -|`boolean` - Whether to ignore if a wildcard expression matches no jobs. (This includes `_all` string or when no jobs have been specified) + - -WARNING: This parameter has been deprecated. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-repositories.html[Endpoint documentation] +[source,ts] +---- +client.cat.repositories(...) +---- -|`exclude_generated` or `excludeGenerated` -|`boolean` - Omits fields that are illegal to set on job PUT +==== segments +Provides low-level information about the segments in the shards of an index. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-segments.html[Endpoint documentation] +[source,ts] +---- +client.cat.segments(...) +---- -[discrete] -=== ml.getModelSnapshots +==== shards +Provides a detailed view of shard allocation on nodes. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-shards.html[Endpoint documentation] [source,ts] ---- -client.ml.getModelSnapshots({ - job_id: string, - snapshot_id: string, - from: number, - size: number, - start: string, - end: string, - sort: string, - desc: boolean, - body: object -}) +client.cat.shards(...) ---- -link:{ref}/ml-get-snapshot.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the job to fetch - -|`snapshot_id` or `snapshotId` -|`string` - The ID of the snapshot to fetch -|`from` -|`number` - Skips a number of documents +==== snapshots +Returns all snapshots in a specific repository. -|`size` -|`number` - The default number of documents returned in queries as a string. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-snapshots.html[Endpoint documentation] +[source,ts] +---- +client.cat.snapshots(...) +---- -|`start` -|`string` - The filter 'start' query parameter +==== tasks +Returns information about the tasks currently executing on one or more nodes in the cluster. -|`end` -|`string` - The filter 'end' query parameter +https://www.elastic.co/guide/en/elasticsearch/reference/master/tasks.html[Endpoint documentation] +[source,ts] +---- +client.cat.tasks(...) +---- -|`sort` -|`string` - Name of the field to sort on +==== templates +Returns information about existing templates. -|`desc` -|`boolean` - True if the results should be sorted in descending order +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-templates.html[Endpoint documentation] +[source,ts] +---- +client.cat.templates(...) +---- -|`body` -|`object` - Model snapshot selection criteria +==== thread_pool +Returns cluster-wide thread pool statistics per node. +By default the active, queue and rejected statistics are returned for all thread pools. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-thread-pool.html[Endpoint documentation] +[source,ts] +---- +client.cat.threadPool(...) +---- -[discrete] -=== ml.getOverallBuckets +==== transforms +Gets configuration and usage information about transforms. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-transforms.html[Endpoint documentation] [source,ts] ---- -client.ml.getOverallBuckets({ - job_id: string, - top_n: number, - bucket_span: string, - overall_score: number, - exclude_interim: boolean, - start: string, - end: string, - allow_no_match: boolean, - allow_no_jobs: boolean, - body: object -}) +client.cat.transforms(...) ---- -link:{ref}/ml-get-overall-buckets.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The job IDs for which to calculate overall bucket results -|`top_n` or `topN` -|`number` - The number of top job bucket scores to be used in the overall_score calculation +=== ccr +==== delete_auto_follow_pattern +Deletes auto-follow patterns. -|`bucket_span` or `bucketSpan` -|`string` - The span of the overall buckets. Defaults to the longest job bucket_span - -|`overall_score` or `overallScore` -|`number` - Returns overall buckets with overall scores higher than this value +https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-delete-auto-follow-pattern.html[Endpoint documentation] +[source,ts] +---- +client.ccr.deleteAutoFollowPattern(...) +---- -|`exclude_interim` or `excludeInterim` -|`boolean` - If true overall buckets that include interim buckets will be excluded +==== follow +Creates a new follower index configured to follow the referenced leader index. -|`start` -|`string` - Returns overall buckets with timestamps after this time +https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-put-follow.html[Endpoint documentation] +[source,ts] +---- +client.ccr.follow(...) +---- -|`end` -|`string` - Returns overall buckets with timestamps earlier than this time +==== follow_info +Retrieves information about all follower indices, including parameters and status for each follower index -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no jobs. (This includes `_all` string or when no jobs have been specified) +https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-get-follow-info.html[Endpoint documentation] +[source,ts] +---- +client.ccr.followInfo(...) +---- -|`allow_no_jobs` or `allowNoJobs` -|`boolean` - Whether to ignore if a wildcard expression matches no jobs. (This includes `_all` string or when no jobs have been specified) + +==== follow_stats +Retrieves follower stats. return shard-level stats about the following tasks associated with each shard for the specified indices. -WARNING: This parameter has been deprecated. +https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-get-follow-stats.html[Endpoint documentation] +[source,ts] +---- +client.ccr.followStats(...) +---- -|`body` -|`object` - Overall bucket selection details if not provided in URI +==== forget_follower +Removes the follower retention leases from the leader. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-post-forget-follower.html[Endpoint documentation] +[source,ts] +---- +client.ccr.forgetFollower(...) +---- -[discrete] -=== ml.getRecords +==== get_auto_follow_pattern +Gets configured auto-follow patterns. Returns the specified auto-follow pattern collection. +https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-get-auto-follow-pattern.html[Endpoint documentation] [source,ts] ---- -client.ml.getRecords({ - job_id: string, - exclude_interim: boolean, - from: number, - size: number, - start: string, - end: string, - record_score: number, - sort: string, - desc: boolean, - body: object -}) +client.ccr.getAutoFollowPattern(...) ---- -link:{ref}/ml-get-record.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the job -|`exclude_interim` or `excludeInterim` -|`boolean` - Exclude interim results +==== pause_auto_follow_pattern +Pauses an auto-follow pattern -|`from` -|`number` - skips a number of records +https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-pause-auto-follow-pattern.html[Endpoint documentation] +[source,ts] +---- +client.ccr.pauseAutoFollowPattern(...) +---- -|`size` -|`number` - specifies a max number of records to get +==== pause_follow +Pauses a follower index. The follower index will not fetch any additional operations from the leader index. -|`start` -|`string` - Start time filter for records +https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-post-pause-follow.html[Endpoint documentation] +[source,ts] +---- +client.ccr.pauseFollow(...) +---- -|`end` -|`string` - End time filter for records +==== put_auto_follow_pattern +Creates a new named collection of auto-follow patterns against a specified remote cluster. Newly created indices on the remote cluster matching any of the specified patterns will be automatically configured as follower indices. -|`record_score` or `recordScore` -|`number` - Returns records with anomaly scores greater or equal than this value +https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-put-auto-follow-pattern.html[Endpoint documentation] +[source,ts] +---- +client.ccr.putAutoFollowPattern(...) +---- -|`sort` -|`string` - Sort records by a particular field +==== resume_auto_follow_pattern +Resumes an auto-follow pattern that has been paused -|`desc` -|`boolean` - Set the sort direction +https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-resume-auto-follow-pattern.html[Endpoint documentation] +[source,ts] +---- +client.ccr.resumeAutoFollowPattern(...) +---- -|`body` -|`object` - Record selection criteria +==== resume_follow +Resumes a follower index that has been paused -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-post-resume-follow.html[Endpoint documentation] +[source,ts] +---- +client.ccr.resumeFollow(...) +---- -[discrete] -=== ml.getTrainedModels +==== stats +Gets all stats related to cross-cluster replication. +https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-get-stats.html[Endpoint documentation] [source,ts] ---- -client.ml.getTrainedModels({ - model_id: string, - allow_no_match: boolean, - include: string, - include_model_definition: boolean, - decompress_definition: boolean, - from: number, - size: number, - tags: string | string[], - exclude_generated: boolean -}) +client.ccr.stats(...) ---- -link:{ref}/get-trained-models.html[Documentation] + -[cols=2*] -|=== -|`model_id` or `modelId` -|`string` - The ID of the trained models to fetch -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no trained models. (This includes `_all` string or when no trained models have been specified) + -_Default:_ `true` +==== unfollow +Stops the following task associated with a follower index and removes index metadata and settings associated with cross-cluster replication. -|`include` -|`string` - A comma-separate list of fields to optionally include. Valid options are 'definition' and 'total_feature_importance'. Default is none. +https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-post-unfollow.html[Endpoint documentation] +[source,ts] +---- +client.ccr.unfollow(...) +---- -|`include_model_definition` or `includeModelDefinition` -|`boolean` - Should the full model definition be included in the results. These definitions can be large. So be cautious when including them. Defaults to false. + +=== cluster +==== allocation_explain +Provides explanations for shard allocations in the cluster. -WARNING: This parameter has been deprecated. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-allocation-explain.html[Endpoint documentation] +[source,ts] +---- +client.cluster.allocationExplain(...) +---- -|`decompress_definition` or `decompressDefinition` -|`boolean` - Should the model definition be decompressed into valid JSON or returned in a custom compressed format. Defaults to true. + -_Default:_ `true` +==== delete_component_template +Deletes a component template -|`from` -|`number` - skips a number of trained models +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-component-template.html[Endpoint documentation] +[source,ts] +---- +client.cluster.deleteComponentTemplate(...) +---- -|`size` -|`number` - specifies a max number of trained models to get + -_Default:_ `100` +==== delete_voting_config_exclusions +Clears cluster voting config exclusions. -|`tags` -|`string \| string[]` - A comma-separated list of tags that the model must have. +https://www.elastic.co/guide/en/elasticsearch/reference/master/voting-config-exclusions.html[Endpoint documentation] +[source,ts] +---- +client.cluster.deleteVotingConfigExclusions(...) +---- -|`exclude_generated` or `excludeGenerated` -|`boolean` - Omits fields that are illegal to set on model PUT +==== exists_component_template +Returns information about whether a particular component template exist -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-component-template.html[Endpoint documentation] +[source,ts] +---- +client.cluster.existsComponentTemplate(...) +---- -[discrete] -=== ml.getTrainedModelsStats +==== get_component_template +Returns one or more component templates +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-component-template.html[Endpoint documentation] [source,ts] ---- -client.ml.getTrainedModelsStats({ - model_id: string, - allow_no_match: boolean, - from: number, - size: number -}) +client.cluster.getComponentTemplate(...) ---- -link:{ref}/get-trained-models-stats.html[Documentation] + -[cols=2*] -|=== -|`model_id` or `modelId` -|`string` - The ID of the trained models stats to fetch -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no trained models. (This includes `_all` string or when no trained models have been specified) + -_Default:_ `true` +==== get_settings +Returns cluster settings. -|`from` -|`number` - skips a number of trained models - -|`size` -|`number` - specifies a max number of trained models to get + -_Default:_ `100` +https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-get-settings.html[Endpoint documentation] +[source,ts] +---- +client.cluster.getSettings(...) +---- -|=== +==== health +Returns basic information about the health of the cluster. -[discrete] -=== ml.inferTrainedModelDeployment -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-health.html[Endpoint documentation] [source,ts] ---- -client.ml.inferTrainedModelDeployment({ - model_id: string, - timeout: string, - body: object -}) +client.cluster.health(...) ---- -link:{ref}/infer-trained-model-deployment.html[Documentation] + -[cols=2*] -|=== -|`model_id` or `modelId` -|`string` - The unique identifier of the trained model. -|`timeout` -|`string` - Controls the amount of time to wait for inference results. + -_Default:_ `10s` +==== pending_tasks +Returns a list of any cluster-level changes (e.g. create index, update mapping, +allocate or fail shard) which have not yet been executed. -|`body` -|`object` - The input text to be evaluated. - -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-pending.html[Endpoint documentation] +[source,ts] +---- +client.cluster.pendingTasks(...) +---- -[discrete] -=== ml.info +==== post_voting_config_exclusions +Updates the cluster voting config exclusions by node ids or node names. +https://www.elastic.co/guide/en/elasticsearch/reference/master/voting-config-exclusions.html[Endpoint documentation] [source,ts] ---- -client.ml.info() +client.cluster.postVotingConfigExclusions(...) ---- -link:{ref}/get-ml-info.html[Documentation] + +==== put_component_template +Creates or updates a component template -[discrete] -=== ml.openJob - +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-component-template.html[Endpoint documentation] [source,ts] ---- -client.ml.openJob({ - job_id: string -}) +client.cluster.putComponentTemplate(...) ---- -link:{ref}/ml-open-job.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the job to open - -|=== -[discrete] -=== ml.postCalendarEvents +==== put_settings +Updates the cluster settings. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-update-settings.html[Endpoint documentation] [source,ts] ---- -client.ml.postCalendarEvents({ - calendar_id: string, - body: object -}) +client.cluster.putSettings(...) ---- -link:{ref}/ml-post-calendar-event.html[Documentation] + -[cols=2*] -|=== -|`calendar_id` or `calendarId` -|`string` - The ID of the calendar to modify -|`body` -|`object` - A list of events +==== remote_info +Returns the information about configured remote clusters. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-remote-info.html[Endpoint documentation] +[source,ts] +---- +client.cluster.remoteInfo(...) +---- -[discrete] -=== ml.postData +==== reroute +Allows to manually change the allocation of individual shards in the cluster. +https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-reroute.html[Endpoint documentation] [source,ts] ---- -client.ml.postData({ - job_id: string, - reset_start: string, - reset_end: string, - body: object -}) +client.cluster.reroute(...) ---- -link:{ref}/ml-post-data.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The name of the job receiving the data -|`reset_start` or `resetStart` -|`string` - Optional parameter to specify the start of the bucket resetting range +==== state +Returns a comprehensive information about the state of the cluster. -|`reset_end` or `resetEnd` -|`string` - Optional parameter to specify the end of the bucket resetting range +https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-state.html[Endpoint documentation] +[source,ts] +---- +client.cluster.state(...) +---- -|`body` -|`object` - The data to process +==== stats +Returns high-level overview of cluster statistics. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-stats.html[Endpoint documentation] +[source,ts] +---- +client.cluster.stats(...) +---- -[discrete] -=== ml.previewDataFrameAnalytics +=== dangling_indices +==== delete_dangling_index +Deletes the specified dangling index +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-gateway-dangling-indices.html[Endpoint documentation] [source,ts] ---- -client.ml.previewDataFrameAnalytics({ - id: string, - body: object -}) +client.danglingIndices.deleteDanglingIndex(...) ---- -link:{ref}/preview-dfanalytics.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the data frame analytics to preview -|`body` -|`object` - The data frame analytics config to preview +==== import_dangling_index +Imports the specified dangling index -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-gateway-dangling-indices.html[Endpoint documentation] +[source,ts] +---- +client.danglingIndices.importDanglingIndex(...) +---- -[discrete] -=== ml.previewDatafeed +==== list_dangling_indices +Returns all dangling indices. +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-gateway-dangling-indices.html[Endpoint documentation] [source,ts] ---- -client.ml.previewDatafeed({ - datafeed_id: string, - body: object -}) +client.danglingIndices.listDanglingIndices(...) ---- -link:{ref}/ml-preview-datafeed.html[Documentation] + -[cols=2*] -|=== -|`datafeed_id` or `datafeedId` -|`string` - The ID of the datafeed to preview -|`body` -|`object` - The datafeed config and job config with which to execute the preview +=== enrich +==== delete_policy +Deletes an existing enrich policy and its enrich index. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/delete-enrich-policy-api.html[Endpoint documentation] +[source,ts] +---- +client.enrich.deletePolicy(...) +---- -[discrete] -=== ml.putCalendar +==== execute_policy +Creates the enrich index for an existing enrich policy. +https://www.elastic.co/guide/en/elasticsearch/reference/current/execute-enrich-policy-api.html[Endpoint documentation] [source,ts] ---- -client.ml.putCalendar({ - calendar_id: string, - body: object -}) +client.enrich.executePolicy(...) ---- -link:{ref}/ml-put-calendar.html[Documentation] + -[cols=2*] -|=== -|`calendar_id` or `calendarId` -|`string` - The ID of the calendar to create -|`body` -|`object` - The calendar details +==== get_policy +Gets information about an enrich policy. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/get-enrich-policy-api.html[Endpoint documentation] +[source,ts] +---- +client.enrich.getPolicy(...) +---- -[discrete] -=== ml.putCalendarJob +==== put_policy +Creates a new enrich policy. +https://www.elastic.co/guide/en/elasticsearch/reference/current/put-enrich-policy-api.html[Endpoint documentation] [source,ts] ---- -client.ml.putCalendarJob({ - calendar_id: string, - job_id: string -}) +client.enrich.putPolicy(...) ---- -link:{ref}/ml-put-calendar-job.html[Documentation] + -[cols=2*] -|=== -|`calendar_id` or `calendarId` -|`string` - The ID of the calendar to modify -|`job_id` or `jobId` -|`string` - The ID of the job to add to the calendar +==== stats +Gets enrich coordinator statistics and information about enrich policies that are currently executing. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/enrich-stats-api.html[Endpoint documentation] +[source,ts] +---- +client.enrich.stats(...) +---- -[discrete] -=== ml.putDataFrameAnalytics +=== eql +==== delete +Deletes an async EQL search by ID. If the search is still running, the search request will be cancelled. Otherwise, the saved search results are deleted. +https://www.elastic.co/guide/en/elasticsearch/reference/current/eql-search-api.html[Endpoint documentation] [source,ts] ---- -client.ml.putDataFrameAnalytics({ - id: string, - body: object -}) +client.eql.delete(...) ---- -link:{ref}/put-dfanalytics.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the data frame analytics to create -|`body` -|`object` - The data frame analytics configuration +==== get +Returns async results from previously executed Event Query Language (EQL) search -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/eql-search-api.html[Endpoint documentation] +[source,ts] +---- +client.eql.get(...) +---- -[discrete] -=== ml.putDatafeed +==== get_status +Returns the status of a previously submitted async or stored Event Query Language (EQL) search +https://www.elastic.co/guide/en/elasticsearch/reference/current/eql-search-api.html[Endpoint documentation] [source,ts] ---- -client.ml.putDatafeed({ - datafeed_id: string, - ignore_unavailable: boolean, - allow_no_indices: boolean, - ignore_throttled: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - body: object -}) +client.eql.getStatus(...) ---- -link:{ref}/ml-put-datafeed.html[Documentation] + -[cols=2*] -|=== -|`datafeed_id` or `datafeedId` -|`string` - The ID of the datafeed to create -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Ignore unavailable indexes (default: false) +==== search +Returns results matching a query expressed in Event Query Language (EQL) -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Ignore if the source indices expressions resolves to no concrete indices (default: true) +https://www.elastic.co/guide/en/elasticsearch/reference/current/eql-search-api.html[Endpoint documentation] +[source,ts] +---- +client.eql.search(...) +---- -|`ignore_throttled` or `ignoreThrottled` -|`boolean` - Ignore indices that are marked as throttled (default: true) +=== features +==== get_features +Gets a list of features which can be included in snapshots using the feature_states field when creating a snapshot -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether source index expressions should get expanded to open or closed indices (default: open) +https://www.elastic.co/guide/en/elasticsearch/reference/master/get-features-api.html[Endpoint documentation] +[source,ts] +---- +client.features.getFeatures(...) +---- -|`body` -|`object` - The datafeed config +==== reset_features +Resets the internal state of features, usually by deleting system indices -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html[Endpoint documentation] +[source,ts] +---- +client.features.resetFeatures(...) +---- -[discrete] -=== ml.putFilter +=== fleet +==== global_checkpoints +Returns the current global checkpoints for an index. This API is design for internal use by the fleet server project. +https://www.elastic.co/guide/en/elasticsearch/reference/current/get-global-checkpoints.html[Endpoint documentation] [source,ts] ---- -client.ml.putFilter({ - filter_id: string, - body: object -}) +client.fleet.globalCheckpoints(...) ---- -link:{ref}/ml-put-filter.html[Documentation] + -[cols=2*] -|=== -|`filter_id` or `filterId` -|`string` - The ID of the filter to create -|`body` -|`object` - The filter details +==== msearch +Multi Search API where the search will only be executed after specified checkpoints are available due to a refresh. This API is designed for internal use by the fleet server project. +[source,ts] +---- +client.fleet.msearch(...) +---- -|=== +==== search +Search API where the search will only be executed after specified checkpoints are available due to a refresh. This API is designed for internal use by the fleet server project. +[source,ts] +---- +client.fleet.search(...) +---- -[discrete] -=== ml.putJob +=== graph +==== explore +Explore extracted and summarized information about the documents and terms in an index. +https://www.elastic.co/guide/en/elasticsearch/reference/current/graph-explore-api.html[Endpoint documentation] [source,ts] ---- -client.ml.putJob({ - job_id: string, - ignore_unavailable: boolean, - allow_no_indices: boolean, - ignore_throttled: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - body: object -}) +client.graph.explore(...) ---- -link:{ref}/ml-put-job.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the job to create -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Ignore unavailable indexes (default: false). Only set if datafeed_config is provided. +=== ilm +==== delete_lifecycle +Deletes the specified lifecycle policy definition. A currently used policy cannot be deleted. -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Ignore if the source indices expressions resolves to no concrete indices (default: true). Only set if datafeed_config is provided. +https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-delete-lifecycle.html[Endpoint documentation] +[source,ts] +---- +client.ilm.deleteLifecycle(...) +---- -|`ignore_throttled` or `ignoreThrottled` -|`boolean` - Ignore indices that are marked as throttled (default: true). Only set if datafeed_config is provided. +==== explain_lifecycle +Retrieves information about the index's current lifecycle state, such as the currently executing phase, action, and step. -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether source index expressions should get expanded to open or closed indices (default: open). Only set if datafeed_config is provided. +https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-explain-lifecycle.html[Endpoint documentation] +[source,ts] +---- +client.ilm.explainLifecycle(...) +---- -|`body` -|`object` - The job +==== get_lifecycle +Returns the specified policy definition. Includes the policy version and last modified date. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-get-lifecycle.html[Endpoint documentation] +[source,ts] +---- +client.ilm.getLifecycle(...) +---- -[discrete] -=== ml.putTrainedModel +==== get_status +Retrieves the current index lifecycle management (ILM) status. +https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-get-status.html[Endpoint documentation] [source,ts] ---- -client.ml.putTrainedModel({ - model_id: string, - body: object -}) +client.ilm.getStatus(...) ---- -link:{ref}/put-trained-models.html[Documentation] + -[cols=2*] -|=== -|`model_id` or `modelId` -|`string` - The ID of the trained models to store -|`body` -|`object` - The trained model configuration +==== migrate_to_data_tiers +Migrates the indices and ILM policies away from custom node attribute allocation routing to data tiers routing -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-migrate-to-data-tiers.html[Endpoint documentation] +[source,ts] +---- +client.ilm.migrateToDataTiers(...) +---- -[discrete] -=== ml.putTrainedModelAlias +==== move_to_step +Manually moves an index into the specified step and executes that step. +https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-move-to-step.html[Endpoint documentation] [source,ts] ---- -client.ml.putTrainedModelAlias({ - model_alias: string, - model_id: string, - reassign: boolean -}) +client.ilm.moveToStep(...) ---- -link:{ref}/put-trained-models-aliases.html[Documentation] + -[cols=2*] -|=== -|`model_alias` or `modelAlias` -|`string` - The trained model alias to update - -|`model_id` or `modelId` -|`string` - The trained model where the model alias should be assigned -|`reassign` -|`boolean` - If the model_alias already exists and points to a separate model_id, this parameter must be true. Defaults to false. +==== put_lifecycle +Creates a lifecycle policy -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-put-lifecycle.html[Endpoint documentation] +[source,ts] +---- +client.ilm.putLifecycle(...) +---- -[discrete] -=== ml.resetJob +==== remove_policy +Removes the assigned lifecycle policy and stops managing the specified index +https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-remove-policy.html[Endpoint documentation] [source,ts] ---- -client.ml.resetJob({ - job_id: string, - wait_for_completion: boolean -}) +client.ilm.removePolicy(...) ---- -link:{ref}/ml-reset-job.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the job to reset -|`wait_for_completion` or `waitForCompletion` -|`boolean` - Should this request wait until the operation has completed before returning + -_Default:_ `true` +==== retry +Retries executing the policy for an index that is in the ERROR step. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-retry-policy.html[Endpoint documentation] +[source,ts] +---- +client.ilm.retry(...) +---- -[discrete] -=== ml.revertModelSnapshot +==== start +Start the index lifecycle management (ILM) plugin. +https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-start.html[Endpoint documentation] [source,ts] ---- -client.ml.revertModelSnapshot({ - job_id: string, - snapshot_id: string, - delete_intervening_results: boolean, - body: object -}) +client.ilm.start(...) ---- -link:{ref}/ml-revert-snapshot.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the job to fetch -|`snapshot_id` or `snapshotId` -|`string` - The ID of the snapshot to revert to +==== stop +Halts all lifecycle management operations and stops the index lifecycle management (ILM) plugin -|`delete_intervening_results` or `deleteInterveningResults` -|`boolean` - Should we reset the results back to the time of the snapshot? +https://www.elastic.co/guide/en/elasticsearch/reference/current/ilm-stop.html[Endpoint documentation] +[source,ts] +---- +client.ilm.stop(...) +---- -|`body` -|`object` - Reversion options +=== indices +==== add_block +Adds a block to an index. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/index-modules-blocks.html[Endpoint documentation] +[source,ts] +---- +client.indices.addBlock(...) +---- -[discrete] -=== ml.setUpgradeMode +==== analyze +Performs the analysis process on a text and return the tokens breakdown of the text. +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-analyze.html[Endpoint documentation] [source,ts] ---- -client.ml.setUpgradeMode({ - enabled: boolean, - timeout: string -}) +client.indices.analyze(...) ---- -link:{ref}/ml-set-upgrade-mode.html[Documentation] + -[cols=2*] -|=== -|`enabled` -|`boolean` - Whether to enable upgrade_mode ML setting or not. Defaults to false. -|`timeout` -|`string` - Controls the time to wait before action times out. Defaults to 30 seconds +==== clear_cache +Clears all or specific caches for one or more indices. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-clearcache.html[Endpoint documentation] +[source,ts] +---- +client.indices.clearCache(...) +---- -[discrete] -=== ml.startDataFrameAnalytics +==== clone +Clones an index +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-clone-index.html[Endpoint documentation] [source,ts] ---- -client.ml.startDataFrameAnalytics({ - id: string, - timeout: string, - body: object -}) +client.indices.clone(...) ---- -link:{ref}/start-dfanalytics.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the data frame analytics to start - -|`timeout` -|`string` - Controls the time to wait until the task has started. Defaults to 20 seconds -|`body` -|`object` - The start data frame analytics parameters +==== close +Closes an index. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-open-close.html[Endpoint documentation] +[source,ts] +---- +client.indices.close(...) +---- -[discrete] -=== ml.startDatafeed +==== create +Creates an index with optional settings and mappings. +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-create-index.html[Endpoint documentation] [source,ts] ---- -client.ml.startDatafeed({ - datafeed_id: string, - start: string, - end: string, - timeout: string, - body: object -}) +client.indices.create(...) ---- -link:{ref}/ml-start-datafeed.html[Documentation] + -[cols=2*] -|=== -|`datafeed_id` or `datafeedId` -|`string` - The ID of the datafeed to start -|`start` -|`string` - The start time from where the datafeed should begin +==== create_data_stream +Creates a data stream -|`end` -|`string` - The end time when the datafeed should stop. When not set, the datafeed continues in real time +https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams.html[Endpoint documentation] +[source,ts] +---- +client.indices.createDataStream(...) +---- -|`timeout` -|`string` - Controls the time to wait until a datafeed has started. Default to 20 seconds +==== data_streams_stats +Provides statistics on operations happening in a data stream. -|`body` -|`object` - The start datafeed parameters +https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams.html[Endpoint documentation] +[source,ts] +---- +client.indices.dataStreamsStats(...) +---- -|=== +==== delete +Deletes an index. -[discrete] -=== ml.startTrainedModelDeployment -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-delete-index.html[Endpoint documentation] [source,ts] ---- -client.ml.startTrainedModelDeployment({ - model_id: string, - timeout: string -}) +client.indices.delete(...) ---- -link:{ref}/start-trained-model-deployment.html[Documentation] + -[cols=2*] -|=== -|`model_id` or `modelId` -|`string` - The unique identifier of the trained model. -|`timeout` -|`string` - Controls the amount of time to wait for the model to deploy. + -_Default:_ `20s` +==== delete_alias +Deletes an alias. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-aliases.html[Endpoint documentation] +[source,ts] +---- +client.indices.deleteAlias(...) +---- -[discrete] -=== ml.stopDataFrameAnalytics +==== delete_data_stream +Deletes a data stream. +https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams.html[Endpoint documentation] [source,ts] ---- -client.ml.stopDataFrameAnalytics({ - id: string, - allow_no_match: boolean, - force: boolean, - timeout: string, - body: object -}) +client.indices.deleteDataStream(...) ---- -link:{ref}/stop-dfanalytics.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the data frame analytics to stop -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no data frame analytics. (This includes `_all` string or when no data frame analytics have been specified) +==== delete_index_template +Deletes an index template. -|`force` -|`boolean` - True if the data frame analytics should be forcefully stopped - -|`timeout` -|`string` - Controls the time to wait until the task has stopped. Defaults to 20 seconds +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-templates.html[Endpoint documentation] +[source,ts] +---- +client.indices.deleteIndexTemplate(...) +---- -|`body` -|`object` - The stop data frame analytics parameters +==== delete_template +Deletes an index template. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-templates.html[Endpoint documentation] +[source,ts] +---- +client.indices.deleteTemplate(...) +---- -[discrete] -=== ml.stopDatafeed +==== disk_usage +Analyzes the disk usage of each field of an index or data stream +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-disk-usage.html[Endpoint documentation] [source,ts] ---- -client.ml.stopDatafeed({ - datafeed_id: string, - allow_no_match: boolean, - allow_no_datafeeds: boolean, - force: boolean, - timeout: string, - body: object -}) +client.indices.diskUsage(...) ---- -link:{ref}/ml-stop-datafeed.html[Documentation] + -[cols=2*] -|=== -|`datafeed_id` or `datafeedId` -|`string` - The ID of the datafeed to stop -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no datafeeds. (This includes `_all` string or when no datafeeds have been specified) +==== exists +Returns information about whether a particular index exists. -|`allow_no_datafeeds` or `allowNoDatafeeds` -|`boolean` - Whether to ignore if a wildcard expression matches no datafeeds. (This includes `_all` string or when no datafeeds have been specified) + +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-exists.html[Endpoint documentation] +[source,ts] +---- +client.indices.exists(...) +---- -WARNING: This parameter has been deprecated. +==== exists_alias +Returns information about whether a particular alias exists. -|`force` -|`boolean` - True if the datafeed should be forcefully stopped. +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-aliases.html[Endpoint documentation] +[source,ts] +---- +client.indices.existsAlias(...) +---- -|`timeout` -|`string` - Controls the time to wait until a datafeed has stopped. Default to 20 seconds +==== exists_index_template +Returns information about whether a particular index template exists. -|`body` -|`object` - The URL params optionally sent in the body +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-templates.html[Endpoint documentation] +[source,ts] +---- +client.indices.existsIndexTemplate(...) +---- -|=== +==== exists_template +Returns information about whether a particular index template exists. -[discrete] -=== ml.stopTrainedModelDeployment -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-templates.html[Endpoint documentation] [source,ts] ---- -client.ml.stopTrainedModelDeployment({ - model_id: string -}) +client.indices.existsTemplate(...) ---- -link:{ref}/stop-trained-model-deployment.html[Documentation] + -[cols=2*] -|=== -|`model_id` or `modelId` -|`string` - The unique identifier of the trained model. -|=== - -[discrete] -=== ml.updateDataFrameAnalytics +==== field_usage_stats +Returns the field usage stats for each field of an index +https://www.elastic.co/guide/en/elasticsearch/reference/master/field-usage-stats.html[Endpoint documentation] [source,ts] ---- -client.ml.updateDataFrameAnalytics({ - id: string, - body: object -}) +client.indices.fieldUsageStats(...) ---- -link:{ref}/update-dfanalytics.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the data frame analytics to update -|`body` -|`object` - The data frame analytics settings to update +==== flush +Performs the flush operation on one or more indices. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-flush.html[Endpoint documentation] +[source,ts] +---- +client.indices.flush(...) +---- -[discrete] -=== ml.updateDatafeed +==== forcemerge +Performs the force merge operation on one or more indices. +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-forcemerge.html[Endpoint documentation] [source,ts] ---- -client.ml.updateDatafeed({ - datafeed_id: string, - ignore_unavailable: boolean, - allow_no_indices: boolean, - ignore_throttled: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - body: object -}) +client.indices.forcemerge(...) ---- -link:{ref}/ml-update-datafeed.html[Documentation] + -[cols=2*] -|=== -|`datafeed_id` or `datafeedId` -|`string` - The ID of the datafeed to update -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Ignore unavailable indexes (default: false) +==== get +Returns information about one or more indices. -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Ignore if the source indices expressions resolves to no concrete indices (default: true) +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-get-index.html[Endpoint documentation] +[source,ts] +---- +client.indices.get(...) +---- -|`ignore_throttled` or `ignoreThrottled` -|`boolean` - Ignore indices that are marked as throttled (default: true) +==== get_alias +Returns an alias. -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether source index expressions should get expanded to open or closed indices (default: open) +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-aliases.html[Endpoint documentation] +[source,ts] +---- +client.indices.getAlias(...) +---- -|`body` -|`object` - The datafeed update settings +==== get_data_stream +Returns data streams. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams.html[Endpoint documentation] +[source,ts] +---- +client.indices.getDataStream(...) +---- -[discrete] -=== ml.updateFilter +==== get_field_mapping +Returns mapping for one or more fields. +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-get-field-mapping.html[Endpoint documentation] [source,ts] ---- -client.ml.updateFilter({ - filter_id: string, - body: object -}) +client.indices.getFieldMapping(...) ---- -link:{ref}/ml-update-filter.html[Documentation] + -[cols=2*] -|=== -|`filter_id` or `filterId` -|`string` - The ID of the filter to update -|`body` -|`object` - The filter update +==== get_index_template +Returns an index template. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-templates.html[Endpoint documentation] +[source,ts] +---- +client.indices.getIndexTemplate(...) +---- -[discrete] -=== ml.updateJob +==== get_mapping +Returns mappings for one or more indices. +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-get-mapping.html[Endpoint documentation] [source,ts] ---- -client.ml.updateJob({ - job_id: string, - body: object -}) +client.indices.getMapping(...) ---- -link:{ref}/ml-update-job.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the job to create -|`body` -|`object` - The job update settings +==== get_settings +Returns settings for one or more indices. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-get-settings.html[Endpoint documentation] +[source,ts] +---- +client.indices.getSettings(...) +---- -[discrete] -=== ml.updateModelSnapshot +==== get_template +Returns an index template. +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-templates.html[Endpoint documentation] [source,ts] ---- -client.ml.updateModelSnapshot({ - job_id: string, - snapshot_id: string, - body: object -}) +client.indices.getTemplate(...) ---- -link:{ref}/ml-update-snapshot.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the job to fetch - -|`snapshot_id` or `snapshotId` -|`string` - The ID of the snapshot to update -|`body` -|`object` - The model snapshot properties to update +==== migrate_to_data_stream +Migrates an alias to a data stream -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams.html[Endpoint documentation] +[source,ts] +---- +client.indices.migrateToDataStream(...) +---- -[discrete] -=== ml.upgradeJobSnapshot +==== modify_data_stream +Modifies a data stream +https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams.html[Endpoint documentation] [source,ts] ---- -client.ml.upgradeJobSnapshot({ - job_id: string, - snapshot_id: string, - timeout: string, - wait_for_completion: boolean -}) +client.indices.modifyDataStream(...) ---- -link:{ref}/ml-upgrade-job-model-snapshot.html[Documentation] + -[cols=2*] -|=== -|`job_id` or `jobId` -|`string` - The ID of the job -|`snapshot_id` or `snapshotId` -|`string` - The ID of the snapshot +==== open +Opens an index. -|`timeout` -|`string` - How long should the API wait for the job to be opened and the old snapshot to be loaded. +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-open-close.html[Endpoint documentation] +[source,ts] +---- +client.indices.open(...) +---- -|`wait_for_completion` or `waitForCompletion` -|`boolean` - Should the request wait until the task is complete before responding to the caller. Default is false. +==== promote_data_stream +Promotes a data stream from a replicated data stream managed by CCR to a regular data stream -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams.html[Endpoint documentation] +[source,ts] +---- +client.indices.promoteDataStream(...) +---- -[discrete] -=== ml.validate +==== put_alias +Creates or updates an alias. +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-aliases.html[Endpoint documentation] [source,ts] ---- -client.ml.validate({ - body: object -}) +client.indices.putAlias(...) ---- -link:https://www.elastic.co/guide/en/machine-learning/current/ml-jobs.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - The job config - -|=== -[discrete] -=== ml.validateDetector +==== put_index_template +Creates or updates an index template. +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-templates.html[Endpoint documentation] [source,ts] ---- -client.ml.validateDetector({ - body: object -}) +client.indices.putIndexTemplate(...) ---- -link:https://www.elastic.co/guide/en/machine-learning/current/ml-jobs.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - The detector -|=== +==== put_mapping +Updates the index mappings. -[discrete] -=== monitoring.bulk -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-put-mapping.html[Endpoint documentation] [source,ts] ---- -client.monitoring.bulk({ - type: string, - system_id: string, - system_api_version: string, - interval: string, - body: object -}) +client.indices.putMapping(...) ---- -link:{ref}/monitor-elasticsearch-cluster.html[Documentation] + -[cols=2*] -|=== -|`type` -|`string` - Default document type for items which don't provide one + -WARNING: This parameter has been deprecated. +==== put_settings +Updates the index settings. -|`system_id` or `systemId` -|`string` - Identifier of the monitored system +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-update-settings.html[Endpoint documentation] +[source,ts] +---- +client.indices.putSettings(...) +---- -|`system_api_version` or `systemApiVersion` -|`string` - API Version of the monitored system +==== put_template +Creates or updates an index template. -|`interval` -|`string` - Collection interval (e.g., '10s' or '10000ms') of the payload +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-templates.html[Endpoint documentation] +[source,ts] +---- +client.indices.putTemplate(...) +---- -|`body` -|`object` - The operation definition and data (action-data pairs), separated by newlines +==== recovery +Returns information about ongoing index shard recoveries. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-recovery.html[Endpoint documentation] +[source,ts] +---- +client.indices.recovery(...) +---- -[discrete] -=== msearch +==== refresh +Performs the refresh operation in one or more indices. +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-refresh.html[Endpoint documentation] [source,ts] ---- -client.msearch({ - index: string | string[], - search_type: 'query_then_fetch' | 'dfs_query_then_fetch', - max_concurrent_searches: number, - typed_keys: boolean, - pre_filter_shard_size: number, - max_concurrent_shard_requests: number, - rest_total_hits_as_int: boolean, - ccs_minimize_roundtrips: boolean, - body: object -}) +client.indices.refresh(...) ---- -link:{ref}/search-multi-search.html[Documentation] + -{jsclient}/msearch_examples.html[Code Example] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to use as default - -|`search_type` or `searchType` -|`'query_then_fetch' \| 'dfs_query_then_fetch'` - Search operation type -|`max_concurrent_searches` or `maxConcurrentSearches` -|`number` - Controls the maximum number of concurrent searches the multi search api will execute +==== reload_search_analyzers +Reloads an index's search analyzers and their resources. -|`typed_keys` or `typedKeys` -|`boolean` - Specify whether aggregation and suggester names should be prefixed by their respective types in the response +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-reload-analyzers.html[Endpoint documentation] +[source,ts] +---- +client.indices.reloadSearchAnalyzers(...) +---- -|`pre_filter_shard_size` or `preFilterShardSize` -|`number` - A threshold that enforces a pre-filter roundtrip to prefilter search shards based on query rewriting if the number of shards the search request expands to exceeds the threshold. This filter roundtrip can limit the number of shards significantly if for instance a shard can not match any documents based on its rewrite method ie. if date filters are mandatory to match but the shard bounds and the query are disjoint. +==== resolve_index +Returns information about any matching indices, aliases, and data streams -|`max_concurrent_shard_requests` or `maxConcurrentShardRequests` -|`number` - The number of concurrent shard requests each sub search executes concurrently per node. This value should be used to limit the impact of the search on the cluster in order to limit the number of concurrent shard requests + -_Default:_ `5` +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-resolve-index-api.html[Endpoint documentation] +[source,ts] +---- +client.indices.resolveIndex(...) +---- -|`rest_total_hits_as_int` or `restTotalHitsAsInt` -|`boolean` - Indicates whether hits.total should be rendered as an integer or an object in the rest search response +==== rollover +Updates an alias to point to a new index when the existing index +is considered to be too large or too old. -|`ccs_minimize_roundtrips` or `ccsMinimizeRoundtrips` -|`boolean` - Indicates whether network round-trips should be minimized as part of cross-cluster search requests execution + -_Default:_ `true` +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-rollover-index.html[Endpoint documentation] +[source,ts] +---- +client.indices.rollover(...) +---- -|`body` -|`object` - The request definitions (metadata-search request definition pairs), separated by newlines +==== segments +Provides low-level information about segments in a Lucene index. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-segments.html[Endpoint documentation] +[source,ts] +---- +client.indices.segments(...) +---- -[discrete] -=== msearchTemplate +==== shard_stores +Provides store information for shard copies of indices. +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-shards-stores.html[Endpoint documentation] [source,ts] ---- -client.msearchTemplate({ - index: string | string[], - search_type: 'query_then_fetch' | 'dfs_query_then_fetch', - typed_keys: boolean, - max_concurrent_searches: number, - rest_total_hits_as_int: boolean, - ccs_minimize_roundtrips: boolean, - body: object -}) +client.indices.shardStores(...) ---- -link:{ref}/search-multi-search.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to use as default -|`search_type` or `searchType` -|`'query_then_fetch' \| 'dfs_query_then_fetch'` - Search operation type +==== shrink +Allow to shrink an existing index into a new index with fewer primary shards. -|`typed_keys` or `typedKeys` -|`boolean` - Specify whether aggregation and suggester names should be prefixed by their respective types in the response - -|`max_concurrent_searches` or `maxConcurrentSearches` -|`number` - Controls the maximum number of concurrent searches the multi search api will execute +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-shrink-index.html[Endpoint documentation] +[source,ts] +---- +client.indices.shrink(...) +---- -|`rest_total_hits_as_int` or `restTotalHitsAsInt` -|`boolean` - Indicates whether hits.total should be rendered as an integer or an object in the rest search response +==== simulate_index_template +Simulate matching the given index name against the index templates in the system -|`ccs_minimize_roundtrips` or `ccsMinimizeRoundtrips` -|`boolean` - Indicates whether network round-trips should be minimized as part of cross-cluster search requests execution + -_Default:_ `true` +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-templates.html[Endpoint documentation] +[source,ts] +---- +client.indices.simulateIndexTemplate(...) +---- -|`body` -|`object` - The request definitions (metadata-search request definition pairs), separated by newlines +==== simulate_template +Simulate resolving the given template name or body -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-templates.html[Endpoint documentation] +[source,ts] +---- +client.indices.simulateTemplate(...) +---- -[discrete] -=== mtermvectors +==== split +Allows you to split an existing index into a new index with more primary shards. +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-split-index.html[Endpoint documentation] [source,ts] ---- -client.mtermvectors({ - index: string, - ids: string | string[], - term_statistics: boolean, - field_statistics: boolean, - fields: string | string[], - offsets: boolean, - positions: boolean, - payloads: boolean, - preference: string, - routing: string, - realtime: boolean, - version: number, - version_type: 'internal' | 'external' | 'external_gte', - body: object -}) +client.indices.split(...) ---- -link:{ref}/docs-multi-termvectors.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The index in which the document resides. -|`ids` -|`string \| string[]` - A comma-separated list of documents ids. You must define ids as parameter or set "ids" or "docs" in the request body +==== stats +Provides statistics on operations happening in an index. -|`term_statistics` or `termStatistics` -|`boolean` - Specifies if total term frequency and document frequency should be returned. Applies to all returned documents unless otherwise specified in body "params" or "docs". - -|`field_statistics` or `fieldStatistics` -|`boolean` - Specifies if document count, sum of document frequencies and sum of total term frequencies should be returned. Applies to all returned documents unless otherwise specified in body "params" or "docs". + -_Default:_ `true` +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-stats.html[Endpoint documentation] +[source,ts] +---- +client.indices.stats(...) +---- -|`fields` -|`string \| string[]` - A comma-separated list of fields to return. Applies to all returned documents unless otherwise specified in body "params" or "docs". +==== unfreeze +Unfreezes an index. When a frozen index is unfrozen, the index goes through the normal recovery process and becomes writeable again. -|`offsets` -|`boolean` - Specifies if term offsets should be returned. Applies to all returned documents unless otherwise specified in body "params" or "docs". + -_Default:_ `true` +https://www.elastic.co/guide/en/elasticsearch/reference/current/unfreeze-index-api.html[Endpoint documentation] +[source,ts] +---- +client.indices.unfreeze(...) +---- -|`positions` -|`boolean` - Specifies if term positions should be returned. Applies to all returned documents unless otherwise specified in body "params" or "docs". + -_Default:_ `true` +==== update_aliases +Updates index aliases. -|`payloads` -|`boolean` - Specifies if term payloads should be returned. Applies to all returned documents unless otherwise specified in body "params" or "docs". + -_Default:_ `true` +https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-aliases.html[Endpoint documentation] +[source,ts] +---- +client.indices.updateAliases(...) +---- -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) .Applies to all returned documents unless otherwise specified in body "params" or "docs". +==== validate_query +Allows a user to validate a potentially expensive query without executing it. -|`routing` -|`string` - Specific routing value. Applies to all returned documents unless otherwise specified in body "params" or "docs". +https://www.elastic.co/guide/en/elasticsearch/reference/master/search-validate.html[Endpoint documentation] +[source,ts] +---- +client.indices.validateQuery(...) +---- -|`realtime` -|`boolean` - Specifies if requests are real-time as opposed to near-real-time (default: true). +=== ingest +==== delete_pipeline +Deletes a pipeline. -|`version` -|`number` - Explicit version number for concurrency control +https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-pipeline-api.html[Endpoint documentation] +[source,ts] +---- +client.ingest.deletePipeline(...) +---- -|`version_type` or `versionType` -|`'internal' \| 'external' \| 'external_gte'` - Specific version type +==== geo_ip_stats +Returns statistical information about geoip databases -|`body` -|`object` - Define ids, documents, parameters or a list of parameters per document here. You must at least provide a list of document ids. See documentation. +https://www.elastic.co/guide/en/elasticsearch/reference/master/geoip-stats-api.html[Endpoint documentation] +[source,ts] +---- +client.ingest.geoIpStats(...) +---- -|=== +==== get_pipeline +Returns a pipeline. -[discrete] -=== nodes.clearMeteringArchive -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/master/get-pipeline-api.html[Endpoint documentation] [source,ts] ---- -client.nodes.clearMeteringArchive({ - node_id: string | string[], - max_archive_version: number -}) +client.ingest.getPipeline(...) ---- -link:{ref}/clear-repositories-metering-archive-api.html[Documentation] + -[cols=2*] -|=== -|`node_id` or `nodeId` -|`string \| string[]` - Comma-separated list of node IDs or names used to limit returned information. - -|`max_archive_version` or `maxArchiveVersion` -|`number` - Specifies the maximum archive_version to be cleared from the archive. -|=== +==== processor_grok +Returns a list of the built-in patterns. -[discrete] -=== nodes.getMeteringInfo -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/master/grok-processor.html#grok-processor-rest-get[Endpoint documentation] [source,ts] ---- -client.nodes.getMeteringInfo({ - node_id: string | string[] -}) +client.ingest.processorGrok(...) ---- -link:{ref}/get-repositories-metering-api.html[Documentation] + -[cols=2*] -|=== -|`node_id` or `nodeId` -|`string \| string[]` - A comma-separated list of node IDs or names to limit the returned information. -|=== - -[discrete] -=== nodes.hotThreads +==== put_pipeline +Creates or updates a pipeline. +https://www.elastic.co/guide/en/elasticsearch/reference/master/put-pipeline-api.html[Endpoint documentation] [source,ts] ---- -client.nodes.hotThreads({ - node_id: string | string[], - interval: string, - snapshots: number, - threads: number, - ignore_idle_threads: boolean, - type: 'cpu' | 'wait' | 'block', - timeout: string -}) +client.ingest.putPipeline(...) ---- -link:{ref}/cluster-nodes-hot-threads.html[Documentation] + -[cols=2*] -|=== -|`node_id` or `nodeId` -|`string \| string[]` - A comma-separated list of node IDs or names to limit the returned information; use `_local` to return information from the node you're connecting to, leave empty to get information from all nodes - -|`interval` -|`string` - The interval for the second sampling of threads -|`snapshots` -|`number` - Number of samples of thread stacktrace (default: 10) +==== simulate +Allows to simulate a pipeline with example documents. -|`threads` -|`number` - Specify the number of threads to provide information for (default: 3) +https://www.elastic.co/guide/en/elasticsearch/reference/master/simulate-pipeline-api.html[Endpoint documentation] +[source,ts] +---- +client.ingest.simulate(...) +---- -|`ignore_idle_threads` or `ignoreIdleThreads` -|`boolean` - Don't show threads that are in known-idle places, such as waiting on a socket select or pulling from an empty task queue (default: true) +=== license +==== delete +Deletes licensing information for the cluster -|`type` -|`'cpu' \| 'wait' \| 'block'` - The type to sample (default: cpu) +https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-license.html[Endpoint documentation] +[source,ts] +---- +client.license.delete(...) +---- -|`timeout` -|`string` - Explicit operation timeout +==== get +Retrieves licensing information for the cluster -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/get-license.html[Endpoint documentation] +[source,ts] +---- +client.license.get(...) +---- -[discrete] -=== nodes.info +==== get_basic_status +Retrieves information about the status of the basic license. +https://www.elastic.co/guide/en/elasticsearch/reference/master/get-basic-status.html[Endpoint documentation] [source,ts] ---- -client.nodes.info({ - node_id: string | string[], - metric: string | string[], - flat_settings: boolean, - timeout: string -}) +client.license.getBasicStatus(...) ---- -link:{ref}/cluster-nodes-info.html[Documentation] + -[cols=2*] -|=== -|`node_id` or `nodeId` -|`string \| string[]` - A comma-separated list of node IDs or names to limit the returned information; use `_local` to return information from the node you're connecting to, leave empty to get information from all nodes -|`metric` -|`string \| string[]` - A comma-separated list of metrics you wish returned. Leave empty to return all. +==== get_trial_status +Retrieves information about the status of the trial license. -|`flat_settings` or `flatSettings` -|`boolean` - Return settings in flat format (default: false) +https://www.elastic.co/guide/en/elasticsearch/reference/master/get-trial-status.html[Endpoint documentation] +[source,ts] +---- +client.license.getTrialStatus(...) +---- -|`timeout` -|`string` - Explicit operation timeout +==== post +Updates the license for the cluster. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/update-license.html[Endpoint documentation] +[source,ts] +---- +client.license.post(...) +---- -[discrete] -=== nodes.reloadSecureSettings +==== post_start_basic +Starts an indefinite basic license. +https://www.elastic.co/guide/en/elasticsearch/reference/master/start-basic.html[Endpoint documentation] [source,ts] ---- -client.nodes.reloadSecureSettings({ - node_id: string | string[], - timeout: string, - body: object -}) +client.license.postStartBasic(...) ---- -link:{ref}/secure-settings.html#reloadable-secure-settings[Documentation] + -[cols=2*] -|=== -|`node_id` or `nodeId` -|`string \| string[]` - A comma-separated list of node IDs to span the reload/reinit call. Should stay empty because reloading usually involves all cluster nodes. - -|`timeout` -|`string` - Explicit operation timeout -|`body` -|`object` - An object containing the password for the elasticsearch keystore +==== post_start_trial +starts a limited time trial license. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/start-trial.html[Endpoint documentation] +[source,ts] +---- +client.license.postStartTrial(...) +---- -[discrete] -=== nodes.stats +=== logstash +==== delete_pipeline +Deletes Logstash Pipelines used by Central Management +https://www.elastic.co/guide/en/elasticsearch/reference/current/logstash-api-delete-pipeline.html[Endpoint documentation] [source,ts] ---- -client.nodes.stats({ - node_id: string | string[], - metric: string | string[], - index_metric: string | string[], - completion_fields: string | string[], - fielddata_fields: string | string[], - fields: string | string[], - groups: boolean, - level: 'indices' | 'node' | 'shards', - types: string | string[], - timeout: string, - include_segment_file_sizes: boolean, - include_unloaded_segments: boolean -}) +client.logstash.deletePipeline(...) ---- -link:{ref}/cluster-nodes-stats.html[Documentation] + -[cols=2*] -|=== -|`node_id` or `nodeId` -|`string \| string[]` - A comma-separated list of node IDs or names to limit the returned information; use `_local` to return information from the node you're connecting to, leave empty to get information from all nodes -|`metric` -|`string \| string[]` - Limit the information returned to the specified metrics +==== get_pipeline +Retrieves Logstash Pipelines used by Central Management -|`index_metric` or `indexMetric` -|`string \| string[]` - Limit the information returned for `indices` metric to the specific index metrics. Isn't used if `indices` (or `all`) metric isn't specified. +https://www.elastic.co/guide/en/elasticsearch/reference/current/logstash-api-get-pipeline.html[Endpoint documentation] +[source,ts] +---- +client.logstash.getPipeline(...) +---- -|`completion_fields` or `completionFields` -|`string \| string[]` - A comma-separated list of fields for the `completion` index metric (supports wildcards) +==== put_pipeline +Adds and updates Logstash Pipelines used for Central Management -|`fielddata_fields` or `fielddataFields` -|`string \| string[]` - A comma-separated list of fields for the `fielddata` index metric (supports wildcards) +https://www.elastic.co/guide/en/elasticsearch/reference/current/logstash-api-put-pipeline.html[Endpoint documentation] +[source,ts] +---- +client.logstash.putPipeline(...) +---- -|`fields` -|`string \| string[]` - A comma-separated list of fields for `fielddata` and `completion` index metric (supports wildcards) +=== migration +==== deprecations +Retrieves information about different cluster, node, and index level settings that use deprecated features that will be removed or changed in the next major version. -|`groups` -|`boolean` - A comma-separated list of search groups for `search` index metric +https://www.elastic.co/guide/en/elasticsearch/reference/current/migration-api-deprecation.html[Endpoint documentation] +[source,ts] +---- +client.migration.deprecations(...) +---- -|`level` -|`'indices' \| 'node' \| 'shards'` - Return indices stats aggregated at index, node or shard level + -_Default:_ `node` +==== get_feature_upgrade_status +Find out whether system features need to be upgraded or not -|`types` -|`string \| string[]` - A comma-separated list of document types for the `indexing` index metric +https://www.elastic.co/guide/en/elasticsearch/reference/current/migration-api-feature-upgrade.html[Endpoint documentation] +[source,ts] +---- +client.migration.getFeatureUpgradeStatus(...) +---- -|`timeout` -|`string` - Explicit operation timeout +==== post_feature_upgrade +Begin upgrades for system features -|`include_segment_file_sizes` or `includeSegmentFileSizes` -|`boolean` - Whether to report the aggregated disk usage of each one of the Lucene index files (only applies if segment stats are requested) +https://www.elastic.co/guide/en/elasticsearch/reference/current/migration-api-feature-upgrade.html[Endpoint documentation] +[source,ts] +---- +client.migration.postFeatureUpgrade(...) +---- -|`include_unloaded_segments` or `includeUnloadedSegments` -|`boolean` - If set to true segment stats will include stats for segments that are not currently loaded into memory +=== ml +==== close_job +Closes one or more anomaly detection jobs. A job can be opened and closed multiple times throughout its lifecycle. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-close-job.html[Endpoint documentation] +[source,ts] +---- +client.ml.closeJob(...) +---- -[discrete] -=== nodes.usage +==== delete_calendar +Deletes a calendar. +https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-delete-calendar.html[Endpoint documentation] [source,ts] ---- -client.nodes.usage({ - node_id: string | string[], - metric: string | string[], - timeout: string -}) +client.ml.deleteCalendar(...) ---- -link:{ref}/cluster-nodes-usage.html[Documentation] + -[cols=2*] -|=== -|`node_id` or `nodeId` -|`string \| string[]` - A comma-separated list of node IDs or names to limit the returned information; use `_local` to return information from the node you're connecting to, leave empty to get information from all nodes - -|`metric` -|`string \| string[]` - Limit the information returned to the specified metrics -|`timeout` -|`string` - Explicit operation timeout +==== delete_calendar_event +Deletes scheduled events from a calendar. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-delete-calendar-event.html[Endpoint documentation] +[source,ts] +---- +client.ml.deleteCalendarEvent(...) +---- -[discrete] -=== openPointInTime +==== delete_calendar_job +Deletes anomaly detection jobs from a calendar. +https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-delete-calendar-job.html[Endpoint documentation] [source,ts] ---- -client.openPointInTime({ - index: string | string[], - preference: string, - routing: string, - ignore_unavailable: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - keep_alive: string -}) +client.ml.deleteCalendarJob(...) ---- -link:{ref}/point-in-time-api.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to open point in time; use `_all` or empty string to perform the operation on all indices -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) +==== delete_data_frame_analytics +Deletes an existing data frame analytics job. -|`routing` -|`string` - Specific routing value +https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-dfanalytics.html[Endpoint documentation] +[source,ts] +---- +client.ml.deleteDataFrameAnalytics(...) +---- -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) +==== delete_datafeed +Deletes an existing datafeed. -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` +https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-delete-datafeed.html[Endpoint documentation] +[source,ts] +---- +client.ml.deleteDatafeed(...) +---- -|`keep_alive` or `keepAlive` -|`string` - Specific the time to live for the point in time +==== delete_expired_data +Deletes expired and unused machine learning data. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-delete-expired-data.html[Endpoint documentation] +[source,ts] +---- +client.ml.deleteExpiredData(...) +---- -[discrete] -=== ping +==== delete_filter +Deletes a filter. +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-delete-filter.html[Endpoint documentation] [source,ts] ---- -client.ping() +client.ml.deleteFilter(...) ---- -link:{ref}/index.html[Documentation] + +==== delete_forecast +Deletes forecasts from a machine learning job. -[discrete] -=== putScript - +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-delete-forecast.html[Endpoint documentation] [source,ts] ---- -client.putScript({ - id: string, - context: string, - timeout: string, - master_timeout: string, - body: object -}) +client.ml.deleteForecast(...) ---- -link:{ref}/modules-scripting.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - Script ID -|`context` -|`string` - Script context +==== delete_job +Deletes an existing anomaly detection job. -|`timeout` -|`string` - Explicit operation timeout +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-delete-job.html[Endpoint documentation] +[source,ts] +---- +client.ml.deleteJob(...) +---- -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for connection to master +==== delete_model_snapshot +Deletes an existing model snapshot. -|`body` -|`object` - The document +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-delete-snapshot.html[Endpoint documentation] +[source,ts] +---- +client.ml.deleteModelSnapshot(...) +---- -|=== +==== delete_trained_model +Deletes an existing trained inference model that is currently not referenced by an ingest pipeline. -[discrete] -=== rankEval -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/delete-trained-models.html[Endpoint documentation] [source,ts] ---- -client.rankEval({ - index: string | string[], - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - search_type: 'query_then_fetch' | 'dfs_query_then_fetch', - body: object -}) +client.ml.deleteTrainedModel(...) ---- -link:{ref}/search-rank-eval.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to search; use `_all` or empty string to perform the operation on all indices -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) +==== delete_trained_model_alias +Deletes a model alias that refers to the trained model -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) +https://www.elastic.co/guide/en/elasticsearch/reference/current/delete-trained-models-aliases.html[Endpoint documentation] +[source,ts] +---- +client.ml.deleteTrainedModelAlias(...) +---- -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` +==== estimate_model_memory +Estimates the model memory -|`search_type` or `searchType` -|`'query_then_fetch' \| 'dfs_query_then_fetch'` - Search operation type +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-apis.html[Endpoint documentation] +[source,ts] +---- +client.ml.estimateModelMemory(...) +---- -|`body` -|`object` - The ranking evaluation search definition, including search requests, document ratings and ranking metric definition. +==== evaluate_data_frame +Evaluates the data frame analytics for an annotated index. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/evaluate-dfanalytics.html[Endpoint documentation] +[source,ts] +---- +client.ml.evaluateDataFrame(...) +---- -[discrete] -=== reindex +==== explain_data_frame_analytics +Explains a data frame analytics config. +http://www.elastic.co/guide/en/elasticsearch/reference/current/explain-dfanalytics.html[Endpoint documentation] [source,ts] ---- -client.reindex({ - refresh: boolean, - timeout: string, - wait_for_active_shards: string, - wait_for_completion: boolean, - requests_per_second: number, - scroll: string, - slices: number|string, - max_docs: number, - body: object -}) +client.ml.explainDataFrameAnalytics(...) ---- -link:{ref}/docs-reindex.html[Documentation] + -{jsclient}/reindex_examples.html[Code Example] + -[cols=2*] -|=== -|`refresh` -|`boolean` - Should the affected indexes be refreshed? -|`timeout` -|`string` - Time each individual bulk request should wait for shards that are unavailable. + -_Default:_ `1m` +==== flush_job +Forces any buffered data to be processed by the job. -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Sets the number of shard copies that must be active before proceeding with the reindex operation. Defaults to 1, meaning the primary shard only. Set to `all` for all shard copies, otherwise set to any non-negative value less than or equal to the total number of copies for the shard (number of replicas + 1) - -|`wait_for_completion` or `waitForCompletion` -|`boolean` - Should the request should block until the reindex is complete. + -_Default:_ `true` +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-flush-job.html[Endpoint documentation] +[source,ts] +---- +client.ml.flushJob(...) +---- -|`requests_per_second` or `requestsPerSecond` -|`number` - The throttle to set on this request in sub-requests per second. -1 means no throttle. +==== forecast +Predicts the future behavior of a time series by using its historical behavior. -|`scroll` -|`string` - Control how long to keep the search context alive + -_Default:_ `5m` +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-forecast.html[Endpoint documentation] +[source,ts] +---- +client.ml.forecast(...) +---- -|`slices` -|`number\|string` - The number of slices this task should be divided into. Defaults to 1, meaning the task isn't sliced into subtasks. Can be set to `auto`. + -_Default:_ `1` +==== get_buckets +Retrieves anomaly detection job results for one or more buckets. -|`max_docs` or `maxDocs` -|`number` - Maximum number of documents to process (default: all documents) +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-bucket.html[Endpoint documentation] +[source,ts] +---- +client.ml.getBuckets(...) +---- -|`body` -|`object` - The search definition using the Query DSL and the prototype for the index request. +==== get_calendar_events +Retrieves information about the scheduled events in calendars. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-calendar-event.html[Endpoint documentation] +[source,ts] +---- +client.ml.getCalendarEvents(...) +---- -[discrete] -=== reindexRethrottle +==== get_calendars +Retrieves configuration information for calendars. +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-calendar.html[Endpoint documentation] [source,ts] ---- -client.reindexRethrottle({ - task_id: string, - requests_per_second: number -}) +client.ml.getCalendars(...) ---- -link:{ref}/docs-reindex.html[Documentation] + -[cols=2*] -|=== -|`task_id` or `taskId` -|`string` - The task id to rethrottle -|`requests_per_second` or `requestsPerSecond` -|`number` - The throttle to set on this request in floating sub-requests per second. -1 means set no throttle. +==== get_categories +Retrieves anomaly detection job results for one or more categories. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-category.html[Endpoint documentation] +[source,ts] +---- +client.ml.getCategories(...) +---- -[discrete] -=== renderSearchTemplate +==== get_data_frame_analytics +Retrieves configuration information for data frame analytics jobs. +https://www.elastic.co/guide/en/elasticsearch/reference/current/get-dfanalytics.html[Endpoint documentation] [source,ts] ---- -client.renderSearchTemplate({ - id: string, - body: object -}) +client.ml.getDataFrameAnalytics(...) ---- -link:{ref}/render-search-template-api.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The id of the stored search template -|`body` -|`object` - The search definition template and its params +==== get_data_frame_analytics_stats +Retrieves usage information for data frame analytics jobs. -|=== - -[discrete] -=== rollup.deleteJob -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/get-dfanalytics-stats.html[Endpoint documentation] [source,ts] ---- -client.rollup.deleteJob({ - id: string -}) +client.ml.getDataFrameAnalyticsStats(...) ---- -link:{ref}/rollup-delete-job.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the job to delete -|=== +==== get_datafeed_stats +Retrieves usage information for datafeeds. -[discrete] -=== rollup.getJobs -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-datafeed-stats.html[Endpoint documentation] [source,ts] ---- -client.rollup.getJobs({ - id: string -}) +client.ml.getDatafeedStats(...) ---- -link:{ref}/rollup-get-job.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the job(s) to fetch. Accepts glob patterns, or left blank for all jobs -|=== +==== get_datafeeds +Retrieves configuration information for datafeeds. -[discrete] -=== rollup.getRollupCaps -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-datafeed.html[Endpoint documentation] [source,ts] ---- -client.rollup.getRollupCaps({ - id: string -}) +client.ml.getDatafeeds(...) ---- -link:{ref}/rollup-get-rollup-caps.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the index to check rollup capabilities on, or left blank for all jobs -|=== +==== get_filters +Retrieves filters. -[discrete] -=== rollup.getRollupIndexCaps -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-filter.html[Endpoint documentation] [source,ts] ---- -client.rollup.getRollupIndexCaps({ - index: string -}) +client.ml.getFilters(...) ---- -link:{ref}/rollup-get-rollup-index-caps.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The rollup index or index pattern to obtain rollup capabilities from. -|=== +==== get_influencers +Retrieves anomaly detection job results for one or more influencers. -[discrete] -=== rollup.putJob -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-influencer.html[Endpoint documentation] [source,ts] ---- -client.rollup.putJob({ - id: string, - body: object -}) +client.ml.getInfluencers(...) ---- -link:{ref}/rollup-put-job.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the job to create - -|`body` -|`object` - The job configuration -|=== +==== get_job_stats +Retrieves usage information for anomaly detection jobs. -[discrete] -=== rollup.rollup -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-job-stats.html[Endpoint documentation] [source,ts] ---- -client.rollup.rollup({ - index: string, - rollup_index: string, - body: object -}) +client.ml.getJobStats(...) ---- -link:{ref}/xpack-rollup.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The index to roll up -|`rollup_index` or `rollupIndex` -|`string` - The name of the rollup index to create +==== get_jobs +Retrieves configuration information for anomaly detection jobs. -|`body` -|`object` - The rollup configuration +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-job.html[Endpoint documentation] +[source,ts] +---- +client.ml.getJobs(...) +---- -|=== +==== get_memory_stats +Returns information on how ML is using memory. -[discrete] -=== rollup.rollupSearch -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/get-ml-memory.html[Endpoint documentation] [source,ts] ---- -client.rollup.rollupSearch({ - index: string | string[], - type: string, - typed_keys: boolean, - rest_total_hits_as_int: boolean, - body: object -}) +client.ml.getMemoryStats(...) ---- -link:{ref}/rollup-search.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - The indices or index-pattern(s) (containing rollup or regular data) that should be searched - -|`type` -|`string` - The doc type inside the index + -WARNING: This parameter has been deprecated. +==== get_model_snapshot_upgrade_stats +Gets stats for anomaly detection job model snapshot upgrades that are in progress. -|`typed_keys` or `typedKeys` -|`boolean` - Specify whether aggregation and suggester names should be prefixed by their respective types in the response +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-job-model-snapshot-upgrade-stats.html[Endpoint documentation] +[source,ts] +---- +client.ml.getModelSnapshotUpgradeStats(...) +---- -|`rest_total_hits_as_int` or `restTotalHitsAsInt` -|`boolean` - Indicates whether hits.total should be rendered as an integer or an object in the rest search response +==== get_model_snapshots +Retrieves information about model snapshots. -|`body` -|`object` - The search request body +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-snapshot.html[Endpoint documentation] +[source,ts] +---- +client.ml.getModelSnapshots(...) +---- -|=== +==== get_overall_buckets +Retrieves overall bucket results that summarize the bucket results of multiple anomaly detection jobs. -[discrete] -=== rollup.startJob -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-overall-buckets.html[Endpoint documentation] [source,ts] ---- -client.rollup.startJob({ - id: string -}) +client.ml.getOverallBuckets(...) ---- -link:{ref}/rollup-start-job.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the job to start -|=== +==== get_records +Retrieves anomaly records for an anomaly detection job. -[discrete] -=== rollup.stopJob -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-get-record.html[Endpoint documentation] [source,ts] ---- -client.rollup.stopJob({ - id: string, - wait_for_completion: boolean, - timeout: string -}) +client.ml.getRecords(...) ---- -link:{ref}/rollup-stop-job.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The ID of the job to stop -|`wait_for_completion` or `waitForCompletion` -|`boolean` - True if the API should block until the job has fully stopped, false if should be executed async. Defaults to false. - -|`timeout` -|`string` - Block for (at maximum) the specified duration while waiting for the job to stop. Defaults to 30s. - -|=== - -[discrete] -=== scriptsPainlessExecute -*Stability:* experimental -[source,ts] ----- -client.scriptsPainlessExecute({ - body: object -}) ----- -link:https://www.elastic.co/guide/en/elasticsearch/painless/master/painless-execute-api.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - The script to execute - -|=== - -[discrete] -=== scroll - -[source,ts] ----- -client.scroll({ - scroll_id: string, - scroll: string, - rest_total_hits_as_int: boolean, - body: object -}) ----- -link:{ref}/search-request-body.html#request-body-search-scroll[Documentation] + -{jsclient}/scroll_examples.html[Code Example] + -[cols=2*] -|=== -|`scroll_id` or `scrollId` -|`string` - The scroll ID + - -WARNING: This parameter has been deprecated. - -|`scroll` -|`string` - Specify how long a consistent view of the index should be maintained for scrolled search - -|`rest_total_hits_as_int` or `restTotalHitsAsInt` -|`boolean` - Indicates whether hits.total should be rendered as an integer or an object in the rest search response - -|`body` -|`object` - The scroll ID if not passed by URL or query parameter. - -|=== - -[discrete] -=== search - -[source,ts] ----- -client.search({ - index: string | string[], - analyzer: string, - analyze_wildcard: boolean, - ccs_minimize_roundtrips: boolean, - default_operator: 'AND' | 'OR', - df: string, - explain: boolean, - stored_fields: string | string[], - docvalue_fields: string | string[], - from: number, - ignore_unavailable: boolean, - ignore_throttled: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - lenient: boolean, - preference: string, - q: string, - routing: string | string[], - scroll: string, - search_type: 'query_then_fetch' | 'dfs_query_then_fetch', - size: number, - sort: string | string[], - _source: string | string[], - _source_excludes: string | string[], - _source_includes: string | string[], - terminate_after: number, - stats: string | string[], - suggest_field: string, - suggest_mode: 'missing' | 'popular' | 'always', - suggest_size: number, - suggest_text: string, - timeout: string, - track_scores: boolean, - track_total_hits: boolean|long, - allow_partial_search_results: boolean, - typed_keys: boolean, - version: boolean, - seq_no_primary_term: boolean, - request_cache: boolean, - batched_reduce_size: number, - max_concurrent_shard_requests: number, - pre_filter_shard_size: number, - rest_total_hits_as_int: boolean, - min_compatible_shard_node: string, - body: object -}) ----- -link:{ref}/search-search.html[Documentation] + -{jsclient}/search_examples.html[Code Example] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to search; use `_all` or empty string to perform the operation on all indices +==== get_trained_models +Retrieves configuration information for a trained inference model. -|`analyzer` -|`string` - The analyzer to use for the query string +https://www.elastic.co/guide/en/elasticsearch/reference/current/get-trained-models.html[Endpoint documentation] +[source,ts] +---- +client.ml.getTrainedModels(...) +---- -|`analyze_wildcard` or `analyzeWildcard` -|`boolean` - Specify whether wildcard and prefix queries should be analyzed (default: false) +==== get_trained_models_stats +Retrieves usage information for trained inference models. -|`ccs_minimize_roundtrips` or `ccsMinimizeRoundtrips` -|`boolean` - Indicates whether network round-trips should be minimized as part of cross-cluster search requests execution + -_Default:_ `true` +https://www.elastic.co/guide/en/elasticsearch/reference/current/get-trained-models-stats.html[Endpoint documentation] +[source,ts] +---- +client.ml.getTrainedModelsStats(...) +---- -|`default_operator` or `defaultOperator` -|`'AND' \| 'OR'` - The default operator for query string query (AND or OR) + -_Default:_ `OR` - -|`df` -|`string` - The field to use as default where no field prefix is given in the query string - -|`explain` -|`boolean` - Specify whether to return detailed information about score computation as part of a hit +==== infer_trained_model_deployment +Evaluate a trained model. -|`stored_fields` or `storedFields` -|`string \| string[]` - A comma-separated list of stored fields to return as part of a hit +https://www.elastic.co/guide/en/elasticsearch/reference/master/infer-trained-model-deployment.html[Endpoint documentation] +[source,ts] +---- +client.ml.inferTrainedModelDeployment(...) +---- -|`docvalue_fields` or `docvalueFields` -|`string \| string[]` - A comma-separated list of fields to return as the docvalue representation of a field for each hit +==== info +Returns defaults and limits used by machine learning. -|`from` -|`number` - Starting offset (default: 0) +https://www.elastic.co/guide/en/elasticsearch/reference/current/get-ml-info.html[Endpoint documentation] +[source,ts] +---- +client.ml.info(...) +---- -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) +==== open_job +Opens one or more anomaly detection jobs. -|`ignore_throttled` or `ignoreThrottled` -|`boolean` - Whether specified concrete, expanded or aliased indices should be ignored when throttled +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-open-job.html[Endpoint documentation] +[source,ts] +---- +client.ml.openJob(...) +---- -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) +==== post_calendar_events +Posts scheduled events in a calendar. -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-post-calendar-event.html[Endpoint documentation] +[source,ts] +---- +client.ml.postCalendarEvents(...) +---- -|`lenient` -|`boolean` - Specify whether format-based query failures (such as providing text to a numeric field) should be ignored - -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) - -|`q` -|`string` - Query in the Lucene query string syntax - -|`routing` -|`string \| string[]` - A comma-separated list of specific routing values - -|`scroll` -|`string` - Specify how long a consistent view of the index should be maintained for scrolled search - -|`search_type` or `searchType` -|`'query_then_fetch' \| 'dfs_query_then_fetch'` - Search operation type +==== post_data +Sends data to an anomaly detection job for analysis. -|`size` -|`number` - Number of hits to return (default: 10) +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-post-data.html[Endpoint documentation] +[source,ts] +---- +client.ml.postData(...) +---- -|`sort` -|`string \| string[]` - A comma-separated list of : pairs +==== preview_data_frame_analytics +Previews that will be analyzed given a data frame analytics config. -|`_source` -|`string \| string[]` - True or false to return the _source field or not, or a list of fields to return +http://www.elastic.co/guide/en/elasticsearch/reference/current/preview-dfanalytics.html[Endpoint documentation] +[source,ts] +---- +client.ml.previewDataFrameAnalytics(...) +---- -|`_source_excludes` or `_sourceExcludes` -|`string \| string[]` - A list of fields to exclude from the returned _source field +==== preview_datafeed +Previews a datafeed. -|`_source_includes` or `_sourceIncludes` -|`string \| string[]` - A list of fields to extract and return from the _source field +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-preview-datafeed.html[Endpoint documentation] +[source,ts] +---- +client.ml.previewDatafeed(...) +---- -|`terminate_after` or `terminateAfter` -|`number` - The maximum number of documents to collect for each shard, upon reaching which the query execution will terminate early. +==== put_calendar +Instantiates a calendar. -|`stats` -|`string \| string[]` - Specific 'tag' of the request for logging and statistical purposes +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-put-calendar.html[Endpoint documentation] +[source,ts] +---- +client.ml.putCalendar(...) +---- -|`suggest_field` or `suggestField` -|`string` - Specify which field to use for suggestions +==== put_calendar_job +Adds an anomaly detection job to a calendar. -|`suggest_mode` or `suggestMode` -|`'missing' \| 'popular' \| 'always'` - Specify suggest mode + -_Default:_ `missing` +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-put-calendar-job.html[Endpoint documentation] +[source,ts] +---- +client.ml.putCalendarJob(...) +---- -|`suggest_size` or `suggestSize` -|`number` - How many suggestions to return in response +==== put_data_frame_analytics +Instantiates a data frame analytics job. -|`suggest_text` or `suggestText` -|`string` - The source text for which the suggestions should be returned +https://www.elastic.co/guide/en/elasticsearch/reference/master/put-dfanalytics.html[Endpoint documentation] +[source,ts] +---- +client.ml.putDataFrameAnalytics(...) +---- -|`timeout` -|`string` - Explicit operation timeout +==== put_datafeed +Instantiates a datafeed. -|`track_scores` or `trackScores` -|`boolean` - Whether to calculate and return scores even if they are not used for sorting +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-put-datafeed.html[Endpoint documentation] +[source,ts] +---- +client.ml.putDatafeed(...) +---- -|`track_total_hits` or `trackTotalHits` -|`boolean\|long` - Indicate if the number of documents that match the query should be tracked. A number can also be specified, to accurately track the total hit count up to the number. +==== put_filter +Instantiates a filter. -|`allow_partial_search_results` or `allowPartialSearchResults` -|`boolean` - Indicate if an error should be returned if there is a partial search failure or timeout + -_Default:_ `true` +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-put-filter.html[Endpoint documentation] +[source,ts] +---- +client.ml.putFilter(...) +---- -|`typed_keys` or `typedKeys` -|`boolean` - Specify whether aggregation and suggester names should be prefixed by their respective types in the response +==== put_job +Instantiates an anomaly detection job. -|`version` -|`boolean` - Specify whether to return document version as part of a hit +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-put-job.html[Endpoint documentation] +[source,ts] +---- +client.ml.putJob(...) +---- -|`seq_no_primary_term` or `seqNoPrimaryTerm` -|`boolean` - Specify whether to return sequence number and primary term of the last modification of each hit +==== put_trained_model +Creates an inference trained model. -|`request_cache` or `requestCache` -|`boolean` - Specify if request cache should be used for this request or not, defaults to index level setting +https://www.elastic.co/guide/en/elasticsearch/reference/current/put-trained-models.html[Endpoint documentation] +[source,ts] +---- +client.ml.putTrainedModel(...) +---- -|`batched_reduce_size` or `batchedReduceSize` -|`number` - The number of shard results that should be reduced at once on the coordinating node. This value should be used as a protection mechanism to reduce the memory overhead per search request if the potential number of shards in the request can be large. + -_Default:_ `512` +==== put_trained_model_alias +Creates a new model alias (or reassigns an existing one) to refer to the trained model -|`max_concurrent_shard_requests` or `maxConcurrentShardRequests` -|`number` - The number of concurrent shard requests per node this search executes concurrently. This value should be used to limit the impact of the search on the cluster in order to limit the number of concurrent shard requests + -_Default:_ `5` +https://www.elastic.co/guide/en/elasticsearch/reference/current/put-trained-models-aliases.html[Endpoint documentation] +[source,ts] +---- +client.ml.putTrainedModelAlias(...) +---- -|`pre_filter_shard_size` or `preFilterShardSize` -|`number` - A threshold that enforces a pre-filter roundtrip to prefilter search shards based on query rewriting if the number of shards the search request expands to exceeds the threshold. This filter roundtrip can limit the number of shards significantly if for instance a shard can not match any documents based on its rewrite method ie. if date filters are mandatory to match but the shard bounds and the query are disjoint. +==== put_trained_model_definition_part +Creates part of a trained model definition -|`rest_total_hits_as_int` or `restTotalHitsAsInt` -|`boolean` - Indicates whether hits.total should be rendered as an integer or an object in the rest search response +https://www.elastic.co/guide/en/elasticsearch/reference/current/put-trained-model-definition-part.html[Endpoint documentation] +[source,ts] +---- +client.ml.putTrainedModelDefinitionPart(...) +---- -|`min_compatible_shard_node` or `minCompatibleShardNode` -|`string` - The minimum compatible version that all shards involved in search should have for this request to be successful +==== put_trained_model_vocabulary +Creates a trained model vocabulary -|`body` -|`object` - The search definition using the Query DSL +https://www.elastic.co/guide/en/elasticsearch/reference/current/put-trained-model-vocabulary.html[Endpoint documentation] +[source,ts] +---- +client.ml.putTrainedModelVocabulary(...) +---- -|=== +==== reset_job +Resets an existing anomaly detection job. -[discrete] -=== searchMvt -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-reset-job.html[Endpoint documentation] [source,ts] ---- -client.searchMvt({ - index: string | string[], - field: string, - zoom: number, - x: number, - y: number, - exact_bounds: boolean, - extent: number, - grid_precision: number, - grid_type: 'grid' | 'point', - size: number, - body: object -}) +client.ml.resetJob(...) ---- -link:{ref}/search-vector-tile-api.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - Comma-separated list of data streams, indices, or aliases to search - -|`field` -|`string` - Field containing geospatial data to return -|`zoom` -|`number` - Zoom level for the vector tile to search +==== revert_model_snapshot +Reverts to a specific snapshot. -|`x` -|`number` - X coordinate for the vector tile to search +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-revert-snapshot.html[Endpoint documentation] +[source,ts] +---- +client.ml.revertModelSnapshot(...) +---- -|`y` -|`number` - Y coordinate for the vector tile to search +==== set_upgrade_mode +Sets a cluster wide upgrade_mode setting that prepares machine learning indices for an upgrade. -|`exact_bounds` or `exactBounds` -|`boolean` - If false, the meta layer's feature is the bounding box of the tile. If true, the meta layer's feature is a bounding box resulting from a `geo_bounds` aggregation. +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-set-upgrade-mode.html[Endpoint documentation] +[source,ts] +---- +client.ml.setUpgradeMode(...) +---- -|`extent` -|`number` - Size, in pixels, of a side of the vector tile. + -_Default:_ `4096` +==== start_data_frame_analytics +Starts a data frame analytics job. -|`grid_precision` or `gridPrecision` -|`number` - Additional zoom levels available through the aggs layer. Accepts 0-8. + -_Default:_ `8` +https://www.elastic.co/guide/en/elasticsearch/reference/current/start-dfanalytics.html[Endpoint documentation] +[source,ts] +---- +client.ml.startDataFrameAnalytics(...) +---- -|`grid_type` or `gridType` -|`'grid' \| 'point'` - Determines the geometry type for features in the aggs layer. + -_Default:_ `grid` +==== start_datafeed +Starts one or more datafeeds. -|`size` -|`number` - Maximum number of features to return in the hits layer. Accepts 0-10000. + -_Default:_ `10000` +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-start-datafeed.html[Endpoint documentation] +[source,ts] +---- +client.ml.startDatafeed(...) +---- -|`body` -|`object` - Search request body. +==== start_trained_model_deployment +Start a trained model deployment. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/start-trained-model-deployment.html[Endpoint documentation] +[source,ts] +---- +client.ml.startTrainedModelDeployment(...) +---- -[discrete] -=== searchShards +==== stop_data_frame_analytics +Stops one or more data frame analytics jobs. +https://www.elastic.co/guide/en/elasticsearch/reference/current/stop-dfanalytics.html[Endpoint documentation] [source,ts] ---- -client.searchShards({ - index: string | string[], - preference: string, - routing: string, - local: boolean, - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all' -}) +client.ml.stopDataFrameAnalytics(...) ---- -link:{ref}/search-shards.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to search; use `_all` or empty string to perform the operation on all indices - -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) -|`routing` -|`string` - Specific routing value +==== stop_datafeed +Stops one or more datafeeds. -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-stop-datafeed.html[Endpoint documentation] +[source,ts] +---- +client.ml.stopDatafeed(...) +---- -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) +==== stop_trained_model_deployment +Stop a trained model deployment. -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) +https://www.elastic.co/guide/en/elasticsearch/reference/master/stop-trained-model-deployment.html[Endpoint documentation] +[source,ts] +---- +client.ml.stopTrainedModelDeployment(...) +---- -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` +==== update_data_frame_analytics +Updates certain properties of a data frame analytics job. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/update-dfanalytics.html[Endpoint documentation] +[source,ts] +---- +client.ml.updateDataFrameAnalytics(...) +---- -[discrete] -=== searchTemplate +==== update_datafeed +Updates certain properties of a datafeed. +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-update-datafeed.html[Endpoint documentation] [source,ts] ---- -client.searchTemplate({ - index: string | string[], - ignore_unavailable: boolean, - ignore_throttled: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - preference: string, - routing: string | string[], - scroll: string, - search_type: 'query_then_fetch' | 'dfs_query_then_fetch', - explain: boolean, - profile: boolean, - typed_keys: boolean, - rest_total_hits_as_int: boolean, - ccs_minimize_roundtrips: boolean, - body: object -}) +client.ml.updateDatafeed(...) ---- -link:{ref}/search-template.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to search; use `_all` or empty string to perform the operation on all indices -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) +==== update_filter +Updates the description of a filter, adds items, or removes items. -|`ignore_throttled` or `ignoreThrottled` -|`boolean` - Whether specified concrete, expanded or aliased indices should be ignored when throttled +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-update-filter.html[Endpoint documentation] +[source,ts] +---- +client.ml.updateFilter(...) +---- -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) +==== update_job +Updates certain properties of an anomaly detection job. -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-update-job.html[Endpoint documentation] +[source,ts] +---- +client.ml.updateJob(...) +---- -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) +==== update_model_snapshot +Updates certain properties of a snapshot. -|`routing` -|`string \| string[]` - A comma-separated list of specific routing values +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-update-snapshot.html[Endpoint documentation] +[source,ts] +---- +client.ml.updateModelSnapshot(...) +---- -|`scroll` -|`string` - Specify how long a consistent view of the index should be maintained for scrolled search +==== upgrade_job_snapshot +Upgrades a given job snapshot to the current major version. -|`search_type` or `searchType` -|`'query_then_fetch' \| 'dfs_query_then_fetch'` - Search operation type +https://www.elastic.co/guide/en/elasticsearch/reference/current/ml-upgrade-job-model-snapshot.html[Endpoint documentation] +[source,ts] +---- +client.ml.upgradeJobSnapshot(...) +---- -|`explain` -|`boolean` - Specify whether to return detailed information about score computation as part of a hit +=== nodes +==== clear_repositories_metering_archive +Removes the archived repositories metering information present in the cluster. -|`profile` -|`boolean` - Specify whether to profile the query execution +https://www.elastic.co/guide/en/elasticsearch/reference/current/clear-repositories-metering-archive-api.html[Endpoint documentation] +[source,ts] +---- +client.nodes.clearRepositoriesMeteringArchive(...) +---- -|`typed_keys` or `typedKeys` -|`boolean` - Specify whether aggregation and suggester names should be prefixed by their respective types in the response +==== get_repositories_metering_info +Returns cluster repositories metering information. -|`rest_total_hits_as_int` or `restTotalHitsAsInt` -|`boolean` - Indicates whether hits.total should be rendered as an integer or an object in the rest search response +https://www.elastic.co/guide/en/elasticsearch/reference/current/get-repositories-metering-api.html[Endpoint documentation] +[source,ts] +---- +client.nodes.getRepositoriesMeteringInfo(...) +---- -|`ccs_minimize_roundtrips` or `ccsMinimizeRoundtrips` -|`boolean` - Indicates whether network round-trips should be minimized as part of cross-cluster search requests execution + -_Default:_ `true` +==== hot_threads +Returns information about hot threads on each node in the cluster. -|`body` -|`object` - The search definition template and its params +https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-nodes-hot-threads.html[Endpoint documentation] +[source,ts] +---- +client.nodes.hotThreads(...) +---- -|=== +==== info +Returns information about nodes in the cluster. -[discrete] -=== searchableSnapshots.cacheStats -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-nodes-info.html[Endpoint documentation] [source,ts] ---- -client.searchableSnapshots.cacheStats({ - node_id: string | string[] -}) +client.nodes.info(...) ---- -link:{ref}/searchable-snapshots-apis.html[Documentation] + -[cols=2*] -|=== -|`node_id` or `nodeId` -|`string \| string[]` - A comma-separated list of node IDs or names to limit the returned information; use `_local` to return information from the node you're connecting to, leave empty to get information from all nodes -|=== +==== reload_secure_settings +Reloads secure settings. -[discrete] -=== searchableSnapshots.clearCache -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/master/secure-settings.html#reloadable-secure-settings[Endpoint documentation] [source,ts] ---- -client.searchableSnapshots.clearCache({ - index: string | string[], - ignore_unavailable: boolean, - allow_no_indices: boolean, - expand_wildcards: 'open' | 'closed' | 'none' | 'all' -}) +client.nodes.reloadSecureSettings(...) ---- -link:{ref}/searchable-snapshots-apis.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) +==== stats +Returns statistical information about nodes in the cluster. -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` +https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-nodes-stats.html[Endpoint documentation] +[source,ts] +---- +client.nodes.stats(...) +---- -|=== +==== usage +Returns low-level information about REST actions usage on nodes. -[discrete] -=== searchableSnapshots.mount -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-nodes-usage.html[Endpoint documentation] [source,ts] ---- -client.searchableSnapshots.mount({ - repository: string, - snapshot: string, - master_timeout: string, - wait_for_completion: boolean, - storage: string, - body: object -}) +client.nodes.usage(...) ---- -link:{ref}/searchable-snapshots-api-mount-snapshot.html[Documentation] + -[cols=2*] -|=== -|`repository` -|`string` - The name of the repository containing the snapshot of the index to mount -|`snapshot` -|`string` - The name of the snapshot of the index to mount +=== rollup +==== delete_job +Deletes an existing rollup job. -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`wait_for_completion` or `waitForCompletion` -|`boolean` - Should this request wait until the operation has completed before returning +https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-delete-job.html[Endpoint documentation] +[source,ts] +---- +client.rollup.deleteJob(...) +---- -|`storage` -|`string` - Selects the kind of local storage used to accelerate searches. Experimental, and defaults to `full_copy` +==== get_jobs +Retrieves the configuration, stats, and status of rollup jobs. -|`body` -|`object` - The restore configuration for mounting the snapshot as searchable +https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-get-job.html[Endpoint documentation] +[source,ts] +---- +client.rollup.getJobs(...) +---- -|=== +==== get_rollup_caps +Returns the capabilities of any rollup jobs that have been configured for a specific index or index pattern. -[discrete] -=== searchableSnapshots.stats -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-get-rollup-caps.html[Endpoint documentation] [source,ts] ---- -client.searchableSnapshots.stats({ - index: string | string[], - level: 'cluster' | 'indices' | 'shards' -}) +client.rollup.getRollupCaps(...) ---- -link:{ref}/searchable-snapshots-apis.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names -|`level` -|`'cluster' \| 'indices' \| 'shards'` - Return stats aggregated at cluster, index or shard level + -_Default:_ `indices` +==== get_rollup_index_caps +Returns the rollup capabilities of all jobs inside of a rollup index (e.g. the index where rollup data is stored). -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-get-rollup-index-caps.html[Endpoint documentation] +[source,ts] +---- +client.rollup.getRollupIndexCaps(...) +---- -[discrete] -=== security.authenticate +==== put_job +Creates a rollup job. +https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-put-job.html[Endpoint documentation] [source,ts] ---- -client.security.authenticate() +client.rollup.putJob(...) ---- -link:{ref}/security-api-authenticate.html[Documentation] + +==== rollup +Rollup an index -[discrete] -=== security.changePassword - +https://www.elastic.co/guide/en/elasticsearch/reference/current/xpack-rollup.html[Endpoint documentation] [source,ts] ---- -client.security.changePassword({ - username: string, - refresh: 'true' | 'false' | 'wait_for', - body: object -}) +client.rollup.rollup(...) ---- -link:{ref}/security-api-change-password.html[Documentation] + -[cols=2*] -|=== -|`username` -|`string` - The username of the user to change the password for - -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. -|`body` -|`object` - the new password for the user +==== rollup_search +Enables searching rolled-up data using the standard query DSL. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-search.html[Endpoint documentation] +[source,ts] +---- +client.rollup.rollupSearch(...) +---- -[discrete] -=== security.clearApiKeyCache +==== start_job +Starts an existing, stopped rollup job. +https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-start-job.html[Endpoint documentation] [source,ts] ---- -client.security.clearApiKeyCache({ - ids: string | string[] -}) +client.rollup.startJob(...) ---- -link:{ref}/security-api-clear-api-key-cache.html[Documentation] + -[cols=2*] -|=== -|`ids` -|`string \| string[]` - A comma-separated list of IDs of API keys to clear from the cache - -|=== -[discrete] -=== security.clearCachedPrivileges +==== stop_job +Stops an existing, started rollup job. +https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-stop-job.html[Endpoint documentation] [source,ts] ---- -client.security.clearCachedPrivileges({ - application: string | string[] -}) +client.rollup.stopJob(...) ---- -link:{ref}/security-api-clear-privilege-cache.html[Documentation] + -[cols=2*] -|=== -|`application` -|`string \| string[]` - A comma-separated list of application names -|=== - -[discrete] -=== security.clearCachedRealms +=== searchable_snapshots +==== cache_stats +Retrieve node-level cache statistics about searchable snapshots. +https://www.elastic.co/guide/en/elasticsearch/reference/master/searchable-snapshots-apis.html[Endpoint documentation] [source,ts] ---- -client.security.clearCachedRealms({ - realms: string | string[], - usernames: string | string[] -}) +client.searchableSnapshots.cacheStats(...) ---- -link:{ref}/security-api-clear-cache.html[Documentation] + -[cols=2*] -|=== -|`realms` -|`string \| string[]` - Comma-separated list of realms to clear -|`usernames` -|`string \| string[]` - Comma-separated list of usernames to clear from the cache +==== clear_cache +Clear the cache of searchable snapshots. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/master/searchable-snapshots-apis.html[Endpoint documentation] +[source,ts] +---- +client.searchableSnapshots.clearCache(...) +---- -[discrete] -=== security.clearCachedRoles +==== mount +Mount a snapshot as a searchable index. +https://www.elastic.co/guide/en/elasticsearch/reference/master/searchable-snapshots-api-mount-snapshot.html[Endpoint documentation] [source,ts] ---- -client.security.clearCachedRoles({ - name: string | string[] -}) +client.searchableSnapshots.mount(...) ---- -link:{ref}/security-api-clear-role-cache.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - Role name -|=== +==== stats +Retrieve shard-level statistics about searchable snapshots. -[discrete] -=== security.clearCachedServiceTokens -*Stability:* beta +https://www.elastic.co/guide/en/elasticsearch/reference/master/searchable-snapshots-apis.html[Endpoint documentation] [source,ts] ---- -client.security.clearCachedServiceTokens({ - namespace: string, - service: string, - name: string | string[] -}) +client.searchableSnapshots.stats(...) ---- -link:{ref}/security-api-clear-service-token-caches.html[Documentation] + -[cols=2*] -|=== -|`namespace` -|`string` - An identifier for the namespace -|`service` -|`string` - An identifier for the service name +=== security +==== activate_user_profile +Creates or updates the user profile on behalf of another user. -|`name` -|`string \| string[]` - A comma-separated list of service token names - -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-activate-user-profile.html[Endpoint documentation] +[source,ts] +---- +client.security.activateUserProfile(...) +---- -[discrete] -=== security.createApiKey +==== authenticate +Enables authentication as a user and retrieve information about the authenticated user. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-authenticate.html[Endpoint documentation] [source,ts] ---- -client.security.createApiKey({ - refresh: 'true' | 'false' | 'wait_for', - body: object -}) +client.security.authenticate(...) ---- -link:{ref}/security-api-create-api-key.html[Documentation] + -[cols=2*] -|=== -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. -|`body` -|`object` - The api key request to create an API key +==== change_password +Changes the passwords of users in the native realm and built-in users. -|=== - -[discrete] -=== security.createServiceToken -*Stability:* beta +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-change-password.html[Endpoint documentation] [source,ts] ---- -client.security.createServiceToken({ - namespace: string, - service: string, - name: string, - refresh: 'true' | 'false' | 'wait_for' -}) +client.security.changePassword(...) ---- -link:{ref}/security-api-create-service-token.html[Documentation] + -[cols=2*] -|=== -|`namespace` -|`string` - An identifier for the namespace -|`service` -|`string` - An identifier for the service name +==== clear_api_key_cache +Clear a subset or all entries from the API key cache. -|`name` -|`string` - An identifier for the token name +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-clear-api-key-cache.html[Endpoint documentation] +[source,ts] +---- +client.security.clearApiKeyCache(...) +---- -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` then refresh the affected shards to make this operation visible to search, if `wait_for` (the default) then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. +==== clear_cached_privileges +Evicts application privileges from the native application privileges cache. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-clear-privilege-cache.html[Endpoint documentation] +[source,ts] +---- +client.security.clearCachedPrivileges(...) +---- -[discrete] -=== security.deletePrivileges +==== clear_cached_realms +Evicts users from the user cache. Can completely clear the cache or evict specific users. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-clear-cache.html[Endpoint documentation] [source,ts] ---- -client.security.deletePrivileges({ - application: string, - name: string, - refresh: 'true' | 'false' | 'wait_for' -}) +client.security.clearCachedRealms(...) ---- -link:{ref}/security-api-delete-privilege.html[Documentation] + -[cols=2*] -|=== -|`application` -|`string` - Application name - -|`name` -|`string` - Privilege name -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. +==== clear_cached_roles +Evicts roles from the native role cache. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-clear-role-cache.html[Endpoint documentation] +[source,ts] +---- +client.security.clearCachedRoles(...) +---- -[discrete] -=== security.deleteRole +==== clear_cached_service_tokens +Evicts tokens from the service account token caches. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-clear-service-token-caches.html[Endpoint documentation] [source,ts] ---- -client.security.deleteRole({ - name: string, - refresh: 'true' | 'false' | 'wait_for' -}) +client.security.clearCachedServiceTokens(...) ---- -link:{ref}/security-api-delete-role.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - Role name -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. +==== create_api_key +Creates an API key for access without requiring basic authentication. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-create-api-key.html[Endpoint documentation] +[source,ts] +---- +client.security.createApiKey(...) +---- -[discrete] -=== security.deleteRoleMapping +==== create_service_token +Creates a service account token for access without requiring basic authentication. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-create-service-token.html[Endpoint documentation] [source,ts] ---- -client.security.deleteRoleMapping({ - name: string, - refresh: 'true' | 'false' | 'wait_for' -}) +client.security.createServiceToken(...) ---- -link:{ref}/security-api-delete-role-mapping.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - Role-mapping name -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. +==== delete_privileges +Removes application privileges. -|=== - -[discrete] -=== security.deleteServiceToken -*Stability:* beta +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-delete-privilege.html[Endpoint documentation] [source,ts] ---- -client.security.deleteServiceToken({ - namespace: string, - service: string, - name: string, - refresh: 'true' | 'false' | 'wait_for' -}) +client.security.deletePrivileges(...) ---- -link:{ref}/security-api-delete-service-token.html[Documentation] + -[cols=2*] -|=== -|`namespace` -|`string` - An identifier for the namespace -|`service` -|`string` - An identifier for the service name +==== delete_role +Removes roles in the native realm. -|`name` -|`string` - An identifier for the token name +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-delete-role.html[Endpoint documentation] +[source,ts] +---- +client.security.deleteRole(...) +---- -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` then refresh the affected shards to make this operation visible to search, if `wait_for` (the default) then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. +==== delete_role_mapping +Removes role mappings. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-delete-role-mapping.html[Endpoint documentation] +[source,ts] +---- +client.security.deleteRoleMapping(...) +---- -[discrete] -=== security.deleteUser +==== delete_service_token +Deletes a service account token. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-delete-service-token.html[Endpoint documentation] [source,ts] ---- -client.security.deleteUser({ - username: string, - refresh: 'true' | 'false' | 'wait_for' -}) +client.security.deleteServiceToken(...) ---- -link:{ref}/security-api-delete-user.html[Documentation] + -[cols=2*] -|=== -|`username` -|`string` - username -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. +==== delete_user +Deletes users from the native realm. -|=== +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-delete-user.html[Endpoint documentation] +[source,ts] +---- +client.security.deleteUser(...) +---- -[discrete] -=== security.disableUser +==== disable_user +Disables users in the native realm. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-disable-user.html[Endpoint documentation] [source,ts] ---- -client.security.disableUser({ - username: string, - refresh: 'true' | 'false' | 'wait_for' -}) +client.security.disableUser(...) ---- -link:{ref}/security-api-disable-user.html[Documentation] + -[cols=2*] -|=== -|`username` -|`string` - The username of the user to disable -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. - -|=== - -[discrete] -=== security.enableUser +==== enable_user +Enables users in the native realm. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-enable-user.html[Endpoint documentation] [source,ts] ---- -client.security.enableUser({ - username: string, - refresh: 'true' | 'false' | 'wait_for' -}) +client.security.enableUser(...) ---- -link:{ref}/security-api-enable-user.html[Documentation] + -[cols=2*] -|=== -|`username` -|`string` - The username of the user to enable - -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. - -|=== -[discrete] -=== security.enrollKibana +==== enroll_kibana +Allows a kibana instance to configure itself to communicate with a secured elasticsearch cluster. +https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-kibana-enrollment.html[Endpoint documentation] [source,ts] ---- -client.security.enrollKibana() +client.security.enrollKibana(...) ---- -link:{ref}/security-api-kibana-enrollment.html[Documentation] + +==== enroll_node +Allows a new node to enroll to an existing cluster with security enabled. -[discrete] -=== security.enrollNode - +https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-node-enrollment.html[Endpoint documentation] [source,ts] ---- -client.security.enrollNode() +client.security.enrollNode(...) ---- -link:{ref}/security-api-node-enrollment.html[Documentation] + - -[discrete] -=== security.getApiKey +==== get_api_key +Retrieves information for one or more API keys. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-get-api-key.html[Endpoint documentation] [source,ts] ---- -client.security.getApiKey({ - id: string, - name: string, - username: string, - realm_name: string, - owner: boolean -}) +client.security.getApiKey(...) ---- -link:{ref}/security-api-get-api-key.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - API key id of the API key to be retrieved - -|`name` -|`string` - API key name of the API key to be retrieved - -|`username` -|`string` - user name of the user who created this API key to be retrieved -|`realm_name` or `realmName` -|`string` - realm name of the user who created this API key to be retrieved - -|`owner` -|`boolean` - flag to query API keys owned by the currently authenticated user - -|=== - -[discrete] -=== security.getBuiltinPrivileges +==== get_builtin_privileges +Retrieves the list of cluster privileges and index privileges that are available in this version of Elasticsearch. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-get-builtin-privileges.html[Endpoint documentation] [source,ts] ---- -client.security.getBuiltinPrivileges() +client.security.getBuiltinPrivileges(...) ---- -link:{ref}/security-api-get-builtin-privileges.html[Documentation] + - -[discrete] -=== security.getPrivileges +==== get_privileges +Retrieves application privileges. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-get-privileges.html[Endpoint documentation] [source,ts] ---- -client.security.getPrivileges({ - application: string, - name: string -}) +client.security.getPrivileges(...) ---- -link:{ref}/security-api-get-privileges.html[Documentation] + -[cols=2*] -|=== -|`application` -|`string` - Application name -|`name` -|`string` - Privilege name - -|=== - -[discrete] -=== security.getRole +==== get_role +Retrieves roles in the native realm. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-get-role.html[Endpoint documentation] [source,ts] ---- -client.security.getRole({ - name: string | string[] -}) +client.security.getRole(...) ---- -link:{ref}/security-api-get-role.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - A comma-separated list of role names -|=== - -[discrete] -=== security.getRoleMapping +==== get_role_mapping +Retrieves role mappings. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-get-role-mapping.html[Endpoint documentation] [source,ts] ---- -client.security.getRoleMapping({ - name: string | string[] -}) +client.security.getRoleMapping(...) ---- -link:{ref}/security-api-get-role-mapping.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string \| string[]` - A comma-separated list of role-mapping names -|=== +==== get_service_accounts +Retrieves information about service accounts. -[discrete] -=== security.getServiceAccounts -*Stability:* beta +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-get-service-accounts.html[Endpoint documentation] [source,ts] ---- -client.security.getServiceAccounts({ - namespace: string, - service: string -}) +client.security.getServiceAccounts(...) ---- -link:{ref}/security-api-get-service-accounts.html[Documentation] + -[cols=2*] -|=== -|`namespace` -|`string` - An identifier for the namespace - -|`service` -|`string` - An identifier for the service name -|=== +==== get_service_credentials +Retrieves information of all service credentials for a service account. -[discrete] -=== security.getServiceCredentials -*Stability:* beta +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-get-service-credentials.html[Endpoint documentation] [source,ts] ---- -client.security.getServiceCredentials({ - namespace: string, - service: string -}) +client.security.getServiceCredentials(...) ---- -link:{ref}/security-api-get-service-credentials.html[Documentation] + -[cols=2*] -|=== -|`namespace` -|`string` - An identifier for the namespace -|`service` -|`string` - An identifier for the service name - -|=== - -[discrete] -=== security.getToken +==== get_token +Creates a bearer token for access without requiring basic authentication. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-get-token.html[Endpoint documentation] [source,ts] ---- -client.security.getToken({ - body: object -}) +client.security.getToken(...) ---- -link:{ref}/security-api-get-token.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - The token request to get -|=== - -[discrete] -=== security.getUser +==== get_user +Retrieves information about users in the native realm and built-in users. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-get-user.html[Endpoint documentation] [source,ts] ---- -client.security.getUser({ - username: string | string[] -}) +client.security.getUser(...) ---- -link:{ref}/security-api-get-user.html[Documentation] + -[cols=2*] -|=== -|`username` -|`string \| string[]` - A comma-separated list of usernames - -|=== -[discrete] -=== security.getUserPrivileges +==== get_user_privileges +Retrieves security privileges for the logged in user. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-get-user-privileges.html[Endpoint documentation] [source,ts] ---- -client.security.getUserPrivileges() +client.security.getUserPrivileges(...) ---- -link:{ref}/security-api-get-privileges.html[Documentation] + +==== get_user_profile +Retrieves user profile for the given unique ID. -[discrete] -=== security.grantApiKey - +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-get-user-profile.html[Endpoint documentation] [source,ts] ---- -client.security.grantApiKey({ - refresh: 'true' | 'false' | 'wait_for', - body: object -}) +client.security.getUserProfile(...) ---- -link:{ref}/security-api-grant-api-key.html[Documentation] + -[cols=2*] -|=== -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. - -|`body` -|`object` - The api key request to create an API key -|=== - -[discrete] -=== security.hasPrivileges +==== grant_api_key +Creates an API key on behalf of another user. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-grant-api-key.html[Endpoint documentation] [source,ts] ---- -client.security.hasPrivileges({ - user: string, - body: object -}) +client.security.grantApiKey(...) ---- -link:{ref}/security-api-has-privileges.html[Documentation] + -[cols=2*] -|=== -|`user` -|`string` - Username - -|`body` -|`object` - The privileges to test -|=== - -[discrete] -=== security.invalidateApiKey +==== has_privileges +Determines whether the specified user has a specified list of privileges. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-has-privileges.html[Endpoint documentation] [source,ts] ---- -client.security.invalidateApiKey({ - body: object -}) +client.security.hasPrivileges(...) ---- -link:{ref}/security-api-invalidate-api-key.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - The api key request to invalidate API key(s) - -|=== -[discrete] -=== security.invalidateToken +==== invalidate_api_key +Invalidates one or more API keys. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-invalidate-api-key.html[Endpoint documentation] [source,ts] ---- -client.security.invalidateToken({ - body: object -}) +client.security.invalidateApiKey(...) ---- -link:{ref}/security-api-invalidate-token.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - The token to invalidate -|=== - -[discrete] -=== security.putPrivileges +==== invalidate_token +Invalidates one or more access tokens or refresh tokens. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-invalidate-token.html[Endpoint documentation] [source,ts] ---- -client.security.putPrivileges({ - refresh: 'true' | 'false' | 'wait_for', - body: object -}) +client.security.invalidateToken(...) ---- -link:{ref}/security-api-put-privileges.html[Documentation] + -[cols=2*] -|=== -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. - -|`body` -|`object` - The privilege(s) to add -|=== - -[discrete] -=== security.putRole +==== oidc_authenticate +Exchanges an OpenID Connection authentication response message for an Elasticsearch access token and refresh token pair +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-oidc-authenticate.html[Endpoint documentation] [source,ts] ---- -client.security.putRole({ - name: string, - refresh: 'true' | 'false' | 'wait_for', - body: object -}) +client.security.oidcAuthenticate(...) ---- -link:{ref}/security-api-put-role.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - Role name - -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. - -|`body` -|`object` - The role to add - -|=== -[discrete] -=== security.putRoleMapping +==== oidc_logout +Invalidates a refresh token and access token that was generated from the OpenID Connect Authenticate API +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-oidc-logout.html[Endpoint documentation] [source,ts] ---- -client.security.putRoleMapping({ - name: string, - refresh: 'true' | 'false' | 'wait_for', - body: object -}) +client.security.oidcLogout(...) ---- -link:{ref}/security-api-put-role-mapping.html[Documentation] + -[cols=2*] -|=== -|`name` -|`string` - Role-mapping name -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. - -|`body` -|`object` - The role mapping to add - -|=== - -[discrete] -=== security.putUser +==== oidc_prepare_authentication +Creates an OAuth 2.0 authentication request as a URL string +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-oidc-prepare-authentication.html[Endpoint documentation] [source,ts] ---- -client.security.putUser({ - username: string, - refresh: 'true' | 'false' | 'wait_for', - body: object -}) +client.security.oidcPrepareAuthentication(...) ---- -link:{ref}/security-api-put-user.html[Documentation] + -[cols=2*] -|=== -|`username` -|`string` - The username of the User - -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes. -|`body` -|`object` - The user to add - -|=== - -[discrete] -=== security.queryApiKeys +==== put_privileges +Adds or updates application privileges. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-put-privileges.html[Endpoint documentation] [source,ts] ---- -client.security.queryApiKeys({ - body: object -}) +client.security.putPrivileges(...) ---- -link:{ref}/security-api-query-api-key.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - From, size, query, sort and search_after -|=== - -[discrete] -=== security.samlAuthenticate +==== put_role +Adds and updates roles in the native realm. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-put-role.html[Endpoint documentation] [source,ts] ---- -client.security.samlAuthenticate({ - body: object -}) +client.security.putRole(...) ---- -link:{ref}/security-api-saml-authenticate.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - The SAML response to authenticate - -|=== -[discrete] -=== security.samlCompleteLogout +==== put_role_mapping +Creates and updates role mappings. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-put-role-mapping.html[Endpoint documentation] [source,ts] ---- -client.security.samlCompleteLogout({ - body: object -}) +client.security.putRoleMapping(...) ---- -link:{ref}/security-api-saml-complete-logout.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - The logout response to verify -|=== - -[discrete] -=== security.samlInvalidate +==== put_user +Adds and updates users in the native realm. These users are commonly referred to as native users. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-put-user.html[Endpoint documentation] [source,ts] ---- -client.security.samlInvalidate({ - body: object -}) +client.security.putUser(...) ---- -link:{ref}/security-api-saml-invalidate.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - The LogoutRequest message - -|=== -[discrete] -=== security.samlLogout +==== query_api_keys +Retrieves information for API keys using a subset of query DSL +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-query-api-key.html[Endpoint documentation] [source,ts] ---- -client.security.samlLogout({ - body: object -}) +client.security.queryApiKeys(...) ---- -link:{ref}/security-api-saml-logout.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - The tokens to invalidate -|=== - -[discrete] -=== security.samlPrepareAuthentication +==== saml_authenticate +Exchanges a SAML Response message for an Elasticsearch access token and refresh token pair +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-saml-authenticate.html[Endpoint documentation] [source,ts] ---- -client.security.samlPrepareAuthentication({ - body: object -}) +client.security.samlAuthenticate(...) ---- -link:{ref}/security-api-saml-prepare-authentication.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - The realm for which to create the authentication request, identified by either its name or the ACS URL - -|=== -[discrete] -=== security.samlServiceProviderMetadata +==== saml_complete_logout +Verifies the logout response sent from the SAML IdP +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-saml-complete-logout.html[Endpoint documentation] [source,ts] ---- -client.security.samlServiceProviderMetadata({ - realm_name: string -}) +client.security.samlCompleteLogout(...) ---- -link:{ref}/security-api-saml-sp-metadata.html[Documentation] + -[cols=2*] -|=== -|`realm_name` or `realmName` -|`string` - The name of the SAML realm to get the metadata for -|=== +==== saml_invalidate +Consumes a SAML LogoutRequest -[discrete] -=== shutdown.deleteNode -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-saml-invalidate.html[Endpoint documentation] [source,ts] ---- -client.shutdown.deleteNode({ - node_id: string -}) +client.security.samlInvalidate(...) ---- -link:https://www.elastic.co/guide/en/elasticsearch/reference/current[Documentation] + -[cols=2*] -|=== -|`node_id` or `nodeId` -|`string` - The node id of node to be removed from the shutdown state -|=== +==== saml_logout +Invalidates an access token and a refresh token that were generated via the SAML Authenticate API -[discrete] -=== shutdown.getNode -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-saml-logout.html[Endpoint documentation] [source,ts] ---- -client.shutdown.getNode({ - node_id: string -}) +client.security.samlLogout(...) ---- -link:https://www.elastic.co/guide/en/elasticsearch/reference/current[Documentation] + -[cols=2*] -|=== -|`node_id` or `nodeId` -|`string` - Which node for which to retrieve the shutdown status -|=== +==== saml_prepare_authentication +Creates a SAML authentication request -[discrete] -=== shutdown.putNode -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-saml-prepare-authentication.html[Endpoint documentation] [source,ts] ---- -client.shutdown.putNode({ - node_id: string, - body: object -}) +client.security.samlPrepareAuthentication(...) ---- -link:https://www.elastic.co/guide/en/elasticsearch/reference/current[Documentation] + -[cols=2*] -|=== -|`node_id` or `nodeId` -|`string` - The node id of node to be shut down -|`body` -|`object` - The shutdown type definition to register - -|=== - -[discrete] -=== slm.deleteLifecycle +==== saml_service_provider_metadata +Generates SAML metadata for the Elastic stack SAML 2.0 Service Provider +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-saml-sp-metadata.html[Endpoint documentation] [source,ts] ---- -client.slm.deleteLifecycle({ - policy_id: string -}) +client.security.samlServiceProviderMetadata(...) ---- -link:{ref}/slm-api-delete-policy.html[Documentation] + -[cols=2*] -|=== -|`policy_id` or `policyId` -|`string` - The id of the snapshot lifecycle policy to remove -|=== - -[discrete] -=== slm.executeLifecycle +==== update_user_profile_data +Update application specific data for the user profile of the given unique ID. +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-update-user-profile-data.html[Endpoint documentation] [source,ts] ---- -client.slm.executeLifecycle({ - policy_id: string -}) +client.security.updateUserProfileData(...) ---- -link:{ref}/slm-api-execute-lifecycle.html[Documentation] + -[cols=2*] -|=== -|`policy_id` or `policyId` -|`string` - The id of the snapshot lifecycle policy to be executed - -|=== -[discrete] -=== slm.executeRetention +=== slm +==== delete_lifecycle +Deletes an existing snapshot lifecycle policy. +https://www.elastic.co/guide/en/elasticsearch/reference/current/slm-api-delete-policy.html[Endpoint documentation] [source,ts] ---- -client.slm.executeRetention() +client.slm.deleteLifecycle(...) ---- -link:{ref}/slm-api-execute-retention.html[Documentation] + +==== execute_lifecycle +Immediately creates a snapshot according to the lifecycle policy, without waiting for the scheduled time. -[discrete] -=== slm.getLifecycle - +https://www.elastic.co/guide/en/elasticsearch/reference/current/slm-api-execute-lifecycle.html[Endpoint documentation] [source,ts] ---- -client.slm.getLifecycle({ - policy_id: string | string[] -}) +client.slm.executeLifecycle(...) ---- -link:{ref}/slm-api-get-policy.html[Documentation] + -[cols=2*] -|=== -|`policy_id` or `policyId` -|`string \| string[]` - Comma-separated list of snapshot lifecycle policies to retrieve - -|=== -[discrete] -=== slm.getStats +==== execute_retention +Deletes any snapshots that are expired according to the policy's retention rules. +https://www.elastic.co/guide/en/elasticsearch/reference/current/slm-api-execute-retention.html[Endpoint documentation] [source,ts] ---- -client.slm.getStats() +client.slm.executeRetention(...) ---- -link:{ref}/slm-api-get-stats.html[Documentation] + +==== get_lifecycle +Retrieves one or more snapshot lifecycle policy definitions and information about the latest snapshot attempts. -[discrete] -=== slm.getStatus - +https://www.elastic.co/guide/en/elasticsearch/reference/current/slm-api-get-policy.html[Endpoint documentation] [source,ts] ---- -client.slm.getStatus() +client.slm.getLifecycle(...) ---- -link:{ref}/slm-api-get-status.html[Documentation] + - -[discrete] -=== slm.putLifecycle +==== get_stats +Returns global and policy-level statistics about actions taken by snapshot lifecycle management. +https://www.elastic.co/guide/en/elasticsearch/reference/master/slm-api-get-stats.html[Endpoint documentation] [source,ts] ---- -client.slm.putLifecycle({ - policy_id: string, - body: object -}) +client.slm.getStats(...) ---- -link:{ref}/slm-api-put-policy.html[Documentation] + -[cols=2*] -|=== -|`policy_id` or `policyId` -|`string` - The id of the snapshot lifecycle policy -|`body` -|`object` - The snapshot lifecycle policy definition to register - -|=== - -[discrete] -=== slm.start +==== get_status +Retrieves the status of snapshot lifecycle management (SLM). +https://www.elastic.co/guide/en/elasticsearch/reference/current/slm-api-get-status.html[Endpoint documentation] [source,ts] ---- -client.slm.start() +client.slm.getStatus(...) ---- -link:{ref}/slm-api-start.html[Documentation] + +==== put_lifecycle +Creates or updates a snapshot lifecycle policy. -[discrete] -=== slm.stop - +https://www.elastic.co/guide/en/elasticsearch/reference/current/slm-api-put-policy.html[Endpoint documentation] [source,ts] ---- -client.slm.stop() +client.slm.putLifecycle(...) ---- -link:{ref}/slm-api-stop.html[Documentation] + - -[discrete] -=== snapshot.cleanupRepository +==== start +Turns on snapshot lifecycle management (SLM). +https://www.elastic.co/guide/en/elasticsearch/reference/current/slm-api-start.html[Endpoint documentation] [source,ts] ---- -client.snapshot.cleanupRepository({ - repository: string, - master_timeout: string, - timeout: string -}) +client.slm.start(...) ---- -link:{ref}/clean-up-snapshot-repo-api.html[Documentation] + -[cols=2*] -|=== -|`repository` -|`string` - A repository name -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`timeout` -|`string` - Explicit operation timeout - -|=== - -[discrete] -=== snapshot.clone +==== stop +Turns off snapshot lifecycle management (SLM). +https://www.elastic.co/guide/en/elasticsearch/reference/current/slm-api-stop.html[Endpoint documentation] [source,ts] ---- -client.snapshot.clone({ - repository: string, - snapshot: string, - target_snapshot: string, - master_timeout: string, - body: object -}) +client.slm.stop(...) ---- -link:{ref}/modules-snapshots.html[Documentation] + -[cols=2*] -|=== -|`repository` -|`string` - A repository name - -|`snapshot` -|`string` - The name of the snapshot to clone from - -|`target_snapshot` or `targetSnapshot` -|`string` - The name of the cloned snapshot to create - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`body` -|`object` - The snapshot clone definition - -|=== -[discrete] -=== snapshot.create +=== snapshot +==== cleanup_repository +Removes stale data from repository. +https://www.elastic.co/guide/en/elasticsearch/reference/master/clean-up-snapshot-repo-api.html[Endpoint documentation] [source,ts] ---- -client.snapshot.create({ - repository: string, - snapshot: string, - master_timeout: string, - wait_for_completion: boolean, - body: object -}) +client.snapshot.cleanupRepository(...) ---- -link:{ref}/modules-snapshots.html[Documentation] + -[cols=2*] -|=== -|`repository` -|`string` - A repository name -|`snapshot` -|`string` - A snapshot name - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`wait_for_completion` or `waitForCompletion` -|`boolean` - Should this request wait until the operation has completed before returning - -|`body` -|`object` - The snapshot definition - -|=== - -[discrete] -=== snapshot.createRepository +==== clone +Clones indices from one snapshot into another snapshot in the same repository. +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html[Endpoint documentation] [source,ts] ---- -client.snapshot.createRepository({ - repository: string, - master_timeout: string, - timeout: string, - verify: boolean, - body: object -}) +client.snapshot.clone(...) ---- -link:{ref}/modules-snapshots.html[Documentation] + -[cols=2*] -|=== -|`repository` -|`string` - A repository name - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`timeout` -|`string` - Explicit operation timeout - -|`verify` -|`boolean` - Whether to verify the repository after creation -|`body` -|`object` - The repository definition - -|=== - -[discrete] -=== snapshot.delete +==== create +Creates a snapshot in a repository. +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html[Endpoint documentation] [source,ts] ---- -client.snapshot.delete({ - repository: string, - snapshot: string | string[], - master_timeout: string -}) +client.snapshot.create(...) ---- -link:{ref}/modules-snapshots.html[Documentation] + -[cols=2*] -|=== -|`repository` -|`string` - A repository name - -|`snapshot` -|`string \| string[]` - A comma-separated list of snapshot names - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node -|=== - -[discrete] -=== snapshot.deleteRepository +==== create_repository +Creates a repository. +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html[Endpoint documentation] [source,ts] ---- -client.snapshot.deleteRepository({ - repository: string | string[], - master_timeout: string, - timeout: string -}) +client.snapshot.createRepository(...) ---- -link:{ref}/modules-snapshots.html[Documentation] + -[cols=2*] -|=== -|`repository` -|`string \| string[]` - Name of the snapshot repository to unregister. Wildcard (`*`) patterns are supported. - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`timeout` -|`string` - Explicit operation timeout - -|=== -[discrete] -=== snapshot.get +==== delete +Deletes one or more snapshots. +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html[Endpoint documentation] [source,ts] ---- -client.snapshot.get({ - repository: string, - snapshot: string | string[], - master_timeout: string, - ignore_unavailable: boolean, - index_details: boolean, - include_repository: boolean, - verbose: boolean -}) +client.snapshot.delete(...) ---- -link:{ref}/modules-snapshots.html[Documentation] + -[cols=2*] -|=== -|`repository` -|`string` - A repository name -|`snapshot` -|`string \| string[]` - A comma-separated list of snapshot names - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether to ignore unavailable snapshots, defaults to false which means a SnapshotMissingException is thrown - -|`index_details` or `indexDetails` -|`boolean` - Whether to include details of each index in the snapshot, if those details are available. Defaults to false. - -|`include_repository` or `includeRepository` -|`boolean` - Whether to include the repository name in the snapshot info. Defaults to true. - -|`verbose` -|`boolean` - Whether to show verbose snapshot info or only show the basic info found in the repository index blob - -|=== - -[discrete] -=== snapshot.getRepository +==== delete_repository +Deletes a repository. +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html[Endpoint documentation] [source,ts] ---- -client.snapshot.getRepository({ - repository: string | string[], - master_timeout: string, - local: boolean -}) +client.snapshot.deleteRepository(...) ---- -link:{ref}/modules-snapshots.html[Documentation] + -[cols=2*] -|=== -|`repository` -|`string \| string[]` - A comma-separated list of repository names - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node -|`local` -|`boolean` - Return local information, do not retrieve the state from master node (default: false) - -|=== - -[discrete] -=== snapshot.repositoryAnalyze +==== get +Returns information about a snapshot. +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html[Endpoint documentation] [source,ts] ---- -client.snapshot.repositoryAnalyze({ - repository: string, - blob_count: number, - concurrency: number, - read_node_count: number, - early_read_node_count: number, - seed: number, - rare_action_probability: number, - max_blob_size: string, - max_total_data_size: string, - timeout: string, - detailed: boolean, - rarely_abort_writes: boolean -}) +client.snapshot.get(...) ---- -link:{ref}/modules-snapshots.html[Documentation] + -[cols=2*] -|=== -|`repository` -|`string` - A repository name - -|`blob_count` or `blobCount` -|`number` - Number of blobs to create during the test. Defaults to 100. - -|`concurrency` -|`number` - Number of operations to run concurrently during the test. Defaults to 10. - -|`read_node_count` or `readNodeCount` -|`number` - Number of nodes on which to read a blob after writing. Defaults to 10. - -|`early_read_node_count` or `earlyReadNodeCount` -|`number` - Number of nodes on which to perform an early read on a blob, i.e. before writing has completed. Early reads are rare actions so the 'rare_action_probability' parameter is also relevant. Defaults to 2. - -|`seed` -|`number` - Seed for the random number generator used to create the test workload. Defaults to a random value. - -|`rare_action_probability` or `rareActionProbability` -|`number` - Probability of taking a rare action such as an early read or an overwrite. Defaults to 0.02. -|`max_blob_size` or `maxBlobSize` -|`string` - Maximum size of a blob to create during the test, e.g '1gb' or '100mb'. Defaults to '10mb'. - -|`max_total_data_size` or `maxTotalDataSize` -|`string` - Maximum total size of all blobs to create during the test, e.g '1tb' or '100gb'. Defaults to '1gb'. - -|`timeout` -|`string` - Explicit operation timeout. Defaults to '30s'. - -|`detailed` -|`boolean` - Whether to return detailed results or a summary. Defaults to 'false' so that only the summary is returned. - -|`rarely_abort_writes` or `rarelyAbortWrites` -|`boolean` - Whether to rarely abort writes before they complete. Defaults to 'true'. - -|=== - -[discrete] -=== snapshot.restore +==== get_repository +Returns information about a repository. +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html[Endpoint documentation] [source,ts] ---- -client.snapshot.restore({ - repository: string, - snapshot: string, - master_timeout: string, - wait_for_completion: boolean, - body: object -}) +client.snapshot.getRepository(...) ---- -link:{ref}/modules-snapshots.html[Documentation] + -[cols=2*] -|=== -|`repository` -|`string` - A repository name - -|`snapshot` -|`string` - A snapshot name - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node -|`wait_for_completion` or `waitForCompletion` -|`boolean` - Should this request wait until the operation has completed before returning - -|`body` -|`object` - Details of what to restore - -|=== - -[discrete] -=== snapshot.status +==== repository_analyze +Analyzes a repository for correctness and performance +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html[Endpoint documentation] [source,ts] ---- -client.snapshot.status({ - repository: string, - snapshot: string | string[], - master_timeout: string, - ignore_unavailable: boolean -}) +client.snapshot.repositoryAnalyze(...) ---- -link:{ref}/modules-snapshots.html[Documentation] + -[cols=2*] -|=== -|`repository` -|`string` - A repository name - -|`snapshot` -|`string \| string[]` - A comma-separated list of snapshot names -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether to ignore unavailable snapshots, defaults to false which means a SnapshotMissingException is thrown - -|=== - -[discrete] -=== snapshot.verifyRepository +==== restore +Restores a snapshot. +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html[Endpoint documentation] [source,ts] ---- -client.snapshot.verifyRepository({ - repository: string, - master_timeout: string, - timeout: string -}) +client.snapshot.restore(...) ---- -link:{ref}/modules-snapshots.html[Documentation] + -[cols=2*] -|=== -|`repository` -|`string` - A repository name - -|`master_timeout` or `masterTimeout` -|`string` - Explicit operation timeout for connection to master node -|`timeout` -|`string` - Explicit operation timeout - -|=== - -[discrete] -=== sql.clearCursor +==== status +Returns information about the status of a snapshot. +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html[Endpoint documentation] [source,ts] ---- -client.sql.clearCursor({ - body: object -}) +client.snapshot.status(...) ---- -link:{ref}/clear-sql-cursor-api.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - Specify the cursor value in the `cursor` element to clean the cursor. -|=== - -[discrete] -=== sql.deleteAsync +==== verify_repository +Verifies a repository. +https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html[Endpoint documentation] [source,ts] ---- -client.sql.deleteAsync({ - id: string -}) +client.snapshot.verifyRepository(...) ---- -link:{ref}/delete-async-sql-search-api.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The async search ID - -|=== -[discrete] -=== sql.getAsync +=== sql +==== clear_cursor +Clears the SQL cursor +https://www.elastic.co/guide/en/elasticsearch/reference/current/clear-sql-cursor-api.html[Endpoint documentation] [source,ts] ---- -client.sql.getAsync({ - id: string, - delimiter: string, - format: string, - keep_alive: string, - wait_for_completion_timeout: string -}) +client.sql.clearCursor(...) ---- -link:{ref}/get-async-sql-search-api.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The async search ID - -|`delimiter` -|`string` - Separator for CSV results + -_Default:_ `,` - -|`format` -|`string` - Short version of the Accept header, e.g. json, yaml - -|`keep_alive` or `keepAlive` -|`string` - Retention period for the search and its results + -_Default:_ `5d` - -|`wait_for_completion_timeout` or `waitForCompletionTimeout` -|`string` - Duration to wait for complete results -|=== - -[discrete] -=== sql.getAsyncStatus +==== delete_async +Deletes an async SQL search or a stored synchronous SQL search. If the search is still running, the API cancels it. +https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-async-sql-search-api.html[Endpoint documentation] [source,ts] ---- -client.sql.getAsyncStatus({ - id: string -}) +client.sql.deleteAsync(...) ---- -link:{ref}/get-async-sql-search-status-api.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - The async search ID - -|=== -[discrete] -=== sql.query +==== get_async +Returns the current status and available results for an async SQL search or stored synchronous SQL search +https://www.elastic.co/guide/en/elasticsearch/reference/master/get-async-sql-search-api.html[Endpoint documentation] [source,ts] ---- -client.sql.query({ - format: string, - body: object -}) +client.sql.getAsync(...) ---- -link:{ref}/sql-search-api.html[Documentation] + -{jsclient}/sql_query_examples.html[Code Example] + -[cols=2*] -|=== -|`format` -|`string` - a short version of the Accept header, e.g. json, yaml - -|`body` -|`object` - Use the `query` element to start a query. Use the `cursor` element to continue a query. - -|=== -[discrete] -=== sql.translate +==== get_async_status +Returns the current status of an async SQL search or a stored synchronous SQL search +https://www.elastic.co/guide/en/elasticsearch/reference/master/get-async-sql-search-status-api.html[Endpoint documentation] [source,ts] ---- -client.sql.translate({ - body: object -}) +client.sql.getAsyncStatus(...) ---- -link:{ref}/sql-translate-api.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - Specify the query in the `query` element. -|=== - -[discrete] -=== ssl.certificates +==== query +Executes a SQL request +https://www.elastic.co/guide/en/elasticsearch/reference/current/sql-search-api.html[Endpoint documentation] [source,ts] ---- -client.ssl.certificates() +client.sql.query(...) ---- -link:{ref}/security-api-ssl.html[Documentation] + +==== translate +Translates SQL into Elasticsearch queries -[discrete] -=== tasks.cancel -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/sql-translate-api.html[Endpoint documentation] [source,ts] ---- -client.tasks.cancel({ - task_id: string, - nodes: string | string[], - actions: string | string[], - parent_task_id: string, - wait_for_completion: boolean -}) +client.sql.translate(...) ---- -link:{ref}/tasks.html[Documentation] + -[cols=2*] -|=== -|`task_id` or `taskId` -|`string` - Cancel the task with specified task id (node_id:task_number) - -|`nodes` -|`string \| string[]` - A comma-separated list of node IDs or names to limit the returned information; use `_local` to return information from the node you're connecting to, leave empty to get information from all nodes - -|`actions` -|`string \| string[]` - A comma-separated list of actions that should be cancelled. Leave empty to cancel all. - -|`parent_task_id` or `parentTaskId` -|`string` - Cancel tasks with specified parent task id (node_id:task_number). Set to -1 to cancel all. -|`wait_for_completion` or `waitForCompletion` -|`boolean` - Should the request block until the cancellation of the task and its descendant tasks is completed. Defaults to false +=== ssl +==== certificates +Retrieves information about the X.509 certificates used to encrypt communications in the cluster. -|=== - -[discrete] -=== tasks.get -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-ssl.html[Endpoint documentation] [source,ts] ---- -client.tasks.get({ - task_id: string, - wait_for_completion: boolean, - timeout: string -}) +client.ssl.certificates(...) ---- -link:{ref}/tasks.html[Documentation] + -[cols=2*] -|=== -|`task_id` or `taskId` -|`string` - Return the task with specified id (node_id:task_number) - -|`wait_for_completion` or `waitForCompletion` -|`boolean` - Wait for the matching tasks to complete (default: false) -|`timeout` -|`string` - Explicit operation timeout +=== tasks +==== cancel +Cancels a task, if it can be cancelled through an API. -|=== - -[discrete] -=== tasks.list -*Stability:* experimental +https://www.elastic.co/guide/en/elasticsearch/reference/master/tasks.html[Endpoint documentation] [source,ts] ---- -client.tasks.list({ - nodes: string | string[], - actions: string | string[], - detailed: boolean, - parent_task_id: string, - wait_for_completion: boolean, - group_by: 'nodes' | 'parents' | 'none', - timeout: string -}) +client.tasks.cancel(...) ---- -link:{ref}/tasks.html[Documentation] + -[cols=2*] -|=== -|`nodes` -|`string \| string[]` - A comma-separated list of node IDs or names to limit the returned information; use `_local` to return information from the node you're connecting to, leave empty to get information from all nodes - -|`actions` -|`string \| string[]` - A comma-separated list of actions that should be returned. Leave empty to return all. - -|`detailed` -|`boolean` - Return detailed task information (default: false) - -|`parent_task_id` or `parentTaskId` -|`string` - Return tasks with specified parent task id (node_id:task_number). Set to -1 to return all. - -|`wait_for_completion` or `waitForCompletion` -|`boolean` - Wait for the matching tasks to complete (default: false) - -|`group_by` or `groupBy` -|`'nodes' \| 'parents' \| 'none'` - Group tasks by nodes or parent/child relationships + -_Default:_ `nodes` -|`timeout` -|`string` - Explicit operation timeout +==== get +Returns information about a task. -|=== - -[discrete] -=== termsEnum -*Stability:* beta +https://www.elastic.co/guide/en/elasticsearch/reference/master/tasks.html[Endpoint documentation] [source,ts] ---- -client.termsEnum({ - index: string | string[], - body: object -}) +client.tasks.get(...) ---- -link:{ref}/search-terms-enum.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to search; use `_all` or empty string to perform the operation on all indices - -|`body` -|`object` - field name, string which is the prefix expected in matching terms, timeout and size for max number of results -|=== - -[discrete] -=== termvectors +==== list +Returns a list of tasks. +https://www.elastic.co/guide/en/elasticsearch/reference/master/tasks.html[Endpoint documentation] [source,ts] ---- -client.termvectors({ - index: string, - id: string, - term_statistics: boolean, - field_statistics: boolean, - fields: string | string[], - offsets: boolean, - positions: boolean, - payloads: boolean, - preference: string, - routing: string, - realtime: boolean, - version: number, - version_type: 'internal' | 'external' | 'external_gte', - body: object -}) +client.tasks.list(...) ---- -link:{ref}/docs-termvectors.html[Documentation] + -[cols=2*] -|=== -|`index` -|`string` - The index in which the document resides. - -|`id` -|`string` - The id of the document, when not specified a doc param should be supplied. - -|`term_statistics` or `termStatistics` -|`boolean` - Specifies if total term frequency and document frequency should be returned. - -|`field_statistics` or `fieldStatistics` -|`boolean` - Specifies if document count, sum of document frequencies and sum of total term frequencies should be returned. + -_Default:_ `true` - -|`fields` -|`string \| string[]` - A comma-separated list of fields to return. - -|`offsets` -|`boolean` - Specifies if term offsets should be returned. + -_Default:_ `true` -|`positions` -|`boolean` - Specifies if term positions should be returned. + -_Default:_ `true` - -|`payloads` -|`boolean` - Specifies if term payloads should be returned. + -_Default:_ `true` - -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random). - -|`routing` -|`string` - Specific routing value. - -|`realtime` -|`boolean` - Specifies if request is real-time as opposed to near-real-time (default: true). - -|`version` -|`number` - Explicit version number for concurrency control - -|`version_type` or `versionType` -|`'internal' \| 'external' \| 'external_gte'` - Specific version type - -|`body` -|`object` - Define parameters and or supply a document to get termvectors for. See documentation. - -|=== - -[discrete] -=== textStructure.findStructure +=== text_structure +==== find_structure +Finds the structure of a text file. The text file must contain data that is suitable to be ingested into Elasticsearch. +https://www.elastic.co/guide/en/elasticsearch/reference/current/find-structure.html[Endpoint documentation] [source,ts] ---- -client.textStructure.findStructure({ - lines_to_sample: number, - line_merge_size_limit: number, - timeout: string, - charset: string, - format: 'ndjson' | 'xml' | 'delimited' | 'semi_structured_text', - has_header_row: boolean, - column_names: string | string[], - delimiter: string, - quote: string, - should_trim_fields: boolean, - grok_pattern: string, - timestamp_field: string, - timestamp_format: string, - explain: boolean, - body: object -}) +client.textStructure.findStructure(...) ---- -link:{ref}/find-structure.html[Documentation] + -[cols=2*] -|=== -|`lines_to_sample` or `linesToSample` -|`number` - How many lines of the file should be included in the analysis + -_Default:_ `1000` - -|`line_merge_size_limit` or `lineMergeSizeLimit` -|`number` - Maximum number of characters permitted in a single message when lines are merged to create messages. + -_Default:_ `10000` - -|`timeout` -|`string` - Timeout after which the analysis will be aborted + -_Default:_ `25s` - -|`charset` -|`string` - Optional parameter to specify the character set of the file - -|`format` -|`'ndjson' \| 'xml' \| 'delimited' \| 'semi_structured_text'` - Optional parameter to specify the high level file format - -|`has_header_row` or `hasHeaderRow` -|`boolean` - Optional parameter to specify whether a delimited file includes the column names in its first row - -|`column_names` or `columnNames` -|`string \| string[]` - Optional parameter containing a comma separated list of the column names for a delimited file - -|`delimiter` -|`string` - Optional parameter to specify the delimiter character for a delimited file - must be a single character -|`quote` -|`string` - Optional parameter to specify the quote character for a delimited file - must be a single character - -|`should_trim_fields` or `shouldTrimFields` -|`boolean` - Optional parameter to specify whether the values between delimiters in a delimited file should have whitespace trimmed from them - -|`grok_pattern` or `grokPattern` -|`string` - Optional parameter to specify the Grok pattern that should be used to extract fields from messages in a semi-structured text file - -|`timestamp_field` or `timestampField` -|`string` - Optional parameter to specify the timestamp field in the file - -|`timestamp_format` or `timestampFormat` -|`string` - Optional parameter to specify the timestamp format in the file - may be either a Joda or Java time format - -|`explain` -|`boolean` - Whether to include a commentary on how the structure was derived - -|`body` -|`object` - The contents of the file to be analyzed - -|=== - -[discrete] -=== transform.deleteTransform +=== transform +==== delete_transform +Deletes an existing transform. +https://www.elastic.co/guide/en/elasticsearch/reference/current/delete-transform.html[Endpoint documentation] [source,ts] ---- -client.transform.deleteTransform({ - transform_id: string, - force: boolean -}) +client.transform.deleteTransform(...) ---- -link:{ref}/delete-transform.html[Documentation] + -[cols=2*] -|=== -|`transform_id` or `transformId` -|`string` - The id of the transform to delete -|`force` -|`boolean` - When `true`, the transform is deleted regardless of its current state. The default value is `false`, meaning that the transform must be `stopped` before it can be deleted. - -|=== - -[discrete] -=== transform.getTransform +==== get_transform +Retrieves configuration information for transforms. +https://www.elastic.co/guide/en/elasticsearch/reference/current/get-transform.html[Endpoint documentation] [source,ts] ---- -client.transform.getTransform({ - transform_id: string, - from: number, - size: number, - allow_no_match: boolean, - exclude_generated: boolean -}) +client.transform.getTransform(...) ---- -link:{ref}/get-transform.html[Documentation] + -[cols=2*] -|=== -|`transform_id` or `transformId` -|`string` - The id or comma delimited list of id expressions of the transforms to get, '_all' or '*' implies get all transforms - -|`from` -|`number` - skips a number of transform configs, defaults to 0 - -|`size` -|`number` - specifies a max number of transforms to get, defaults to 100 -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no transforms. (This includes `_all` string or when no transforms have been specified) - -|`exclude_generated` or `excludeGenerated` -|`boolean` - Omits fields that are illegal to set on transform PUT - -|=== - -[discrete] -=== transform.getTransformStats +==== get_transform_stats +Retrieves usage information for transforms. +https://www.elastic.co/guide/en/elasticsearch/reference/current/get-transform-stats.html[Endpoint documentation] [source,ts] ---- -client.transform.getTransformStats({ - transform_id: string, - from: number, - size: number, - allow_no_match: boolean -}) +client.transform.getTransformStats(...) ---- -link:{ref}/get-transform-stats.html[Documentation] + -[cols=2*] -|=== -|`transform_id` or `transformId` -|`string` - The id of the transform for which to get stats. '_all' or '*' implies all transforms - -|`from` -|`number` - skips a number of transform stats, defaults to 0 -|`size` -|`number` - specifies a max number of transform stats to get, defaults to 100 - -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no transforms. (This includes `_all` string or when no transforms have been specified) - -|=== - -[discrete] -=== transform.previewTransform +==== preview_transform +Previews a transform. +https://www.elastic.co/guide/en/elasticsearch/reference/current/preview-transform.html[Endpoint documentation] [source,ts] ---- -client.transform.previewTransform({ - body: object -}) +client.transform.previewTransform(...) ---- -link:{ref}/preview-transform.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - The definition for the transform to preview - -|=== -[discrete] -=== transform.putTransform +==== put_transform +Instantiates a transform. +https://www.elastic.co/guide/en/elasticsearch/reference/current/put-transform.html[Endpoint documentation] [source,ts] ---- -client.transform.putTransform({ - transform_id: string, - defer_validation: boolean, - body: object -}) +client.transform.putTransform(...) ---- -link:{ref}/put-transform.html[Documentation] + -[cols=2*] -|=== -|`transform_id` or `transformId` -|`string` - The id of the new transform. -|`defer_validation` or `deferValidation` -|`boolean` - If validations should be deferred until transform starts, defaults to false. - -|`body` -|`object` - The transform definition - -|=== - -[discrete] -=== transform.startTransform +==== reset_transform +Resets an existing transform. +https://www.elastic.co/guide/en/elasticsearch/reference/current/reset-transform.html[Endpoint documentation] [source,ts] ---- -client.transform.startTransform({ - transform_id: string, - timeout: string -}) +client.transform.resetTransform(...) ---- -link:{ref}/start-transform.html[Documentation] + -[cols=2*] -|=== -|`transform_id` or `transformId` -|`string` - The id of the transform to start - -|`timeout` -|`string` - Controls the time to wait for the transform to start -|=== - -[discrete] -=== transform.stopTransform +==== start_transform +Starts one or more transforms. +https://www.elastic.co/guide/en/elasticsearch/reference/current/start-transform.html[Endpoint documentation] [source,ts] ---- -client.transform.stopTransform({ - transform_id: string, - force: boolean, - wait_for_completion: boolean, - timeout: string, - allow_no_match: boolean, - wait_for_checkpoint: boolean -}) +client.transform.startTransform(...) ---- -link:{ref}/stop-transform.html[Documentation] + -[cols=2*] -|=== -|`transform_id` or `transformId` -|`string` - The id of the transform to stop - -|`force` -|`boolean` - Whether to force stop a failed transform or not. Default to false - -|`wait_for_completion` or `waitForCompletion` -|`boolean` - Whether to wait for the transform to fully stop before returning or not. Default to false - -|`timeout` -|`string` - Controls the time to wait until the transform has stopped. Default to 30 seconds -|`allow_no_match` or `allowNoMatch` -|`boolean` - Whether to ignore if a wildcard expression matches no transforms. (This includes `_all` string or when no transforms have been specified) - -|`wait_for_checkpoint` or `waitForCheckpoint` -|`boolean` - Whether to wait for the transform to reach a checkpoint before stopping. Default to false - -|=== - -[discrete] -=== transform.updateTransform +==== stop_transform +Stops one or more transforms. +https://www.elastic.co/guide/en/elasticsearch/reference/current/stop-transform.html[Endpoint documentation] [source,ts] ---- -client.transform.updateTransform({ - transform_id: string, - defer_validation: boolean, - body: object -}) +client.transform.stopTransform(...) ---- -link:{ref}/update-transform.html[Documentation] + -[cols=2*] -|=== -|`transform_id` or `transformId` -|`string` - The id of the transform. - -|`defer_validation` or `deferValidation` -|`boolean` - If validations should be deferred until transform starts, defaults to false. -|`body` -|`object` - The update transform definition - -|=== - -[discrete] -=== update +==== update_transform +Updates certain properties of a transform. +https://www.elastic.co/guide/en/elasticsearch/reference/current/update-transform.html[Endpoint documentation] [source,ts] ---- -client.update({ - id: string, - index: string, - type: string, - wait_for_active_shards: string, - _source: string | string[], - _source_excludes: string | string[], - _source_includes: string | string[], - lang: string, - refresh: 'true' | 'false' | 'wait_for', - retry_on_conflict: number, - routing: string, - timeout: string, - if_seq_no: number, - if_primary_term: number, - require_alias: boolean, - body: object -}) ----- -link:{ref}/docs-update.html[Documentation] + -{jsclient}/update_examples.html[Code Example] + -[cols=2*] -|=== -|`id` -|`string` - Document ID - -|`index` -|`string` - The name of the index - -|`type` -|`string` - The type of the document + - -WARNING: This parameter has been deprecated. - -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Sets the number of shard copies that must be active before proceeding with the update operation. Defaults to 1, meaning the primary shard only. Set to `all` for all shard copies, otherwise set to any non-negative value less than or equal to the total number of copies for the shard (number of replicas + 1) - -|`_source` -|`string \| string[]` - True or false to return the _source field or not, or a list of fields to return - -|`_source_excludes` or `_sourceExcludes` -|`string \| string[]` - A list of fields to exclude from the returned _source field - -|`_source_includes` or `_sourceIncludes` -|`string \| string[]` - A list of fields to extract and return from the _source field - -|`lang` -|`string` - The script language (default: painless) - -|`refresh` -|`'true' \| 'false' \| 'wait_for'` - If `true` then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` (the default) then do nothing with refreshes. - -|`retry_on_conflict` or `retryOnConflict` -|`number` - Specify how many times should the operation be retried when a conflict occurs (default: 0) - -|`routing` -|`string` - Specific routing value - -|`timeout` -|`string` - Explicit operation timeout - -|`if_seq_no` or `ifSeqNo` -|`number` - only perform the update operation if the last operation that has changed the document has the specified sequence number - -|`if_primary_term` or `ifPrimaryTerm` -|`number` - only perform the update operation if the last operation that has changed the document has the specified primary term - -|`require_alias` or `requireAlias` -|`boolean` - When true, requires destination is an alias. Default is false - -|`body` -|`object` - The request definition requires either `script` or partial `doc` - -|=== - -[discrete] -=== updateByQuery - -[source,ts] ----- -client.updateByQuery({ - index: string | string[], - analyzer: string, - analyze_wildcard: boolean, - default_operator: 'AND' | 'OR', - df: string, - from: number, - ignore_unavailable: boolean, - allow_no_indices: boolean, - conflicts: 'abort' | 'proceed', - expand_wildcards: 'open' | 'closed' | 'hidden' | 'none' | 'all', - lenient: boolean, - pipeline: string, - preference: string, - q: string, - routing: string | string[], - scroll: string, - search_type: 'query_then_fetch' | 'dfs_query_then_fetch', - search_timeout: string, - max_docs: number, - sort: string | string[], - _source: string | string[], - _source_excludes: string | string[], - _source_includes: string | string[], - terminate_after: number, - stats: string | string[], - version: boolean, - version_type: boolean, - request_cache: boolean, - refresh: boolean, - timeout: string, - wait_for_active_shards: string, - scroll_size: number, - wait_for_completion: boolean, - requests_per_second: number, - slices: number|string, - body: object -}) +client.transform.updateTransform(...) ---- -link:{ref}/docs-update-by-query.html[Documentation] + -{jsclient}/update_by_query_examples.html[Code Example] + -[cols=2*] -|=== -|`index` -|`string \| string[]` - A comma-separated list of index names to search; use `_all` or empty string to perform the operation on all indices - -|`analyzer` -|`string` - The analyzer to use for the query string - -|`analyze_wildcard` or `analyzeWildcard` -|`boolean` - Specify whether wildcard and prefix queries should be analyzed (default: false) - -|`default_operator` or `defaultOperator` -|`'AND' \| 'OR'` - The default operator for query string query (AND or OR) + -_Default:_ `OR` - -|`df` -|`string` - The field to use as default where no field prefix is given in the query string - -|`from` -|`number` - Starting offset (default: 0) - -|`ignore_unavailable` or `ignoreUnavailable` -|`boolean` - Whether specified concrete indices should be ignored when unavailable (missing or closed) - -|`allow_no_indices` or `allowNoIndices` -|`boolean` - Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) - -|`conflicts` -|`'abort' \| 'proceed'` - What to do when the update by query hits version conflicts? + -_Default:_ `abort` - -|`expand_wildcards` or `expandWildcards` -|`'open' \| 'closed' \| 'hidden' \| 'none' \| 'all'` - Whether to expand wildcard expression to concrete indices that are open, closed or both. + -_Default:_ `open` - -|`lenient` -|`boolean` - Specify whether format-based query failures (such as providing text to a numeric field) should be ignored - -|`pipeline` -|`string` - Ingest pipeline to set on index requests made by this action. (default: none) - -|`preference` -|`string` - Specify the node or shard the operation should be performed on (default: random) - -|`q` -|`string` - Query in the Lucene query string syntax - -|`routing` -|`string \| string[]` - A comma-separated list of specific routing values - -|`scroll` -|`string` - Specify how long a consistent view of the index should be maintained for scrolled search - -|`search_type` or `searchType` -|`'query_then_fetch' \| 'dfs_query_then_fetch'` - Search operation type - -|`search_timeout` or `searchTimeout` -|`string` - Explicit timeout for each search request. Defaults to no timeout. - -|`max_docs` or `maxDocs` -|`number` - Maximum number of documents to process (default: all documents) - -|`sort` -|`string \| string[]` - A comma-separated list of : pairs - -|`_source` -|`string \| string[]` - True or false to return the _source field or not, or a list of fields to return - -|`_source_excludes` or `_sourceExcludes` -|`string \| string[]` - A list of fields to exclude from the returned _source field - -|`_source_includes` or `_sourceIncludes` -|`string \| string[]` - A list of fields to extract and return from the _source field - -|`terminate_after` or `terminateAfter` -|`number` - The maximum number of documents to collect for each shard, upon reaching which the query execution will terminate early. - -|`stats` -|`string \| string[]` - Specific 'tag' of the request for logging and statistical purposes - -|`version` -|`boolean` - Specify whether to return document version as part of a hit - -|`version_type` or `versionType` -|`boolean` - Should the document increment the version number (internal) on hit or not (reindex) - -|`request_cache` or `requestCache` -|`boolean` - Specify if request cache should be used for this request or not, defaults to index level setting - -|`refresh` -|`boolean` - Should the affected indexes be refreshed? - -|`timeout` -|`string` - Time each individual bulk request should wait for shards that are unavailable. + -_Default:_ `1m` -|`wait_for_active_shards` or `waitForActiveShards` -|`string` - Sets the number of shard copies that must be active before proceeding with the update by query operation. Defaults to 1, meaning the primary shard only. Set to `all` for all shard copies, otherwise set to any non-negative value less than or equal to the total number of copies for the shard (number of replicas + 1) - -|`scroll_size` or `scrollSize` -|`number` - Size on the scroll request powering the update by query + -_Default:_ `100` - -|`wait_for_completion` or `waitForCompletion` -|`boolean` - Should the request should block until the update by query operation is complete. + -_Default:_ `true` - -|`requests_per_second` or `requestsPerSecond` -|`number` - The throttle to set on this request in sub-requests per second. -1 means no throttle. - -|`slices` -|`number\|string` - The number of slices this task should be divided into. Defaults to 1, meaning the task isn't sliced into subtasks. Can be set to `auto`. + -_Default:_ `1` - -|`body` -|`object` - The search definition using the Query DSL - -|=== - -[discrete] -=== updateByQueryRethrottle +==== upgrade_transforms +Upgrades all transforms. +https://www.elastic.co/guide/en/elasticsearch/reference/current/upgrade-transforms.html[Endpoint documentation] [source,ts] ---- -client.updateByQueryRethrottle({ - task_id: string, - requests_per_second: number -}) +client.transform.upgradeTransforms(...) ---- -link:{ref}/docs-update-by-query.html[Documentation] + -[cols=2*] -|=== -|`task_id` or `taskId` -|`string` - The task id to rethrottle - -|`requests_per_second` or `requestsPerSecond` -|`number` - The throttle to set on this request in floating sub-requests per second. -1 means set no throttle. -|=== - -[discrete] -=== watcher.ackWatch +=== watcher +==== ack_watch +Acknowledges a watch, manually throttling the execution of the watch's actions. +https://www.elastic.co/guide/en/elasticsearch/reference/current/watcher-api-ack-watch.html[Endpoint documentation] [source,ts] ---- -client.watcher.ackWatch({ - watch_id: string, - action_id: string | string[] -}) +client.watcher.ackWatch(...) ---- -link:{ref}/watcher-api-ack-watch.html[Documentation] + -[cols=2*] -|=== -|`watch_id` or `watchId` -|`string` - Watch ID - -|`action_id` or `actionId` -|`string \| string[]` - A comma-separated list of the action ids to be acked -|=== - -[discrete] -=== watcher.activateWatch +==== activate_watch +Activates a currently inactive watch. +https://www.elastic.co/guide/en/elasticsearch/reference/current/watcher-api-activate-watch.html[Endpoint documentation] [source,ts] ---- -client.watcher.activateWatch({ - watch_id: string -}) +client.watcher.activateWatch(...) ---- -link:{ref}/watcher-api-activate-watch.html[Documentation] + -[cols=2*] -|=== -|`watch_id` or `watchId` -|`string` - Watch ID - -|=== -[discrete] -=== watcher.deactivateWatch +==== deactivate_watch +Deactivates a currently active watch. +https://www.elastic.co/guide/en/elasticsearch/reference/current/watcher-api-deactivate-watch.html[Endpoint documentation] [source,ts] ---- -client.watcher.deactivateWatch({ - watch_id: string -}) +client.watcher.deactivateWatch(...) ---- -link:{ref}/watcher-api-deactivate-watch.html[Documentation] + -[cols=2*] -|=== -|`watch_id` or `watchId` -|`string` - Watch ID -|=== - -[discrete] -=== watcher.deleteWatch +==== delete_watch +Removes a watch from Watcher. +https://www.elastic.co/guide/en/elasticsearch/reference/current/watcher-api-delete-watch.html[Endpoint documentation] [source,ts] ---- -client.watcher.deleteWatch({ - id: string -}) +client.watcher.deleteWatch(...) ---- -link:{ref}/watcher-api-delete-watch.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - Watch ID - -|=== -[discrete] -=== watcher.executeWatch +==== execute_watch +Forces the execution of a stored watch. +https://www.elastic.co/guide/en/elasticsearch/reference/current/watcher-api-execute-watch.html[Endpoint documentation] [source,ts] ---- -client.watcher.executeWatch({ - id: string, - debug: boolean, - body: object -}) +client.watcher.executeWatch(...) ---- -link:{ref}/watcher-api-execute-watch.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - Watch ID - -|`debug` -|`boolean` - indicates whether the watch should execute in debug mode - -|`body` -|`object` - Execution control -|=== - -[discrete] -=== watcher.getWatch +==== get_watch +Retrieves a watch by its ID. +https://www.elastic.co/guide/en/elasticsearch/reference/current/watcher-api-get-watch.html[Endpoint documentation] [source,ts] ---- -client.watcher.getWatch({ - id: string -}) +client.watcher.getWatch(...) ---- -link:{ref}/watcher-api-get-watch.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - Watch ID - -|=== -[discrete] -=== watcher.putWatch +==== put_watch +Creates a new watch, or updates an existing one. +https://www.elastic.co/guide/en/elasticsearch/reference/current/watcher-api-put-watch.html[Endpoint documentation] [source,ts] ---- -client.watcher.putWatch({ - id: string, - active: boolean, - version: number, - if_seq_no: number, - if_primary_term: number, - body: object -}) +client.watcher.putWatch(...) ---- -link:{ref}/watcher-api-put-watch.html[Documentation] + -[cols=2*] -|=== -|`id` -|`string` - Watch ID - -|`active` -|`boolean` - Specify whether the watch is in/active by default - -|`version` -|`number` - Explicit version number for concurrency control - -|`if_seq_no` or `ifSeqNo` -|`number` - only update the watch if the last operation that has changed the watch has the specified sequence number - -|`if_primary_term` or `ifPrimaryTerm` -|`number` - only update the watch if the last operation that has changed the watch has the specified primary term - -|`body` -|`object` - The watch - -|=== -[discrete] -=== watcher.queryWatches +==== query_watches +Retrieves stored watches. +https://www.elastic.co/guide/en/elasticsearch/reference/current/watcher-api-query-watches.html[Endpoint documentation] [source,ts] ---- -client.watcher.queryWatches({ - body: object -}) +client.watcher.queryWatches(...) ---- -link:{ref}/watcher-api-query-watches.html[Documentation] + -[cols=2*] -|=== -|`body` -|`object` - From, size, query, sort and search_after -|=== - -[discrete] -=== watcher.start +==== start +Starts Watcher if it is not already running. +https://www.elastic.co/guide/en/elasticsearch/reference/current/watcher-api-start.html[Endpoint documentation] [source,ts] ---- -client.watcher.start() +client.watcher.start(...) ---- -link:{ref}/watcher-api-start.html[Documentation] + - -[discrete] -=== watcher.stats +==== stats +Retrieves the current Watcher metrics. +https://www.elastic.co/guide/en/elasticsearch/reference/current/watcher-api-stats.html[Endpoint documentation] [source,ts] ---- -client.watcher.stats({ - metric: string | string[], - emit_stacktraces: boolean -}) +client.watcher.stats(...) ---- -link:{ref}/watcher-api-stats.html[Documentation] + -[cols=2*] -|=== -|`metric` -|`string \| string[]` - Controls what additional stat metrics should be include in the response - -|`emit_stacktraces` or `emitStacktraces` -|`boolean` - Emits stack traces of currently running watches - -|=== -[discrete] -=== watcher.stop +==== stop +Stops Watcher if it is running. +https://www.elastic.co/guide/en/elasticsearch/reference/current/watcher-api-stop.html[Endpoint documentation] [source,ts] ---- -client.watcher.stop() +client.watcher.stop(...) ---- -link:{ref}/watcher-api-stop.html[Documentation] + +=== xpack +==== info +Retrieves information about the installed X-Pack features. -[discrete] -=== xpack.info - +https://www.elastic.co/guide/en/elasticsearch/reference/current/info-api.html[Endpoint documentation] [source,ts] ---- -client.xpack.info({ - categories: string | string[], - accept_enterprise: boolean -}) +client.xpack.info(...) ---- -link:{ref}/info-api.html[Documentation] + -[cols=2*] -|=== -|`categories` -|`string \| string[]` - Comma-separated list of info categories. Can be any of: build, license, features - -|`accept_enterprise` or `acceptEnterprise` -|`boolean` - If this param is used it must be set to true + - -WARNING: This parameter has been deprecated. - -|=== -[discrete] -=== xpack.usage +==== usage +Retrieves usage information about the installed X-Pack features. +https://www.elastic.co/guide/en/elasticsearch/reference/current/usage-api.html[Endpoint documentation] [source,ts] ---- -client.xpack.usage({ - master_timeout: string -}) +client.xpack.usage(...) ---- -link:{ref}/usage-api.html[Documentation] + -[cols=2*] -|=== -|`master_timeout` or `masterTimeout` -|`string` - Specify timeout for watch write operation -|=== From c89586e3caed891b8134588cc69cd0833c56b5e8 Mon Sep 17 00:00:00 2001 From: delvedor Date: Thu, 3 Mar 2022 11:37:49 +0100 Subject: [PATCH 2/3] Fix titles --- docs/reference.asciidoc | 86 ++++++++++++++++++++--------------------- 1 file changed, 43 insertions(+), 43 deletions(-) diff --git a/docs/reference.asciidoc b/docs/reference.asciidoc index c13867584..93c332d54 100644 --- a/docs/reference.asciidoc +++ b/docs/reference.asciidoc @@ -25,7 +25,7 @@ //////// == API Reference -==== bulk +=== bulk Allows to perform multiple index/update/delete operations in a single request. https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-bulk.html[Endpoint documentation] @@ -34,7 +34,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-bulk.html[En client.bulk(...) ---- -==== clear_scroll +=== clear_scroll Explicitly clears the search context for a scroll. https://www.elastic.co/guide/en/elasticsearch/reference/master/clear-scroll-api.html[Endpoint documentation] @@ -43,7 +43,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/clear-scroll-api. client.clearScroll(...) ---- -==== close_point_in_time +=== close_point_in_time Close a point in time https://www.elastic.co/guide/en/elasticsearch/reference/master/point-in-time-api.html[Endpoint documentation] @@ -52,7 +52,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/point-in-time-api client.closePointInTime(...) ---- -==== count +=== count Returns number of documents matching a query. https://www.elastic.co/guide/en/elasticsearch/reference/master/search-count.html[Endpoint documentation] @@ -61,7 +61,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/search-count.html client.count(...) ---- -==== create +=== create Creates a new document in the index. Returns a 409 response when a document with a same ID already exists in the index. @@ -72,7 +72,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-index_.html[ client.create(...) ---- -==== delete +=== delete Removes a document from the index. https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-delete.html[Endpoint documentation] @@ -81,7 +81,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-delete.html[ client.delete(...) ---- -==== delete_by_query +=== delete_by_query Deletes documents matching the provided query. https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-delete-by-query.html[Endpoint documentation] @@ -90,7 +90,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-delete-by-qu client.deleteByQuery(...) ---- -==== delete_by_query_rethrottle +=== delete_by_query_rethrottle Changes the number of requests per second for a particular Delete By Query operation. https://www.elastic.co/guide/en/elasticsearch/reference/current/docs-delete-by-query.html[Endpoint documentation] @@ -99,7 +99,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/current/docs-delete-by-q client.deleteByQueryRethrottle(...) ---- -==== delete_script +=== delete_script Deletes a script. https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting.html[Endpoint documentation] @@ -108,7 +108,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting client.deleteScript(...) ---- -==== exists +=== exists Returns information about whether a document exists in an index. https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html[Endpoint documentation] @@ -117,7 +117,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html[End client.exists(...) ---- -==== exists_source +=== exists_source Returns information about whether a document source exists in an index. https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html[Endpoint documentation] @@ -126,7 +126,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html[End client.existsSource(...) ---- -==== explain +=== explain Returns information about why a specific matches (or doesn't match) a query. https://www.elastic.co/guide/en/elasticsearch/reference/master/search-explain.html[Endpoint documentation] @@ -135,7 +135,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/search-explain.ht client.explain(...) ---- -==== field_caps +=== field_caps Returns the information about the capabilities of fields among multiple indices. https://www.elastic.co/guide/en/elasticsearch/reference/master/search-field-caps.html[Endpoint documentation] @@ -144,7 +144,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/search-field-caps client.fieldCaps(...) ---- -==== get +=== get Returns a document. https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html[Endpoint documentation] @@ -153,7 +153,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html[End client.get(...) ---- -==== get_script +=== get_script Returns a script. https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting.html[Endpoint documentation] @@ -162,7 +162,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting client.getScript(...) ---- -==== get_script_context +=== get_script_context Returns all script contexts. https://www.elastic.co/guide/en/elasticsearch/painless/master/painless-contexts.html[Endpoint documentation] @@ -171,7 +171,7 @@ https://www.elastic.co/guide/en/elasticsearch/painless/master/painless-contexts. client.getScriptContext(...) ---- -==== get_script_languages +=== get_script_languages Returns available script types, languages and contexts https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting.html[Endpoint documentation] @@ -180,7 +180,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting client.getScriptLanguages(...) ---- -==== get_source +=== get_source Returns the source of a document. https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html[Endpoint documentation] @@ -189,7 +189,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html[End client.getSource(...) ---- -==== index +=== index Creates or updates a document in an index. https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-index_.html[Endpoint documentation] @@ -198,7 +198,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-index_.html[ client.index(...) ---- -==== info +=== info Returns basic information about the cluster. https://www.elastic.co/guide/en/elasticsearch/reference/current/index.html[Endpoint documentation] @@ -207,7 +207,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/current/index.html[Endpo client.info(...) ---- -==== knn_search +=== knn_search Performs a kNN search. https://www.elastic.co/guide/en/elasticsearch/reference/master/search-search.html[Endpoint documentation] @@ -216,7 +216,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/search-search.htm client.knnSearch(...) ---- -==== mget +=== mget Allows to get multiple documents in one request. https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-multi-get.html[Endpoint documentation] @@ -225,7 +225,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-multi-get.ht client.mget(...) ---- -==== msearch +=== msearch Allows to execute several search operations in one request. https://www.elastic.co/guide/en/elasticsearch/reference/master/search-multi-search.html[Endpoint documentation] @@ -234,7 +234,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/search-multi-sear client.msearch(...) ---- -==== msearch_template +=== msearch_template Allows to execute several search template operations in one request. https://www.elastic.co/guide/en/elasticsearch/reference/current/search-multi-search.html[Endpoint documentation] @@ -243,7 +243,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/current/search-multi-sea client.msearchTemplate(...) ---- -==== mtermvectors +=== mtermvectors Returns multiple termvectors in one request. https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-multi-termvectors.html[Endpoint documentation] @@ -252,7 +252,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-multi-termve client.mtermvectors(...) ---- -==== open_point_in_time +=== open_point_in_time Open a point in time that can be used in subsequent searches https://www.elastic.co/guide/en/elasticsearch/reference/master/point-in-time-api.html[Endpoint documentation] @@ -261,7 +261,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/point-in-time-api client.openPointInTime(...) ---- -==== ping +=== ping Returns whether the cluster is running. https://www.elastic.co/guide/en/elasticsearch/reference/current/index.html[Endpoint documentation] @@ -270,7 +270,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/current/index.html[Endpo client.ping(...) ---- -==== put_script +=== put_script Creates or updates a script. https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting.html[Endpoint documentation] @@ -279,7 +279,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting client.putScript(...) ---- -==== rank_eval +=== rank_eval Allows to evaluate the quality of ranked search results over a set of typical search queries https://www.elastic.co/guide/en/elasticsearch/reference/master/search-rank-eval.html[Endpoint documentation] @@ -288,7 +288,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/search-rank-eval. client.rankEval(...) ---- -==== reindex +=== reindex Allows to copy documents from one index to another, optionally filtering the source documents by a query, changing the destination index settings, or fetching the documents from a remote cluster. @@ -299,7 +299,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-reindex.html client.reindex(...) ---- -==== reindex_rethrottle +=== reindex_rethrottle Changes the number of requests per second for a particular Reindex operation. https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-reindex.html[Endpoint documentation] @@ -308,7 +308,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-reindex.html client.reindexRethrottle(...) ---- -==== render_search_template +=== render_search_template Allows to use the Mustache language to pre-render a search definition. https://www.elastic.co/guide/en/elasticsearch/reference/current/render-search-template-api.html[Endpoint documentation] @@ -317,7 +317,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/current/render-search-te client.renderSearchTemplate(...) ---- -==== scripts_painless_execute +=== scripts_painless_execute Allows an arbitrary script to be executed and a result to be returned https://www.elastic.co/guide/en/elasticsearch/painless/master/painless-execute-api.html[Endpoint documentation] @@ -326,7 +326,7 @@ https://www.elastic.co/guide/en/elasticsearch/painless/master/painless-execute-a client.scriptsPainlessExecute(...) ---- -==== scroll +=== scroll Allows to retrieve a large numbers of results from a single search request. https://www.elastic.co/guide/en/elasticsearch/reference/master/search-request-body.html#request-body-search-scroll[Endpoint documentation] @@ -335,7 +335,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/search-request-bo client.scroll(...) ---- -==== search +=== search Returns results matching a query. https://www.elastic.co/guide/en/elasticsearch/reference/master/search-search.html[Endpoint documentation] @@ -344,7 +344,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/search-search.htm client.search(...) ---- -==== search_mvt +=== search_mvt Searches a vector tile for geospatial values. Returns results as a binary Mapbox vector tile. https://www.elastic.co/guide/en/elasticsearch/reference/master/search-vector-tile-api.html[Endpoint documentation] @@ -353,7 +353,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/search-vector-til client.searchMvt(...) ---- -==== search_shards +=== search_shards Returns information about the indices and shards that a search request would be executed against. https://www.elastic.co/guide/en/elasticsearch/reference/master/search-shards.html[Endpoint documentation] @@ -362,7 +362,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/search-shards.htm client.searchShards(...) ---- -==== search_template +=== search_template Allows to use the Mustache language to pre-render a search definition. https://www.elastic.co/guide/en/elasticsearch/reference/current/search-template.html[Endpoint documentation] @@ -371,7 +371,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/current/search-template. client.searchTemplate(...) ---- -==== terms_enum +=== terms_enum The terms enum API can be used to discover terms in the index that begin with the provided string. It is designed for low-latency look-ups used in auto-complete scenarios. https://www.elastic.co/guide/en/elasticsearch/reference/current/search-terms-enum.html[Endpoint documentation] @@ -380,7 +380,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/current/search-terms-enu client.termsEnum(...) ---- -==== termvectors +=== termvectors Returns information and statistics about terms in the fields of a particular document. https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-termvectors.html[Endpoint documentation] @@ -389,7 +389,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-termvectors. client.termvectors(...) ---- -==== update +=== update Updates a document with a script or partial document. https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-update.html[Endpoint documentation] @@ -398,7 +398,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-update.html[ client.update(...) ---- -==== update_by_query +=== update_by_query Performs an update on every document in the index without changing the source, for example to pick up a mapping change. @@ -408,7 +408,7 @@ https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-update-by-qu client.updateByQuery(...) ---- -==== update_by_query_rethrottle +=== update_by_query_rethrottle Changes the number of requests per second for a particular Update By Query operation. https://www.elastic.co/guide/en/elasticsearch/reference/current/docs-update-by-query.html[Endpoint documentation] From 97470fc133a3629548b432fd7d797f955ebccc45 Mon Sep 17 00:00:00 2001 From: delvedor Date: Thu, 3 Mar 2022 12:33:45 +0100 Subject: [PATCH 3/3] Fix links --- docs/reference.asciidoc | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/docs/reference.asciidoc b/docs/reference.asciidoc index 93c332d54..4c82b6382 100644 --- a/docs/reference.asciidoc +++ b/docs/reference.asciidoc @@ -2127,8 +2127,6 @@ client.ml.getJobs(...) ==== get_memory_stats Returns information on how ML is using memory. - -https://www.elastic.co/guide/en/elasticsearch/reference/current/get-ml-memory.html[Endpoint documentation] [source,ts] ---- client.ml.getMemoryStats(...) @@ -2662,8 +2660,6 @@ client.searchableSnapshots.stats(...) === security ==== activate_user_profile Creates or updates the user profile on behalf of another user. - -https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-activate-user-profile.html[Endpoint documentation] [source,ts] ---- client.security.activateUserProfile(...) @@ -2923,8 +2919,6 @@ client.security.getUserPrivileges(...) ==== get_user_profile Retrieves user profile for the given unique ID. - -https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-get-user-profile.html[Endpoint documentation] [source,ts] ---- client.security.getUserProfile(...) @@ -3094,8 +3088,6 @@ client.security.samlServiceProviderMetadata(...) ==== update_user_profile_data Update application specific data for the user profile of the given unique ID. - -https://www.elastic.co/guide/en/elasticsearch/reference/current/security-api-update-user-profile-data.html[Endpoint documentation] [source,ts] ---- client.security.updateUserProfileData(...) @@ -3443,8 +3435,6 @@ client.transform.putTransform(...) ==== reset_transform Resets an existing transform. - -https://www.elastic.co/guide/en/elasticsearch/reference/current/reset-transform.html[Endpoint documentation] [source,ts] ---- client.transform.resetTransform(...)