From 6da9268fa1dfb9aeaefe0713bc6945004d5d7a72 Mon Sep 17 00:00:00 2001 From: Elastic Machine Date: Mon, 3 Feb 2025 06:03:54 +0000 Subject: [PATCH] Auto-generated API code --- .../00ad41bde67beac991534ae0e04b1296.asciidoc | 11 + .../0f028f71f04c1d569fab402869565a84.asciidoc | 15 + .../12adea5d76f73d94d80d42f53f67563f.asciidoc | 11 + .../1ead35c954963e83f89872048dabdbe9.asciidoc | 19 + .../272e27bf1fcc4fe5dbd4092679dd0342.asciidoc | 11 + ...2afd49985950cbcccf727fa858d00067.asciidoc} | 6 +- .../31832bd71c31c46a1ccf8d1c210d89d4.asciidoc | 28 + .../32c8c86702ccd68eb70f1573409c2a1f.asciidoc | 31 + ...36792c81c053e0555407d1e83e7e054f.asciidoc} | 5 +- .../3722dad876023e0757138dd5a6d3240e.asciidoc | 23 + .../3a204b57072a104d9b50f3a9e064a8f6.asciidoc | 19 + .../3bc4a3681e3ea9cb3de49f72085807d8.asciidoc | 61 + .../4de4bb55bbc0a76c75d256f245a3ee3f.asciidoc | 17 + .../537bce129338d9227bccb6a0283dab45.asciidoc | 12 + .../59aa5216630f80c5dc298fc5bba4a819.asciidoc | 10 + .../6baf72c04d48cb04c2f8be609ff3b3b5.asciidoc | 23 + .../6e498b9dc753b94abf2618c407fa5cd8.asciidoc | 16 + .../8621c05cc7cf3880bde751f6670a0c3a.asciidoc | 15 + .../89f547649895176c246bb8c41313ff21.asciidoc | 12 + .../8c47c80139f40f25db44f5781ca2dfbe.asciidoc | 10 + .../a46f566ca031375658c22f89b87dc6d2.asciidoc | 12 + .../a675fafa7c688cb3ea1be09bf887ebf0.asciidoc | 12 + ...ba0e7e0b18fc9ec6c623d40186d1f61b.asciidoc} | 1 + ...bcd1afb793240b1dddd9fa5d3f21192b.asciidoc} | 10 +- .../c3b77e11b16e37e9e37e28dec922432e.asciidoc | 11 + .../d2e7dead222cfbebbd2c21a7cc1893b4.asciidoc | 11 + .../d3a0f648d0fd50b54a4e9ebe363c5047.asciidoc | 44 + .../d6a4548b29e939fb197189c20c7c016f.asciidoc | 17 + .../dd16c9c981551c9da47ebb5ef5105fa0.asciidoc | 57 + ...e715fb8c792bf09ac98f0ceca99beb84.asciidoc} | 4 +- ...f994498dd6576be657dedce2822d2b9e.asciidoc} | 7 + ...ffda10edaa7ce087703193c3cb95a426.asciidoc} | 8 + docs/reference.asciidoc | 1722 ++++++++++------- src/api/api/async_search.ts | 8 +- src/api/api/autoscaling.ts | 8 +- src/api/api/bulk.ts | 2 +- src/api/api/cat.ts | 52 +- src/api/api/ccr.ts | 28 +- src/api/api/clear_scroll.ts | 2 +- src/api/api/close_point_in_time.ts | 2 +- src/api/api/cluster.ts | 34 +- src/api/api/connector.ts | 56 +- src/api/api/count.ts | 4 +- src/api/api/create.ts | 2 +- src/api/api/dangling_indices.ts | 6 +- src/api/api/delete.ts | 2 +- src/api/api/delete_by_query.ts | 2 +- src/api/api/delete_by_query_rethrottle.ts | 2 +- src/api/api/delete_script.ts | 2 +- src/api/api/enrich.ts | 10 +- src/api/api/eql.ts | 8 +- src/api/api/esql.ts | 48 +- src/api/api/exists.ts | 2 +- src/api/api/exists_source.ts | 2 +- src/api/api/explain.ts | 4 +- src/api/api/features.ts | 4 +- src/api/api/field_caps.ts | 2 +- src/api/api/fleet.ts | 4 +- src/api/api/get.ts | 2 +- src/api/api/get_script.ts | 2 +- src/api/api/get_script_context.ts | 2 +- src/api/api/get_script_languages.ts | 2 +- src/api/api/get_source.ts | 2 +- src/api/api/graph.ts | 2 +- src/api/api/health_report.ts | 2 +- src/api/api/ilm.ts | 22 +- src/api/api/index.ts | 2 +- src/api/api/indices.ts | 136 +- src/api/api/inference.ts | 14 +- src/api/api/info.ts | 2 +- src/api/api/ingest.ts | 18 +- src/api/api/knn_search.ts | 4 +- src/api/api/license.ts | 16 +- src/api/api/logstash.ts | 6 +- src/api/api/mget.ts | 4 +- src/api/api/migration.ts | 6 +- src/api/api/ml.ts | 154 +- src/api/api/monitoring.ts | 2 +- src/api/api/msearch.ts | 2 +- src/api/api/msearch_template.ts | 4 +- src/api/api/mtermvectors.ts | 4 +- src/api/api/nodes.ts | 14 +- src/api/api/open_point_in_time.ts | 2 +- src/api/api/ping.ts | 2 +- src/api/api/put_script.ts | 2 +- src/api/api/query_rules.ts | 16 +- src/api/api/rank_eval.ts | 2 +- src/api/api/reindex.ts | 2 +- src/api/api/reindex_rethrottle.ts | 2 +- src/api/api/render_search_template.ts | 6 +- src/api/api/rollup.ts | 16 +- src/api/api/scroll.ts | 2 +- src/api/api/search.ts | 2 +- src/api/api/search_application.ts | 20 +- src/api/api/search_mvt.ts | 4 +- src/api/api/search_shards.ts | 4 +- src/api/api/search_template.ts | 2 +- src/api/api/searchable_snapshots.ts | 8 +- src/api/api/security.ts | 128 +- src/api/api/shutdown.ts | 6 +- src/api/api/simulate.ts | 2 +- src/api/api/slm.ts | 18 +- src/api/api/snapshot.ts | 26 +- src/api/api/sql.ts | 12 +- src/api/api/ssl.ts | 2 +- src/api/api/synonyms.ts | 14 +- src/api/api/tasks.ts | 6 +- src/api/api/terms_enum.ts | 4 +- src/api/api/termvectors.ts | 4 +- src/api/api/text_structure.ts | 8 +- src/api/api/transform.ts | 34 +- src/api/api/update.ts | 2 +- src/api/api/update_by_query.ts | 2 +- src/api/api/update_by_query_rethrottle.ts | 2 +- src/api/api/watcher.ts | 26 +- src/api/api/xpack.ts | 4 +- src/api/types.ts | 347 ++-- 117 files changed, 2344 insertions(+), 1386 deletions(-) create mode 100644 docs/doc_examples/00ad41bde67beac991534ae0e04b1296.asciidoc create mode 100644 docs/doc_examples/0f028f71f04c1d569fab402869565a84.asciidoc create mode 100644 docs/doc_examples/12adea5d76f73d94d80d42f53f67563f.asciidoc create mode 100644 docs/doc_examples/1ead35c954963e83f89872048dabdbe9.asciidoc create mode 100644 docs/doc_examples/272e27bf1fcc4fe5dbd4092679dd0342.asciidoc rename docs/doc_examples/{d29031409016b2b798148ef173a196ae.asciidoc => 2afd49985950cbcccf727fa858d00067.asciidoc} (83%) create mode 100644 docs/doc_examples/31832bd71c31c46a1ccf8d1c210d89d4.asciidoc create mode 100644 docs/doc_examples/32c8c86702ccd68eb70f1573409c2a1f.asciidoc rename docs/doc_examples/{37f367ca81a16d3aef4ef7126ec33a2e.asciidoc => 36792c81c053e0555407d1e83e7e054f.asciidoc} (94%) create mode 100644 docs/doc_examples/3722dad876023e0757138dd5a6d3240e.asciidoc create mode 100644 docs/doc_examples/3a204b57072a104d9b50f3a9e064a8f6.asciidoc create mode 100644 docs/doc_examples/3bc4a3681e3ea9cb3de49f72085807d8.asciidoc create mode 100644 docs/doc_examples/4de4bb55bbc0a76c75d256f245a3ee3f.asciidoc create mode 100644 docs/doc_examples/537bce129338d9227bccb6a0283dab45.asciidoc create mode 100644 docs/doc_examples/59aa5216630f80c5dc298fc5bba4a819.asciidoc create mode 100644 docs/doc_examples/6baf72c04d48cb04c2f8be609ff3b3b5.asciidoc create mode 100644 docs/doc_examples/6e498b9dc753b94abf2618c407fa5cd8.asciidoc create mode 100644 docs/doc_examples/8621c05cc7cf3880bde751f6670a0c3a.asciidoc create mode 100644 docs/doc_examples/89f547649895176c246bb8c41313ff21.asciidoc create mode 100644 docs/doc_examples/8c47c80139f40f25db44f5781ca2dfbe.asciidoc create mode 100644 docs/doc_examples/a46f566ca031375658c22f89b87dc6d2.asciidoc create mode 100644 docs/doc_examples/a675fafa7c688cb3ea1be09bf887ebf0.asciidoc rename docs/doc_examples/{357edc9d10e98ed776401c7a439a1a55.asciidoc => ba0e7e0b18fc9ec6c623d40186d1f61b.asciidoc} (94%) rename docs/doc_examples/{436d50b85fc8f0977d02059eec00719b.asciidoc => bcd1afb793240b1dddd9fa5d3f21192b.asciidoc} (65%) create mode 100644 docs/doc_examples/c3b77e11b16e37e9e37e28dec922432e.asciidoc create mode 100644 docs/doc_examples/d2e7dead222cfbebbd2c21a7cc1893b4.asciidoc create mode 100644 docs/doc_examples/d3a0f648d0fd50b54a4e9ebe363c5047.asciidoc create mode 100644 docs/doc_examples/d6a4548b29e939fb197189c20c7c016f.asciidoc create mode 100644 docs/doc_examples/dd16c9c981551c9da47ebb5ef5105fa0.asciidoc rename docs/doc_examples/{8b144b3eb20872595fd7cbc6c245c7c8.asciidoc => e715fb8c792bf09ac98f0ceca99beb84.asciidoc} (67%) rename docs/doc_examples/{9ad0864bcd665b63551e944653d32423.asciidoc => f994498dd6576be657dedce2822d2b9e.asciidoc} (87%) rename docs/doc_examples/{681d24c2633f598fc43d6afff8996dbb.asciidoc => ffda10edaa7ce087703193c3cb95a426.asciidoc} (92%) diff --git a/docs/doc_examples/00ad41bde67beac991534ae0e04b1296.asciidoc b/docs/doc_examples/00ad41bde67beac991534ae0e04b1296.asciidoc new file mode 100644 index 000000000..aad48ff29 --- /dev/null +++ b/docs/doc_examples/00ad41bde67beac991534ae0e04b1296.asciidoc @@ -0,0 +1,11 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.indices.getDataStream({ + name: "my-data-stream", + filter_path: "data_streams.indices.index_name", +}); +console.log(response); +---- diff --git a/docs/doc_examples/0f028f71f04c1d569fab402869565a84.asciidoc b/docs/doc_examples/0f028f71f04c1d569fab402869565a84.asciidoc new file mode 100644 index 000000000..007f558d8 --- /dev/null +++ b/docs/doc_examples/0f028f71f04c1d569fab402869565a84.asciidoc @@ -0,0 +1,15 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.indices.putSettings({ + index: ".reindexed-v9-ml-anomalies-custom-example", + settings: { + index: { + number_of_replicas: "", + }, + }, +}); +console.log(response); +---- diff --git a/docs/doc_examples/12adea5d76f73d94d80d42f53f67563f.asciidoc b/docs/doc_examples/12adea5d76f73d94d80d42f53f67563f.asciidoc new file mode 100644 index 000000000..83d87f9c6 --- /dev/null +++ b/docs/doc_examples/12adea5d76f73d94d80d42f53f67563f.asciidoc @@ -0,0 +1,11 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.indices.addBlock({ + index: ".ml-anomalies-custom-example", + block: "read_only", +}); +console.log(response); +---- diff --git a/docs/doc_examples/1ead35c954963e83f89872048dabdbe9.asciidoc b/docs/doc_examples/1ead35c954963e83f89872048dabdbe9.asciidoc new file mode 100644 index 000000000..347f3152e --- /dev/null +++ b/docs/doc_examples/1ead35c954963e83f89872048dabdbe9.asciidoc @@ -0,0 +1,19 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.security.queryRole({ + query: { + bool: { + must_not: { + term: { + "metadata._reserved": true, + }, + }, + }, + }, + sort: ["name"], +}); +console.log(response); +---- diff --git a/docs/doc_examples/272e27bf1fcc4fe5dbd4092679dd0342.asciidoc b/docs/doc_examples/272e27bf1fcc4fe5dbd4092679dd0342.asciidoc new file mode 100644 index 000000000..5a65c9753 --- /dev/null +++ b/docs/doc_examples/272e27bf1fcc4fe5dbd4092679dd0342.asciidoc @@ -0,0 +1,11 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.indices.addBlock({ + index: ".ml-anomalies-custom-example", + block: "write", +}); +console.log(response); +---- diff --git a/docs/doc_examples/d29031409016b2b798148ef173a196ae.asciidoc b/docs/doc_examples/2afd49985950cbcccf727fa858d00067.asciidoc similarity index 83% rename from docs/doc_examples/d29031409016b2b798148ef173a196ae.asciidoc rename to docs/doc_examples/2afd49985950cbcccf727fa858d00067.asciidoc index fac02d172..38aa159a8 100644 --- a/docs/doc_examples/d29031409016b2b798148ef173a196ae.asciidoc +++ b/docs/doc_examples/2afd49985950cbcccf727fa858d00067.asciidoc @@ -6,13 +6,13 @@ const response = await client.indices.create({ index: "test-index", query: { - semantic: { - field: "my_semantic_field", + match: { + my_field: "Which country is Paris in?", }, }, highlight: { fields: { - my_semantic_field: { + my_field: { type: "semantic", number_of_fragments: 2, order: "score", diff --git a/docs/doc_examples/31832bd71c31c46a1ccf8d1c210d89d4.asciidoc b/docs/doc_examples/31832bd71c31c46a1ccf8d1c210d89d4.asciidoc new file mode 100644 index 000000000..e61007e9c --- /dev/null +++ b/docs/doc_examples/31832bd71c31c46a1ccf8d1c210d89d4.asciidoc @@ -0,0 +1,28 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.search({ + index: "my-index-*", + query: { + bool: { + must: [ + { + match: { + "user.id": "kimchy", + }, + }, + ], + must_not: [ + { + terms: { + _index: ["my-index-01"], + }, + }, + ], + }, + }, +}); +console.log(response); +---- diff --git a/docs/doc_examples/32c8c86702ccd68eb70f1573409c2a1f.asciidoc b/docs/doc_examples/32c8c86702ccd68eb70f1573409c2a1f.asciidoc new file mode 100644 index 000000000..dcc8ff429 --- /dev/null +++ b/docs/doc_examples/32c8c86702ccd68eb70f1573409c2a1f.asciidoc @@ -0,0 +1,31 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.ilm.putLifecycle({ + name: "my_policy", + policy: { + phases: { + hot: { + actions: { + rollover: { + max_primary_shard_size: "50gb", + }, + searchable_snapshot: { + snapshot_repository: "backing_repo", + replicate_for: "14d", + }, + }, + }, + delete: { + min_age: "28d", + actions: { + delete: {}, + }, + }, + }, + }, +}); +console.log(response); +---- diff --git a/docs/doc_examples/37f367ca81a16d3aef4ef7126ec33a2e.asciidoc b/docs/doc_examples/36792c81c053e0555407d1e83e7e054f.asciidoc similarity index 94% rename from docs/doc_examples/37f367ca81a16d3aef4ef7126ec33a2e.asciidoc rename to docs/doc_examples/36792c81c053e0555407d1e83e7e054f.asciidoc index 8651f44c6..2256f4c94 100644 --- a/docs/doc_examples/37f367ca81a16d3aef4ef7126ec33a2e.asciidoc +++ b/docs/doc_examples/36792c81c053e0555407d1e83e7e054f.asciidoc @@ -9,10 +9,13 @@ const response = await client.search({ retriever: { rescorer: { rescore: { + window_size: 50, query: { - window_size: 50, rescore_query: { script_score: { + query: { + match_all: {}, + }, script: { source: "cosineSimilarity(params.queryVector, 'product-vector_final_stage') + 1.0", diff --git a/docs/doc_examples/3722dad876023e0757138dd5a6d3240e.asciidoc b/docs/doc_examples/3722dad876023e0757138dd5a6d3240e.asciidoc new file mode 100644 index 000000000..e071509a9 --- /dev/null +++ b/docs/doc_examples/3722dad876023e0757138dd5a6d3240e.asciidoc @@ -0,0 +1,23 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.indices.create({ + index: "my-index", + settings: { + index: { + number_of_shards: 3, + "blocks.write": true, + }, + }, + mappings: { + properties: { + field1: { + type: "text", + }, + }, + }, +}); +console.log(response); +---- diff --git a/docs/doc_examples/3a204b57072a104d9b50f3a9e064a8f6.asciidoc b/docs/doc_examples/3a204b57072a104d9b50f3a9e064a8f6.asciidoc new file mode 100644 index 000000000..087b6dc1b --- /dev/null +++ b/docs/doc_examples/3a204b57072a104d9b50f3a9e064a8f6.asciidoc @@ -0,0 +1,19 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.search({ + index: ".ml-anomalies-custom-example", + size: 0, + aggs: { + job_ids: { + terms: { + field: "job_id", + size: 100, + }, + }, + }, +}); +console.log(response); +---- diff --git a/docs/doc_examples/3bc4a3681e3ea9cb3de49f72085807d8.asciidoc b/docs/doc_examples/3bc4a3681e3ea9cb3de49f72085807d8.asciidoc new file mode 100644 index 000000000..929ab0ee8 --- /dev/null +++ b/docs/doc_examples/3bc4a3681e3ea9cb3de49f72085807d8.asciidoc @@ -0,0 +1,61 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.search({ + index: "retrievers_example", + retriever: { + linear: { + retrievers: [ + { + retriever: { + standard: { + query: { + function_score: { + query: { + term: { + topic: "ai", + }, + }, + functions: [ + { + script_score: { + script: { + source: "doc['timestamp'].value.millis", + }, + }, + }, + ], + boost_mode: "replace", + }, + }, + sort: { + timestamp: { + order: "asc", + }, + }, + }, + }, + weight: 2, + normalizer: "minmax", + }, + { + retriever: { + knn: { + field: "vector", + query_vector: [0.23, 0.67, 0.89], + k: 3, + num_candidates: 5, + }, + }, + weight: 1.5, + }, + ], + rank_window_size: 10, + }, + }, + _source: false, +}); +console.log(response); +---- diff --git a/docs/doc_examples/4de4bb55bbc0a76c75d256f245a3ee3f.asciidoc b/docs/doc_examples/4de4bb55bbc0a76c75d256f245a3ee3f.asciidoc new file mode 100644 index 000000000..22100f235 --- /dev/null +++ b/docs/doc_examples/4de4bb55bbc0a76c75d256f245a3ee3f.asciidoc @@ -0,0 +1,17 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.inference.put({ + task_type: "sparse_embedding", + inference_id: "elser-model-eis", + inference_config: { + service: "elastic", + service_settings: { + model_name: "elser", + }, + }, +}); +console.log(response); +---- diff --git a/docs/doc_examples/537bce129338d9227bccb6a0283dab45.asciidoc b/docs/doc_examples/537bce129338d9227bccb6a0283dab45.asciidoc new file mode 100644 index 000000000..cfeed0dff --- /dev/null +++ b/docs/doc_examples/537bce129338d9227bccb6a0283dab45.asciidoc @@ -0,0 +1,12 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.cluster.putSettings({ + persistent: { + "migrate.data_stream_reindex_max_request_per_second": 10000, + }, +}); +console.log(response); +---- diff --git a/docs/doc_examples/59aa5216630f80c5dc298fc5bba4a819.asciidoc b/docs/doc_examples/59aa5216630f80c5dc298fc5bba4a819.asciidoc new file mode 100644 index 000000000..61ac89373 --- /dev/null +++ b/docs/doc_examples/59aa5216630f80c5dc298fc5bba4a819.asciidoc @@ -0,0 +1,10 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.indices.getSettings({ + index: ".reindexed-v9-ml-anomalies-custom-example", +}); +console.log(response); +---- diff --git a/docs/doc_examples/6baf72c04d48cb04c2f8be609ff3b3b5.asciidoc b/docs/doc_examples/6baf72c04d48cb04c2f8be609ff3b3b5.asciidoc new file mode 100644 index 000000000..41c42d206 --- /dev/null +++ b/docs/doc_examples/6baf72c04d48cb04c2f8be609ff3b3b5.asciidoc @@ -0,0 +1,23 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.search({ + index: "test-index", + query: { + match: { + my_semantic_field: "Which country is Paris in?", + }, + }, + highlight: { + fields: { + my_semantic_field: { + number_of_fragments: 2, + order: "score", + }, + }, + }, +}); +console.log(response); +---- diff --git a/docs/doc_examples/6e498b9dc753b94abf2618c407fa5cd8.asciidoc b/docs/doc_examples/6e498b9dc753b94abf2618c407fa5cd8.asciidoc new file mode 100644 index 000000000..fdd6ab8f3 --- /dev/null +++ b/docs/doc_examples/6e498b9dc753b94abf2618c407fa5cd8.asciidoc @@ -0,0 +1,16 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.reindex({ + wait_for_completion: "false", + source: { + index: ".ml-anomalies-custom-example", + }, + dest: { + index: ".reindexed-v9-ml-anomalies-custom-example", + }, +}); +console.log(response); +---- diff --git a/docs/doc_examples/8621c05cc7cf3880bde751f6670a0c3a.asciidoc b/docs/doc_examples/8621c05cc7cf3880bde751f6670a0c3a.asciidoc new file mode 100644 index 000000000..7cb4b44d1 --- /dev/null +++ b/docs/doc_examples/8621c05cc7cf3880bde751f6670a0c3a.asciidoc @@ -0,0 +1,15 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.indices.putSettings({ + index: ".reindexed-v9-ml-anomalies-custom-example", + settings: { + index: { + number_of_replicas: 0, + }, + }, +}); +console.log(response); +---- diff --git a/docs/doc_examples/89f547649895176c246bb8c41313ff21.asciidoc b/docs/doc_examples/89f547649895176c246bb8c41313ff21.asciidoc new file mode 100644 index 000000000..571f64436 --- /dev/null +++ b/docs/doc_examples/89f547649895176c246bb8c41313ff21.asciidoc @@ -0,0 +1,12 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.esql.query({ + query: + '\nFROM library\n| EVAL year = DATE_EXTRACT("year", release_date)\n| WHERE page_count > ? AND match(author, ?, {"minimum_should_match": ?})\n| LIMIT 5\n', + params: [300, "Frank Herbert", 2], +}); +console.log(response); +---- diff --git a/docs/doc_examples/8c47c80139f40f25db44f5781ca2dfbe.asciidoc b/docs/doc_examples/8c47c80139f40f25db44f5781ca2dfbe.asciidoc new file mode 100644 index 000000000..680f24481 --- /dev/null +++ b/docs/doc_examples/8c47c80139f40f25db44f5781ca2dfbe.asciidoc @@ -0,0 +1,10 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.indices.getAlias({ + index: ".ml-anomalies-custom-example", +}); +console.log(response); +---- diff --git a/docs/doc_examples/a46f566ca031375658c22f89b87dc6d2.asciidoc b/docs/doc_examples/a46f566ca031375658c22f89b87dc6d2.asciidoc new file mode 100644 index 000000000..f11302fa4 --- /dev/null +++ b/docs/doc_examples/a46f566ca031375658c22f89b87dc6d2.asciidoc @@ -0,0 +1,12 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.cat.indices({ + index: ".ml-anomalies-custom-example", + v: "true", + h: "index,store.size", +}); +console.log(response); +---- diff --git a/docs/doc_examples/a675fafa7c688cb3ea1be09bf887ebf0.asciidoc b/docs/doc_examples/a675fafa7c688cb3ea1be09bf887ebf0.asciidoc new file mode 100644 index 000000000..2837854a9 --- /dev/null +++ b/docs/doc_examples/a675fafa7c688cb3ea1be09bf887ebf0.asciidoc @@ -0,0 +1,12 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.indices.get({ + index: ".migrated-ds-my-data-stream-2025.01.23-000001", + human: "true", + filter_path: "*.settings.index.version.created_string", +}); +console.log(response); +---- diff --git a/docs/doc_examples/357edc9d10e98ed776401c7a439a1a55.asciidoc b/docs/doc_examples/ba0e7e0b18fc9ec6c623d40186d1f61b.asciidoc similarity index 94% rename from docs/doc_examples/357edc9d10e98ed776401c7a439a1a55.asciidoc rename to docs/doc_examples/ba0e7e0b18fc9ec6c623d40186d1f61b.asciidoc index 088bda3bc..42c6d4763 100644 --- a/docs/doc_examples/357edc9d10e98ed776401c7a439a1a55.asciidoc +++ b/docs/doc_examples/ba0e7e0b18fc9ec6c623d40186d1f61b.asciidoc @@ -6,6 +6,7 @@ const response = await client.indices.resolveCluster({ name: "not-present,clust*:my-index*,oldcluster:*", ignore_unavailable: "false", + timeout: "5s", }); console.log(response); ---- diff --git a/docs/doc_examples/436d50b85fc8f0977d02059eec00719b.asciidoc b/docs/doc_examples/bcd1afb793240b1dddd9fa5d3f21192b.asciidoc similarity index 65% rename from docs/doc_examples/436d50b85fc8f0977d02059eec00719b.asciidoc rename to docs/doc_examples/bcd1afb793240b1dddd9fa5d3f21192b.asciidoc index d1a2f84de..5dc68e409 100644 --- a/docs/doc_examples/436d50b85fc8f0977d02059eec00719b.asciidoc +++ b/docs/doc_examples/bcd1afb793240b1dddd9fa5d3f21192b.asciidoc @@ -6,15 +6,11 @@ const response = await client.update({ index: "test", id: 1, - script: { - source: "ctx._source.counter += params.count", - lang: "painless", - params: { - count: 4, - }, + doc: { + product_price: 100, }, upsert: { - counter: 1, + product_price: 50, }, }); console.log(response); diff --git a/docs/doc_examples/c3b77e11b16e37e9e37e28dec922432e.asciidoc b/docs/doc_examples/c3b77e11b16e37e9e37e28dec922432e.asciidoc new file mode 100644 index 000000000..f80f1ac99 --- /dev/null +++ b/docs/doc_examples/c3b77e11b16e37e9e37e28dec922432e.asciidoc @@ -0,0 +1,11 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.esql.query({ + query: + '\nFROM library\n| WHERE match(author, "Frank Herbert", {"minimum_should_match": 2, "operator": "AND"})\n| LIMIT 5\n', +}); +console.log(response); +---- diff --git a/docs/doc_examples/d2e7dead222cfbebbd2c21a7cc1893b4.asciidoc b/docs/doc_examples/d2e7dead222cfbebbd2c21a7cc1893b4.asciidoc new file mode 100644 index 000000000..ff0c652e4 --- /dev/null +++ b/docs/doc_examples/d2e7dead222cfbebbd2c21a7cc1893b4.asciidoc @@ -0,0 +1,11 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.cluster.state({ + metric: "metadata", + filter_path: "metadata.indices.*.system", +}); +console.log(response); +---- diff --git a/docs/doc_examples/d3a0f648d0fd50b54a4e9ebe363c5047.asciidoc b/docs/doc_examples/d3a0f648d0fd50b54a4e9ebe363c5047.asciidoc new file mode 100644 index 000000000..46940cf06 --- /dev/null +++ b/docs/doc_examples/d3a0f648d0fd50b54a4e9ebe363c5047.asciidoc @@ -0,0 +1,44 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.search({ + index: "retrievers_example", + retriever: { + linear: { + retrievers: [ + { + retriever: { + standard: { + query: { + query_string: { + query: "(information retrieval) OR (artificial intelligence)", + default_field: "text", + }, + }, + }, + }, + weight: 2, + normalizer: "minmax", + }, + { + retriever: { + knn: { + field: "vector", + query_vector: [0.23, 0.67, 0.89], + k: 3, + num_candidates: 5, + }, + }, + weight: 1.5, + normalizer: "minmax", + }, + ], + rank_window_size: 10, + }, + }, + _source: false, +}); +console.log(response); +---- diff --git a/docs/doc_examples/d6a4548b29e939fb197189c20c7c016f.asciidoc b/docs/doc_examples/d6a4548b29e939fb197189c20c7c016f.asciidoc new file mode 100644 index 000000000..745cb7efe --- /dev/null +++ b/docs/doc_examples/d6a4548b29e939fb197189c20c7c016f.asciidoc @@ -0,0 +1,17 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.inference.put({ + task_type: "chat_completion", + inference_id: "chat-completion-endpoint", + inference_config: { + service: "elastic", + service_settings: { + model_id: "model-1", + }, + }, +}); +console.log(response); +---- diff --git a/docs/doc_examples/dd16c9c981551c9da47ebb5ef5105fa0.asciidoc b/docs/doc_examples/dd16c9c981551c9da47ebb5ef5105fa0.asciidoc new file mode 100644 index 000000000..c00660b74 --- /dev/null +++ b/docs/doc_examples/dd16c9c981551c9da47ebb5ef5105fa0.asciidoc @@ -0,0 +1,57 @@ +// This file is autogenerated, DO NOT EDIT +// Use `node scripts/generate-docs-examples.js` to generate the docs examples + +[source, js] +---- +const response = await client.indices.updateAliases({ + actions: [ + { + add: { + index: ".reindexed-v9-ml-anomalies-custom-example", + alias: ".ml-anomalies-example1", + filter: { + term: { + job_id: { + value: "example1", + }, + }, + }, + is_hidden: true, + }, + }, + { + add: { + index: ".reindexed-v9-ml-anomalies-custom-example", + alias: ".ml-anomalies-example2", + filter: { + term: { + job_id: { + value: "example2", + }, + }, + }, + is_hidden: true, + }, + }, + { + remove: { + index: ".ml-anomalies-custom-example", + aliases: ".ml-anomalies-*", + }, + }, + { + remove_index: { + index: ".ml-anomalies-custom-example", + }, + }, + { + add: { + index: ".reindexed-v9-ml-anomalies-custom-example", + alias: ".ml-anomalies-custom-example", + is_hidden: true, + }, + }, + ], +}); +console.log(response); +---- diff --git a/docs/doc_examples/8b144b3eb20872595fd7cbc6c245c7c8.asciidoc b/docs/doc_examples/e715fb8c792bf09ac98f0ceca99beb84.asciidoc similarity index 67% rename from docs/doc_examples/8b144b3eb20872595fd7cbc6c245c7c8.asciidoc rename to docs/doc_examples/e715fb8c792bf09ac98f0ceca99beb84.asciidoc index 3bccba38f..1b37d265b 100644 --- a/docs/doc_examples/8b144b3eb20872595fd7cbc6c245c7c8.asciidoc +++ b/docs/doc_examples/e715fb8c792bf09ac98f0ceca99beb84.asciidoc @@ -3,8 +3,8 @@ [source, js] ---- -const response = await client.security.queryRole({ - sort: ["name"], +const response = await client.migration.deprecations({ + index: ".ml-anomalies-*", }); console.log(response); ---- diff --git a/docs/doc_examples/9ad0864bcd665b63551e944653d32423.asciidoc b/docs/doc_examples/f994498dd6576be657dedce2822d2b9e.asciidoc similarity index 87% rename from docs/doc_examples/9ad0864bcd665b63551e944653d32423.asciidoc rename to docs/doc_examples/f994498dd6576be657dedce2822d2b9e.asciidoc index f553c8706..21a737450 100644 --- a/docs/doc_examples/9ad0864bcd665b63551e944653d32423.asciidoc +++ b/docs/doc_examples/f994498dd6576be657dedce2822d2b9e.asciidoc @@ -30,6 +30,13 @@ const response = await client.search({ ], }, }, + highlight: { + fields: { + semantic_text: { + number_of_fragments: 2, + }, + }, + }, }); console.log(response); ---- diff --git a/docs/doc_examples/681d24c2633f598fc43d6afff8996dbb.asciidoc b/docs/doc_examples/ffda10edaa7ce087703193c3cb95a426.asciidoc similarity index 92% rename from docs/doc_examples/681d24c2633f598fc43d6afff8996dbb.asciidoc rename to docs/doc_examples/ffda10edaa7ce087703193c3cb95a426.asciidoc index bfb21cf32..0ccb2c77a 100644 --- a/docs/doc_examples/681d24c2633f598fc43d6afff8996dbb.asciidoc +++ b/docs/doc_examples/ffda10edaa7ce087703193c3cb95a426.asciidoc @@ -28,6 +28,9 @@ const response = await client.indices.create({ topic: { type: "keyword", }, + timestamp: { + type: "date", + }, }, }, }); @@ -41,6 +44,7 @@ const response1 = await client.index({ text: "Large language models are revolutionizing information retrieval by boosting search precision, deepening contextual understanding, and reshaping user experiences in data-rich environments.", year: 2024, topic: ["llm", "ai", "information_retrieval"], + timestamp: "2021-01-01T12:10:30", }, }); console.log(response1); @@ -53,6 +57,7 @@ const response2 = await client.index({ text: "Artificial intelligence is transforming medicine, from advancing diagnostics and tailoring treatment plans to empowering predictive patient care for improved health outcomes.", year: 2023, topic: ["ai", "medicine"], + timestamp: "2022-01-01T12:10:30", }, }); console.log(response2); @@ -65,6 +70,7 @@ const response3 = await client.index({ text: "AI is redefining security by enabling advanced threat detection, proactive risk analysis, and dynamic defenses against increasingly sophisticated cyber threats.", year: 2024, topic: ["ai", "security"], + timestamp: "2023-01-01T12:10:30", }, }); console.log(response3); @@ -77,6 +83,7 @@ const response4 = await client.index({ text: "Elastic introduces Elastic AI Assistant, the open, generative AI sidekick powered by ESRE to democratize cybersecurity and enable users of every skill level.", year: 2023, topic: ["ai", "elastic", "assistant"], + timestamp: "2024-01-01T12:10:30", }, }); console.log(response4); @@ -89,6 +96,7 @@ const response5 = await client.index({ text: "Learn how to spin up a deployment of our hosted Elasticsearch Service and use Elastic Observability to gain deeper insight into the behavior of your applications and systems.", year: 2024, topic: ["documentation", "observability", "elastic"], + timestamp: "2025-01-01T12:10:30", }, }); console.log(response5); diff --git a/docs/reference.asciidoc b/docs/reference.asciidoc index 62f283b1a..8aee6b840 100644 --- a/docs/reference.asciidoc +++ b/docs/reference.asciidoc @@ -138,7 +138,7 @@ Imagine a `_bulk?refresh=wait_for` request with three documents in it that happe The request will only wait for those three shards to refresh. The other two shards that make up the index do not participate in the `_bulk` request at all. -{ref}/docs-bulk.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-bulk[Endpoint documentation] [source,ts] ---- client.bulk({ ... }) @@ -166,7 +166,7 @@ client.bulk({ ... }) Clear a scrolling search. Clear the search context and results for a scrolling search. -{ref}/clear-scroll-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-clear-scroll[Endpoint documentation] [source,ts] ---- client.clearScroll({ ... }) @@ -185,7 +185,7 @@ The `keep_alive` parameter tells Elasticsearch how long it should persist. A point in time is automatically closed when the `keep_alive` period has elapsed. However, keeping points in time has a cost; close them as soon as they are no longer required for search requests. -{ref}/point-in-time-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-open-point-in-time[Endpoint documentation] [source,ts] ---- client.closePointInTime({ id }) @@ -201,8 +201,8 @@ client.closePointInTime({ id }) Count search results. Get the number of documents matching a query. -The query can either be provided using a simple query string as a parameter or using the Query DSL defined within the request body. -The latter must be nested in a `query` key, which is the same as the search API. +The query can be provided either by using a simple query string as a parameter, or by defining Query DSL within the request body. +The query is optional. When no query is provided, the API uses `match_all` to count all the documents. The count API supports multi-target syntax. You can run a single count API search across multiple data streams and indices. @@ -210,7 +210,7 @@ The operation is broadcast across all shards. For each shard ID group, a replica is chosen and the search is run against it. This means that replicas increase the scalability of the count. -{ref}/search-count.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-count[Endpoint documentation] [source,ts] ---- client.count({ ... }) @@ -220,7 +220,7 @@ client.count({ ... }) * *Request (object):* ** *`index` (Optional, string | string[])*: A list of data streams, indices, and aliases to search. It supports wildcards (`*`). To search all data streams and indices, omit this parameter or use `*` or `_all`. -** *`query` (Optional, { bool, boosting, common, combined_fields, constant_score, dis_max, distance_feature, exists, function_score, fuzzy, geo_bounding_box, geo_distance, geo_polygon, geo_shape, has_child, has_parent, ids, intervals, knn, match, match_all, match_bool_prefix, match_none, match_phrase, match_phrase_prefix, more_like_this, multi_match, nested, parent_id, percolate, pinned, prefix, query_string, range, rank_feature, regexp, rule, script, script_score, semantic, shape, simple_query_string, span_containing, span_field_masking, span_first, span_multi, span_near, span_not, span_or, span_term, span_within, sparse_vector, term, terms, terms_set, text_expansion, weighted_tokens, wildcard, wrapper, type })*: Defines the search definition using the Query DSL. The query is optional, and when not provided, it will use `match_all` to count all the docs. +** *`query` (Optional, { bool, boosting, common, combined_fields, constant_score, dis_max, distance_feature, exists, function_score, fuzzy, geo_bounding_box, geo_distance, geo_polygon, geo_shape, has_child, has_parent, ids, intervals, knn, match, match_all, match_bool_prefix, match_none, match_phrase, match_phrase_prefix, more_like_this, multi_match, nested, parent_id, percolate, pinned, prefix, query_string, range, rank_feature, regexp, rule, script, script_score, semantic, shape, simple_query_string, span_containing, span_field_masking, span_first, span_multi, span_near, span_not, span_or, span_term, span_within, sparse_vector, term, terms, terms_set, text_expansion, weighted_tokens, wildcard, wrapper, type })*: Defines the search query using Query DSL. A request body query cannot be used with the `q` query string parameter. ** *`allow_no_indices` (Optional, boolean)*: If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targeting `foo*,bar*` returns an error if an index starts with `foo` but no index starts with `bar`. ** *`analyzer` (Optional, string)*: The analyzer to use for the query string. This parameter can be used only when the `q` query string parameter is specified. ** *`analyze_wildcard` (Optional, boolean)*: If `true`, wildcard and prefix queries are analyzed. This parameter can be used only when the `q` query string parameter is specified. @@ -234,7 +234,7 @@ client.count({ ... }) ** *`preference` (Optional, string)*: The node or shard the operation should be performed on. By default, it is random. ** *`routing` (Optional, string)*: A custom value used to route operations to a specific shard. ** *`terminate_after` (Optional, number)*: The maximum number of documents to collect for each shard. If a query reaches this limit, Elasticsearch terminates the query early. Elasticsearch collects documents before sorting. IMPORTANT: Use with caution. Elasticsearch applies this parameter to each shard handling the request. When possible, let Elasticsearch perform early termination automatically. Avoid specifying this parameter for requests that target data streams with backing indices across multiple data tiers. -** *`q` (Optional, string)*: The query in Lucene query string syntax. +** *`q` (Optional, string)*: The query in Lucene query string syntax. This parameter cannot be used with a request body. [discrete] === create @@ -311,7 +311,7 @@ It is important to note that this setting greatly reduces the chances of the wri After the write operation is underway, it is still possible for replication to fail on any number of shard copies but still succeed on the primary. The `_shards` section of the API response reveals the number of shard copies on which replication succeeded and failed. -{ref}/docs-index_.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-create[Endpoint documentation] [source,ts] ---- client.create({ id, index }) @@ -373,7 +373,7 @@ The document is not deleted if the correct routing is not specified. The delete operation gets hashed into a specific shard ID. It then gets redirected into the primary shard within that ID group and replicated (if needed) to shard replicas within that ID group. -{ref}/docs-delete.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-delete[Endpoint documentation] [source,ts] ---- client.delete({ id, index }) @@ -476,7 +476,7 @@ The task ID can be found by using the get tasks API. Cancellation should happen quickly but might take a few seconds. The get task status API will continue to list the delete by query task until this task checks that it has been cancelled and terminates itself. -{ref}/docs-delete-by-query.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-delete-by-query[Endpoint documentation] [source,ts] ---- client.deleteByQuery({ index }) @@ -525,7 +525,7 @@ Throttle a delete by query operation. Change the number of requests per second for a particular delete by query operation. Rethrottling that speeds up the query takes effect immediately but rethrotting that slows down the query takes effect after completing the current batch to prevent scroll timeouts. -{ref}/docs-delete-by-query.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-delete-by-query-rethrottle[Endpoint documentation] [source,ts] ---- client.deleteByQueryRethrottle({ task_id }) @@ -542,7 +542,7 @@ client.deleteByQueryRethrottle({ task_id }) Delete a script or search template. Deletes a stored script or search template. -{ref}/modules-scripting.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-delete-script[Endpoint documentation] [source,ts] ---- client.deleteScript({ id }) @@ -551,9 +551,9 @@ client.deleteScript({ id }) ==== Arguments * *Request (object):* -** *`id` (string)*: Identifier for the stored script or search template. -** *`master_timeout` (Optional, string | -1 | 0)*: Period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error. -** *`timeout` (Optional, string | -1 | 0)*: Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. +** *`id` (string)*: The identifier for the stored script or search template. +** *`master_timeout` (Optional, string | -1 | 0)*: The period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. +** *`timeout` (Optional, string | -1 | 0)*: The period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. [discrete] === exists @@ -577,7 +577,7 @@ Internally, Elasticsearch has marked the old document as deleted and added an en The old version of the document doesn't disappear immediately, although you won't be able to access it. Elasticsearch cleans up deleted documents in the background as you continue to index more data. -{ref}/docs-get.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-get[Endpoint documentation] [source,ts] ---- client.exists({ id, index }) @@ -612,7 +612,7 @@ HEAD my-index-000001/_source/1 A document's source is not available if it is disabled in the mapping. -{ref}/docs-get.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-get[Endpoint documentation] [source,ts] ---- client.existsSource({ id, index }) @@ -636,9 +636,10 @@ client.existsSource({ id, index }) [discrete] === explain Explain a document match result. -Returns information about why a specific document matches, or doesn’t match, a query. +Get information about why a specific document matches, or doesn't match, a query. +It computes a score explanation for a query and a specific document. -{ref}/search-explain.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-explain[Endpoint documentation] [source,ts] ---- client.explain({ id, index }) @@ -647,21 +648,21 @@ client.explain({ id, index }) ==== Arguments * *Request (object):* -** *`id` (string)*: Defines the document ID. -** *`index` (string)*: Index names used to limit the request. Only a single index name can be provided to this parameter. +** *`id` (string)*: The document identifier. +** *`index` (string)*: Index names that are used to limit the request. Only a single index name can be provided to this parameter. ** *`query` (Optional, { bool, boosting, common, combined_fields, constant_score, dis_max, distance_feature, exists, function_score, fuzzy, geo_bounding_box, geo_distance, geo_polygon, geo_shape, has_child, has_parent, ids, intervals, knn, match, match_all, match_bool_prefix, match_none, match_phrase, match_phrase_prefix, more_like_this, multi_match, nested, parent_id, percolate, pinned, prefix, query_string, range, rank_feature, regexp, rule, script, script_score, semantic, shape, simple_query_string, span_containing, span_field_masking, span_first, span_multi, span_near, span_not, span_or, span_term, span_within, sparse_vector, term, terms, terms_set, text_expansion, weighted_tokens, wildcard, wrapper, type })*: Defines the search definition using the Query DSL. -** *`analyzer` (Optional, string)*: Analyzer to use for the query string. This parameter can only be used when the `q` query string parameter is specified. -** *`analyze_wildcard` (Optional, boolean)*: If `true`, wildcard and prefix queries are analyzed. -** *`default_operator` (Optional, Enum("and" | "or"))*: The default operator for query string query: `AND` or `OR`. -** *`df` (Optional, string)*: Field to use as default where no field prefix is given in the query string. -** *`lenient` (Optional, boolean)*: If `true`, format-based query failures (such as providing text to a numeric field) in the query string will be ignored. -** *`preference` (Optional, string)*: Specifies the node or shard the operation should be performed on. Random by default. -** *`routing` (Optional, string)*: Custom value used to route operations to a specific shard. -** *`_source` (Optional, boolean | string | string[])*: True or false to return the `_source` field or not, or a list of fields to return. -** *`_source_excludes` (Optional, string | string[])*: A list of source fields to exclude from the response. -** *`_source_includes` (Optional, string | string[])*: A list of source fields to include in the response. +** *`analyzer` (Optional, string)*: The analyzer to use for the query string. This parameter can be used only when the `q` query string parameter is specified. +** *`analyze_wildcard` (Optional, boolean)*: If `true`, wildcard and prefix queries are analyzed. This parameter can be used only when the `q` query string parameter is specified. +** *`default_operator` (Optional, Enum("and" | "or"))*: The default operator for query string query: `AND` or `OR`. This parameter can be used only when the `q` query string parameter is specified. +** *`df` (Optional, string)*: The field to use as default where no field prefix is given in the query string. This parameter can be used only when the `q` query string parameter is specified. +** *`lenient` (Optional, boolean)*: If `true`, format-based query failures (such as providing text to a numeric field) in the query string will be ignored. This parameter can be used only when the `q` query string parameter is specified. +** *`preference` (Optional, string)*: The node or shard the operation should be performed on. It is random by default. +** *`routing` (Optional, string)*: A custom value used to route operations to a specific shard. +** *`_source` (Optional, boolean | string | string[])*: `True` or `false` to return the `_source` field or not or a list of fields to return. +** *`_source_excludes` (Optional, string | string[])*: A list of source fields to exclude from the response. You can also use this parameter to exclude fields from the subset specified in `_source_includes` query parameter. If the `_source` parameter is `false`, this parameter is ignored. +** *`_source_includes` (Optional, string | string[])*: A list of source fields to include in the response. If this parameter is specified, only these source fields are returned. You can exclude fields from this subset using the `_source_excludes` query parameter. If the `_source` parameter is `false`, this parameter is ignored. ** *`stored_fields` (Optional, string | string[])*: A list of stored fields to return in the response. -** *`q` (Optional, string)*: Query in the Lucene query string syntax. +** *`q` (Optional, string)*: The query in the Lucene query string syntax. [discrete] === field_caps @@ -673,7 +674,7 @@ For data streams, the API returns field capabilities among the stream’s backin It returns runtime fields like any other field. For example, a runtime field with a type of keyword is returned the same as any other field that belongs to the `keyword` family. -{ref}/search-field-caps.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-field-caps[Endpoint documentation] [source,ts] ---- client.fieldCaps({ ... }) @@ -682,16 +683,16 @@ client.fieldCaps({ ... }) ==== Arguments * *Request (object):* -** *`index` (Optional, string | string[])*: List of data streams, indices, and aliases used to limit the request. Supports wildcards (*). To target all data streams and indices, omit this parameter or use * or _all. -** *`fields` (Optional, string | string[])*: List of fields to retrieve capabilities for. Wildcard (`*`) expressions are supported. -** *`index_filter` (Optional, { bool, boosting, common, combined_fields, constant_score, dis_max, distance_feature, exists, function_score, fuzzy, geo_bounding_box, geo_distance, geo_polygon, geo_shape, has_child, has_parent, ids, intervals, knn, match, match_all, match_bool_prefix, match_none, match_phrase, match_phrase_prefix, more_like_this, multi_match, nested, parent_id, percolate, pinned, prefix, query_string, range, rank_feature, regexp, rule, script, script_score, semantic, shape, simple_query_string, span_containing, span_field_masking, span_first, span_multi, span_near, span_not, span_or, span_term, span_within, sparse_vector, term, terms, terms_set, text_expansion, weighted_tokens, wildcard, wrapper, type })*: Allows to filter indices if the provided query rewrites to match_none on every shard. -** *`runtime_mappings` (Optional, Record)*: Defines ad-hoc runtime fields in the request similar to the way it is done in search requests. These fields exist only as part of the query and take precedence over fields defined with the same name in the index mappings. +** *`index` (Optional, string | string[])*: A list of data streams, indices, and aliases used to limit the request. Supports wildcards (*). To target all data streams and indices, omit this parameter or use * or _all. +** *`fields` (Optional, string | string[])*: A list of fields to retrieve capabilities for. Wildcard (`*`) expressions are supported. +** *`index_filter` (Optional, { bool, boosting, common, combined_fields, constant_score, dis_max, distance_feature, exists, function_score, fuzzy, geo_bounding_box, geo_distance, geo_polygon, geo_shape, has_child, has_parent, ids, intervals, knn, match, match_all, match_bool_prefix, match_none, match_phrase, match_phrase_prefix, more_like_this, multi_match, nested, parent_id, percolate, pinned, prefix, query_string, range, rank_feature, regexp, rule, script, script_score, semantic, shape, simple_query_string, span_containing, span_field_masking, span_first, span_multi, span_near, span_not, span_or, span_term, span_within, sparse_vector, term, terms, terms_set, text_expansion, weighted_tokens, wildcard, wrapper, type })*: Filter indices if the provided query rewrites to `match_none` on every shard. IMPORTANT: The filtering is done on a best-effort basis, it uses index statistics and mappings to rewrite queries to `match_none` instead of fully running the request. For instance a range query over a date field can rewrite to `match_none` if all documents within a shard (including deleted documents) are outside of the provided range. However, not all queries can rewrite to `match_none` so this API may return an index even if the provided filter matches no document. +** *`runtime_mappings` (Optional, Record)*: Define ad-hoc runtime fields in the request similar to the way it is done in search requests. These fields exist only as part of the query and take precedence over fields defined with the same name in the index mappings. ** *`allow_no_indices` (Optional, boolean)*: If false, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targeting `foo*,bar*` returns an error if an index starts with foo but no index starts with bar. -** *`expand_wildcards` (Optional, Enum("all" | "open" | "closed" | "hidden" | "none") | Enum("all" | "open" | "closed" | "hidden" | "none")[])*: Type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports a list of values, such as `open,hidden`. +** *`expand_wildcards` (Optional, Enum("all" | "open" | "closed" | "hidden" | "none") | Enum("all" | "open" | "closed" | "hidden" | "none")[])*: The type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports a list of values, such as `open,hidden`. ** *`ignore_unavailable` (Optional, boolean)*: If `true`, missing or closed indices are not included in the response. ** *`include_unmapped` (Optional, boolean)*: If true, unmapped fields are included in the response. -** *`filters` (Optional, string)*: An optional set of filters: can include +metadata,-metadata,-nested,-multifield,-parent -** *`types` (Optional, string[])*: Only return results for fields that have one of the types in the list +** *`filters` (Optional, string)*: A list of filters to apply to the response. +** *`types` (Optional, string[])*: A list of field types to include. Any fields that do not match one of these types will be excluded from the results. It defaults to empty, meaning that all field types are returned. ** *`include_empty_fields` (Optional, boolean)*: If false, empty fields are not included in the response. [discrete] @@ -755,7 +756,7 @@ Internally, Elasticsearch has marked the old document as deleted and added an en The old version of the document doesn't disappear immediately, although you won't be able to access it. Elasticsearch cleans up deleted documents in the background as you continue to index more data. -{ref}/docs-get.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-get[Endpoint documentation] [source,ts] ---- client.get({ id, index }) @@ -783,7 +784,7 @@ client.get({ id, index }) Get a script or search template. Retrieves a stored script or search template. -{ref}/modules-scripting.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-get-script[Endpoint documentation] [source,ts] ---- client.getScript({ id }) @@ -792,8 +793,8 @@ client.getScript({ id }) ==== Arguments * *Request (object):* -** *`id` (string)*: Identifier for the stored script or search template. -** *`master_timeout` (Optional, string | -1 | 0)*: Specify timeout for connection to master +** *`id` (string)*: The identifier for the stored script or search template. +** *`master_timeout` (Optional, string | -1 | 0)*: The period to wait for the master node. If the master node is not available before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. [discrete] === get_script_context @@ -801,7 +802,7 @@ Get script contexts. Get a list of supported script contexts and their methods. -{painless}/painless-contexts.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-get-script-context[Endpoint documentation] [source,ts] ---- client.getScriptContext() @@ -813,7 +814,7 @@ Get script languages. Get a list of available script types, languages, and contexts. -{ref}/modules-scripting.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-get-script-languages[Endpoint documentation] [source,ts] ---- client.getScriptLanguages() @@ -836,7 +837,7 @@ You can use the source filtering parameters to control which parts of the `_sour GET my-index-000001/_source/1/?_source_includes=*.id&_source_excludes=entities ---- -{ref}/docs-get.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-get[Endpoint documentation] [source,ts] ---- client.getSource({ id, index }) @@ -879,7 +880,7 @@ A diagnosis contains a cause detailing a root cause analysis, an action containi NOTE: The health indicators perform root cause analysis of non-green health statuses. This can be computationally expensive when called frequently. When setting up automated polling of the API for health status, set verbose to false to disable the more expensive analysis logic. -{ref}/health-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-health-report[Endpoint documentation] [source,ts] ---- client.healthReport({ ... }) @@ -1016,7 +1017,7 @@ If the document was already updated and its version was set to 2 or higher, the A nice side effect is that there is no need to maintain strict ordering of async indexing operations run as a result of changes to a source database, as long as version numbers from the source database are used. Even the simple case of updating the Elasticsearch index using data from a database is simplified if external versioning is used, as only the latest version will be used if the index operations arrive out of order. -{ref}/docs-index_.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-create[Endpoint documentation] [source,ts] ---- client.index({ index }) @@ -1045,7 +1046,7 @@ client.index({ index }) Get cluster info. Get basic build, version, and cluster information. -{ref}/rest-api-root.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-info[Endpoint documentation] [source,ts] ---- client.info() @@ -1067,7 +1068,13 @@ This means the results returned are not always the true k closest neighbors. The kNN search API supports restricting the search using a filter. The search will return the top k documents that also match the filter query. -{ref}/search-search.html[Endpoint documentation] +A kNN search response has the exact same structure as a search API response. +However, certain sections have a meaning specific to kNN search: + +* The document `_score` is determined by the similarity between the query and document vector. +* The `hits.total` object contains the total number of nearest neighbor candidates considered, which is `num_candidates * num_shards`. The `hits.total.relation` will always be `eq`, indicating an exact value. + +{ref}/knn-search-api.html[Endpoint documentation] [source,ts] ---- client.knnSearch({ index, knn }) @@ -1076,14 +1083,14 @@ client.knnSearch({ index, knn }) ==== Arguments * *Request (object):* -** *`index` (string | string[])*: A list of index names to search; use `_all` or to perform the operation on all indices -** *`knn` ({ field, query_vector, k, num_candidates })*: kNN query to execute -** *`_source` (Optional, boolean | { excludes, includes })*: Indicates which source fields are returned for matching documents. These fields are returned in the hits._source property of the search response. -** *`docvalue_fields` (Optional, { field, format, include_unmapped }[])*: The request returns doc values for field names matching these patterns in the hits.fields property of the response. Accepts wildcard (*) patterns. -** *`stored_fields` (Optional, string | string[])*: List of stored fields to return as part of a hit. If no fields are specified, no stored fields are included in the response. If this field is specified, the _source parameter defaults to false. You can pass _source: true to return both source fields and stored fields in the search response. -** *`fields` (Optional, string | string[])*: The request returns values for field names matching these patterns in the hits.fields property of the response. Accepts wildcard (*) patterns. -** *`filter` (Optional, { bool, boosting, common, combined_fields, constant_score, dis_max, distance_feature, exists, function_score, fuzzy, geo_bounding_box, geo_distance, geo_polygon, geo_shape, has_child, has_parent, ids, intervals, knn, match, match_all, match_bool_prefix, match_none, match_phrase, match_phrase_prefix, more_like_this, multi_match, nested, parent_id, percolate, pinned, prefix, query_string, range, rank_feature, regexp, rule, script, script_score, semantic, shape, simple_query_string, span_containing, span_field_masking, span_first, span_multi, span_near, span_not, span_or, span_term, span_within, sparse_vector, term, terms, terms_set, text_expansion, weighted_tokens, wildcard, wrapper, type } | { bool, boosting, common, combined_fields, constant_score, dis_max, distance_feature, exists, function_score, fuzzy, geo_bounding_box, geo_distance, geo_polygon, geo_shape, has_child, has_parent, ids, intervals, knn, match, match_all, match_bool_prefix, match_none, match_phrase, match_phrase_prefix, more_like_this, multi_match, nested, parent_id, percolate, pinned, prefix, query_string, range, rank_feature, regexp, rule, script, script_score, semantic, shape, simple_query_string, span_containing, span_field_masking, span_first, span_multi, span_near, span_not, span_or, span_term, span_within, sparse_vector, term, terms, terms_set, text_expansion, weighted_tokens, wildcard, wrapper, type }[])*: Query to filter the documents that can match. The kNN search will return the top `k` documents that also match this filter. The value can be a single query or a list of queries. If `filter` isn't provided, all documents are allowed to match. -** *`routing` (Optional, string)*: A list of specific routing values +** *`index` (string | string[])*: A list of index names to search; use `_all` or to perform the operation on all indices. +** *`knn` ({ field, query_vector, k, num_candidates })*: The kNN query to run. +** *`_source` (Optional, boolean | { excludes, includes })*: Indicates which source fields are returned for matching documents. These fields are returned in the `hits._source` property of the search response. +** *`docvalue_fields` (Optional, { field, format, include_unmapped }[])*: The request returns doc values for field names matching these patterns in the `hits.fields` property of the response. It accepts wildcard (`*`) patterns. +** *`stored_fields` (Optional, string | string[])*: A list of stored fields to return as part of a hit. If no fields are specified, no stored fields are included in the response. If this field is specified, the `_source` parameter defaults to `false`. You can pass `_source: true` to return both source fields and stored fields in the search response. +** *`fields` (Optional, string | string[])*: The request returns values for field names matching these patterns in the `hits.fields` property of the response. It accepts wildcard (`*`) patterns. +** *`filter` (Optional, { bool, boosting, common, combined_fields, constant_score, dis_max, distance_feature, exists, function_score, fuzzy, geo_bounding_box, geo_distance, geo_polygon, geo_shape, has_child, has_parent, ids, intervals, knn, match, match_all, match_bool_prefix, match_none, match_phrase, match_phrase_prefix, more_like_this, multi_match, nested, parent_id, percolate, pinned, prefix, query_string, range, rank_feature, regexp, rule, script, script_score, semantic, shape, simple_query_string, span_containing, span_field_masking, span_first, span_multi, span_near, span_not, span_or, span_term, span_within, sparse_vector, term, terms, terms_set, text_expansion, weighted_tokens, wildcard, wrapper, type } | { bool, boosting, common, combined_fields, constant_score, dis_max, distance_feature, exists, function_score, fuzzy, geo_bounding_box, geo_distance, geo_polygon, geo_shape, has_child, has_parent, ids, intervals, knn, match, match_all, match_bool_prefix, match_none, match_phrase, match_phrase_prefix, more_like_this, multi_match, nested, parent_id, percolate, pinned, prefix, query_string, range, rank_feature, regexp, rule, script, script_score, semantic, shape, simple_query_string, span_containing, span_field_masking, span_first, span_multi, span_near, span_not, span_or, span_term, span_within, sparse_vector, term, terms, terms_set, text_expansion, weighted_tokens, wildcard, wrapper, type }[])*: A query to filter the documents that can match. The kNN search will return the top `k` documents that also match this filter. The value can be a single query or a list of queries. If `filter` isn't provided, all documents are allowed to match. +** *`routing` (Optional, string)*: A list of specific routing values. [discrete] === mget @@ -1093,7 +1100,19 @@ Get multiple JSON documents by ID from one or more indices. If you specify an index in the request URI, you only need to specify the document IDs in the request body. To ensure fast responses, this multi get (mget) API responds with partial results if one or more shards fail. -{ref}/docs-multi-get.html[Endpoint documentation] +**Filter source fields** + +By default, the `_source` field is returned for every document (if stored). +Use the `_source` and `_source_include` or `source_exclude` attributes to filter what fields are returned for a particular document. +You can include the `_source`, `_source_includes`, and `_source_excludes` query parameters in the request URI to specify the defaults to use when there are no per-document instructions. + +**Get stored fields** + +Use the `stored_fields` attribute to specify the set of stored fields you want to retrieve. +Any requested fields that are not stored are ignored. +You can include the `stored_fields` query parameter in the request URI to specify the defaults to use when there are no per-document instructions. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-mget[Endpoint documentation] [source,ts] ---- client.mget({ ... }) @@ -1135,7 +1154,7 @@ IMPORTANT: The final line of data must end with a newline character `\n`. Each newline character may be preceded by a carriage return `\r`. When sending requests to this endpoint the `Content-Type` header should be set to `application/x-ndjson`. -{ref}/search-multi-search.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-msearch[Endpoint documentation] [source,ts] ---- client.msearch({ ... }) @@ -1164,7 +1183,21 @@ client.msearch({ ... }) === msearch_template Run multiple templated searches. -{ref}/search-multi-search.html[Endpoint documentation] +Run multiple templated searches with a single request. +If you are providing a text file or text input to `curl`, use the `--data-binary` flag instead of `-d` to preserve newlines. +For example: + +---- +$ cat requests +{ "index": "my-index" } +{ "id": "my-search-template", "params": { "query_string": "hello world", "from": 0, "size": 10 }} +{ "index": "my-other-index" } +{ "id": "my-other-search-template", "params": { "query_type": "match_all" }} + +$ curl -H "Content-Type: application/x-ndjson" -XGET localhost:9200/_msearch/template --data-binary "@requests"; echo +---- + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-msearch-template[Endpoint documentation] [source,ts] ---- client.msearchTemplate({ ... }) @@ -1173,11 +1206,11 @@ client.msearchTemplate({ ... }) ==== Arguments * *Request (object):* -** *`index` (Optional, string | string[])*: List of data streams, indices, and aliases to search. Supports wildcards (`*`). To search all data streams and indices, omit this parameter or use `*`. +** *`index` (Optional, string | string[])*: A list of data streams, indices, and aliases to search. It supports wildcards (`*`). To search all data streams and indices, omit this parameter or use `*`. ** *`search_templates` (Optional, { allow_no_indices, expand_wildcards, ignore_unavailable, index, preference, request_cache, routing, search_type, ccs_minimize_roundtrips, allow_partial_search_results, ignore_throttled } | { aggregations, collapse, query, explain, ext, stored_fields, docvalue_fields, knn, from, highlight, indices_boost, min_score, post_filter, profile, rescore, script_fields, search_after, size, sort, _source, fields, terminate_after, stats, timeout, track_scores, track_total_hits, version, runtime_mappings, seq_no_primary_term, pit, suggest }[])* ** *`ccs_minimize_roundtrips` (Optional, boolean)*: If `true`, network round-trips are minimized for cross-cluster search requests. -** *`max_concurrent_searches` (Optional, number)*: Maximum number of concurrent searches the API can run. -** *`search_type` (Optional, Enum("query_then_fetch" | "dfs_query_then_fetch"))*: The type of the search operation. Available options: `query_then_fetch`, `dfs_query_then_fetch`. +** *`max_concurrent_searches` (Optional, number)*: The maximum number of concurrent searches the API can run. +** *`search_type` (Optional, Enum("query_then_fetch" | "dfs_query_then_fetch"))*: The type of the search operation. ** *`rest_total_hits_as_int` (Optional, boolean)*: If `true`, the response returns `hits.total` as an integer. If `false`, it returns `hits.total` as an object. ** *`typed_keys` (Optional, boolean)*: If `true`, the response prefixes aggregation and suggester names with their respective types. @@ -1185,12 +1218,18 @@ client.msearchTemplate({ ... }) === mtermvectors Get multiple term vectors. +Get multiple term vectors with a single request. You can specify existing documents by index and ID or provide artificial documents in the body of the request. You can specify the index in the request body or request URI. The response contains a `docs` array with all the fetched termvectors. Each element has the structure provided by the termvectors API. -{ref}/docs-multi-termvectors.html[Endpoint documentation] +**Artificial documents** + +You can also use `mtermvectors` to generate term vectors for artificial documents provided in the body of the request. +The mapping used is determined by the specified `_index`. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-mtermvectors[Endpoint documentation] [source,ts] ---- client.mtermvectors({ ... }) @@ -1199,20 +1238,20 @@ client.mtermvectors({ ... }) ==== Arguments * *Request (object):* -** *`index` (Optional, string)*: Name of the index that contains the documents. -** *`docs` (Optional, { _id, _index, routing, _source, stored_fields, version, version_type }[])*: Array of existing or artificial documents. -** *`ids` (Optional, string[])*: Simplified syntax to specify documents by their ID if they're in the same index. -** *`fields` (Optional, string | string[])*: List or wildcard expressions of fields to include in the statistics. Used as the default list unless a specific field list is provided in the `completion_fields` or `fielddata_fields` parameters. +** *`index` (Optional, string)*: The name of the index that contains the documents. +** *`docs` (Optional, { _id, _index, routing, _source, stored_fields, version, version_type }[])*: An array of existing or artificial documents. +** *`ids` (Optional, string[])*: A simplified syntax to specify documents by their ID if they're in the same index. +** *`fields` (Optional, string | string[])*: A list or wildcard expressions of fields to include in the statistics. It is used as the default list unless a specific field list is provided in the `completion_fields` or `fielddata_fields` parameters. ** *`field_statistics` (Optional, boolean)*: If `true`, the response includes the document count, sum of document frequencies, and sum of total term frequencies. ** *`offsets` (Optional, boolean)*: If `true`, the response includes term offsets. ** *`payloads` (Optional, boolean)*: If `true`, the response includes term payloads. ** *`positions` (Optional, boolean)*: If `true`, the response includes term positions. -** *`preference` (Optional, string)*: Specifies the node or shard the operation should be performed on. Random by default. +** *`preference` (Optional, string)*: The node or shard the operation should be performed on. It is random by default. ** *`realtime` (Optional, boolean)*: If true, the request is real-time as opposed to near-real-time. -** *`routing` (Optional, string)*: Custom value used to route operations to a specific shard. +** *`routing` (Optional, string)*: A custom value used to route operations to a specific shard. ** *`term_statistics` (Optional, boolean)*: If true, the response includes term frequency and document frequency. ** *`version` (Optional, number)*: If `true`, returns the document version as part of a hit. -** *`version_type` (Optional, Enum("internal" | "external" | "external_gte" | "force"))*: Specific version type. +** *`version_type` (Optional, Enum("internal" | "external" | "external_gte" | "force"))*: The version type. [discrete] === open_point_in_time @@ -1254,7 +1293,7 @@ Ensure that your nodes have sufficient heap space if you have many open point-in Note that a point-in-time doesn't prevent its associated indices from being deleted. You can check how many point-in-times (that is, search contexts) are open with the nodes stats API. -{ref}/point-in-time-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-open-point-in-time[Endpoint documentation] [source,ts] ---- client.openPointInTime({ index, keep_alive }) @@ -1277,7 +1316,7 @@ client.openPointInTime({ index, keep_alive }) Ping the cluster. Get information about whether the cluster is running. -{ref}/index.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-cluster[Endpoint documentation] [source,ts] ---- client.ping() @@ -1288,7 +1327,7 @@ client.ping() Create or update a script or search template. Creates or updates a stored script or search template. -{ref}/modules-scripting.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-put-script[Endpoint documentation] [source,ts] ---- client.putScript({ id, script }) @@ -1297,11 +1336,11 @@ client.putScript({ id, script }) ==== Arguments * *Request (object):* -** *`id` (string)*: Identifier for the stored script or search template. Must be unique within the cluster. -** *`script` ({ lang, options, source })*: Contains the script or search template, its parameters, and its language. -** *`context` (Optional, string)*: Context in which the script or search template should run. To prevent errors, the API immediately compiles the script or template in this context. -** *`master_timeout` (Optional, string | -1 | 0)*: Period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error. -** *`timeout` (Optional, string | -1 | 0)*: Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. +** *`id` (string)*: The identifier for the stored script or search template. It must be unique within the cluster. +** *`script` ({ lang, options, source })*: The script or search template, its parameters, and its language. +** *`context` (Optional, string)*: The context in which the script or search template should run. To prevent errors, the API immediately compiles the script or template in this context. +** *`master_timeout` (Optional, string | -1 | 0)*: The period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. +** *`timeout` (Optional, string | -1 | 0)*: The period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. [discrete] === rank_eval @@ -1309,7 +1348,7 @@ Evaluate ranked search results. Evaluate the quality of ranked search results over a set of typical search queries. -{ref}/search-rank-eval.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rank-eval[Endpoint documentation] [source,ts] ---- client.rankEval({ requests }) @@ -1319,7 +1358,7 @@ client.rankEval({ requests }) * *Request (object):* ** *`requests` ({ id, request, ratings, template_id, params }[])*: A set of typical search requests, together with their provided ratings. -** *`index` (Optional, string | string[])*: List of data streams, indices, and index aliases used to limit the request. Wildcard (`*`) expressions are supported. To target all data streams and indices in a cluster, omit this parameter or use `_all` or `*`. +** *`index` (Optional, string | string[])*: A list of data streams, indices, and index aliases used to limit the request. Wildcard (`*`) expressions are supported. To target all data streams and indices in a cluster, omit this parameter or use `_all` or `*`. ** *`metric` (Optional, { precision, recall, mean_reciprocal_rank, dcg, expected_reciprocal_rank })*: Definition of the evaluation metric to calculate. ** *`allow_no_indices` (Optional, boolean)*: If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targeting `foo*,bar*` returns an error if an index starts with `foo` but no index starts with `bar`. ** *`expand_wildcards` (Optional, Enum("all" | "open" | "closed" | "hidden" | "none") | Enum("all" | "open" | "closed" | "hidden" | "none")[])*: Whether to expand wildcard expression to concrete indices that are open, closed or both. @@ -1511,7 +1550,7 @@ Reindex from remote supports configurable SSL settings. These must be specified in the `elasticsearch.yml` file, with the exception of the secure settings, which you add in the Elasticsearch keystore. It is not possible to configure SSL in the body of the reindex request. -{ref}/docs-reindex.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-reindex[Endpoint documentation] [source,ts] ---- client.reindex({ dest, source }) @@ -1550,7 +1589,7 @@ Rethrottling that speeds up the query takes effect immediately. Rethrottling that slows down the query will take effect after completing the current batch. This behavior prevents scroll timeouts. -{ref}/docs-reindex.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-reindex[Endpoint documentation] [source,ts] ---- client.reindexRethrottle({ task_id }) @@ -1568,7 +1607,7 @@ Render a search template. Render a search template as a search request body. -{ref}/render-search-template-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-render-search-template[Endpoint documentation] [source,ts] ---- client.renderSearchTemplate({ ... }) @@ -1577,10 +1616,10 @@ client.renderSearchTemplate({ ... }) ==== Arguments * *Request (object):* -** *`id` (Optional, string)*: ID of the search template to render. If no `source` is specified, this or the `id` request body parameter is required. +** *`id` (Optional, string)*: The ID of the search template to render. If no `source` is specified, this or the `id` request body parameter is required. ** *`file` (Optional, string)* ** *`params` (Optional, Record)*: Key-value pairs used to replace Mustache variables in the template. The key is the variable name. The value is the variable value. -** *`source` (Optional, string)*: An inline search template. Supports the same parameters as the search API's request body. These parameters also support Mustache variables. If no `id` or `` is specified, this parameter is required. +** *`source` (Optional, string)*: An inline search template. It supports the same parameters as the search API's request body. These parameters also support Mustache variables. If no `id` or `` is specified, this parameter is required. [discrete] === scripts_painless_execute @@ -1624,7 +1663,7 @@ You can also use the scroll API to specify a new scroll parameter that extends o IMPORTANT: Results from a scrolling search reflect the state of the index at the time of the initial search request. Subsequent indexing or document changes only affect later search and scroll requests. -{ref}/search-request-body.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-scroll[Endpoint documentation] [source,ts] ---- client.scroll({ scroll_id }) @@ -1633,8 +1672,8 @@ client.scroll({ scroll_id }) ==== Arguments * *Request (object):* -** *`scroll_id` (string)*: Scroll ID of the search. -** *`scroll` (Optional, string | -1 | 0)*: Period to retain the search context for scrolling. +** *`scroll_id` (string)*: The scroll ID of the search. +** *`scroll` (Optional, string | -1 | 0)*: The period to retain the search context for scrolling. ** *`rest_total_hits_as_int` (Optional, boolean)*: If true, the API response’s hit.total property is returned as an integer. If false, the API response’s hit.total property is returned as an object. [discrete] @@ -1660,7 +1699,7 @@ IMPORTANT: The same point-in-time ID should be used for all slices. If different PIT IDs are used, slices can overlap and miss documents. This situation can occur because the splitting criterion is based on Lucene document IDs, which are not stable across changes to the index. -{ref}/search-search.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search[Endpoint documentation] [source,ts] ---- client.search({ ... }) @@ -1740,8 +1779,140 @@ client.search({ ... }) Search a vector tile. Search a vector tile for geospatial values. +Before using this API, you should be familiar with the Mapbox vector tile specification. +The API returns results as a binary mapbox vector tile. + +Internally, Elasticsearch translates a vector tile search API request into a search containing: + +* A `geo_bounding_box` query on the ``. The query uses the `//` tile as a bounding box. +* A `geotile_grid` or `geohex_grid` aggregation on the ``. The `grid_agg` parameter determines the aggregation type. The aggregation uses the `//` tile as a bounding box. +* Optionally, a `geo_bounds` aggregation on the ``. The search only includes this aggregation if the `exact_bounds` parameter is `true`. +* If the optional parameter `with_labels` is `true`, the internal search will include a dynamic runtime field that calls the `getLabelPosition` function of the geometry doc value. This enables the generation of new point features containing suggested geometry labels, so that, for example, multi-polygons will have only one label. + +For example, Elasticsearch may translate a vector tile search API request with a `grid_agg` argument of `geotile` and an `exact_bounds` argument of `true` into the following search + +---- +GET my-index/_search +{ + "size": 10000, + "query": { + "geo_bounding_box": { + "my-geo-field": { + "top_left": { + "lat": -40.979898069620134, + "lon": -45 + }, + "bottom_right": { + "lat": -66.51326044311186, + "lon": 0 + } + } + } + }, + "aggregations": { + "grid": { + "geotile_grid": { + "field": "my-geo-field", + "precision": 11, + "size": 65536, + "bounds": { + "top_left": { + "lat": -40.979898069620134, + "lon": -45 + }, + "bottom_right": { + "lat": -66.51326044311186, + "lon": 0 + } + } + } + }, + "bounds": { + "geo_bounds": { + "field": "my-geo-field", + "wrap_longitude": false + } + } + } +} +---- -{ref}/search-vector-tile-api.html[Endpoint documentation] +The API returns results as a binary Mapbox vector tile. +Mapbox vector tiles are encoded as Google Protobufs (PBF). By default, the tile contains three layers: + +* A `hits` layer containing a feature for each `` value matching the `geo_bounding_box` query. +* An `aggs` layer containing a feature for each cell of the `geotile_grid` or `geohex_grid`. The layer only contains features for cells with matching data. +* A meta layer containing: + * A feature containing a bounding box. By default, this is the bounding box of the tile. + * Value ranges for any sub-aggregations on the `geotile_grid` or `geohex_grid`. + * Metadata for the search. + +The API only returns features that can display at its zoom level. +For example, if a polygon feature has no area at its zoom level, the API omits it. +The API returns errors as UTF-8 encoded JSON. + +IMPORTANT: You can specify several options for this API as either a query parameter or request body parameter. +If you specify both parameters, the query parameter takes precedence. + +**Grid precision for geotile** + +For a `grid_agg` of `geotile`, you can use cells in the `aggs` layer as tiles for lower zoom levels. +`grid_precision` represents the additional zoom levels available through these cells. The final precision is computed by as follows: ` + grid_precision`. +For example, if `` is 7 and `grid_precision` is 8, then the `geotile_grid` aggregation will use a precision of 15. +The maximum final precision is 29. +The `grid_precision` also determines the number of cells for the grid as follows: `(2^grid_precision) x (2^grid_precision)`. +For example, a value of 8 divides the tile into a grid of 256 x 256 cells. +The `aggs` layer only contains features for cells with matching data. + +**Grid precision for geohex** + +For a `grid_agg` of `geohex`, Elasticsearch uses `` and `grid_precision` to calculate a final precision as follows: ` + grid_precision`. + +This precision determines the H3 resolution of the hexagonal cells produced by the `geohex` aggregation. +The following table maps the H3 resolution for each precision. +For example, if `` is 3 and `grid_precision` is 3, the precision is 6. +At a precision of 6, hexagonal cells have an H3 resolution of 2. +If `` is 3 and `grid_precision` is 4, the precision is 7. +At a precision of 7, hexagonal cells have an H3 resolution of 3. + +| Precision | Unique tile bins | H3 resolution | Unique hex bins | Ratio | +| --------- | ---------------- | ------------- | ----------------| ----- | +| 1 | 4 | 0 | 122 | 30.5 | +| 2 | 16 | 0 | 122 | 7.625 | +| 3 | 64 | 1 | 842 | 13.15625 | +| 4 | 256 | 1 | 842 | 3.2890625 | +| 5 | 1024 | 2 | 5882 | 5.744140625 | +| 6 | 4096 | 2 | 5882 | 1.436035156 | +| 7 | 16384 | 3 | 41162 | 2.512329102 | +| 8 | 65536 | 3 | 41162 | 0.6280822754 | +| 9 | 262144 | 4 | 288122 | 1.099098206 | +| 10 | 1048576 | 4 | 288122 | 0.2747745514 | +| 11 | 4194304 | 5 | 2016842 | 0.4808526039 | +| 12 | 16777216 | 6 | 14117882 | 0.8414913416 | +| 13 | 67108864 | 6 | 14117882 | 0.2103728354 | +| 14 | 268435456 | 7 | 98825162 | 0.3681524172 | +| 15 | 1073741824 | 8 | 691776122 | 0.644266719 | +| 16 | 4294967296 | 8 | 691776122 | 0.1610666797 | +| 17 | 17179869184 | 9 | 4842432842 | 0.2818666889 | +| 18 | 68719476736 | 10 | 33897029882 | 0.4932667053 | +| 19 | 274877906944 | 11 | 237279209162 | 0.8632167343 | +| 20 | 1099511627776 | 11 | 237279209162 | 0.2158041836 | +| 21 | 4398046511104 | 12 | 1660954464122 | 0.3776573213 | +| 22 | 17592186044416 | 13 | 11626681248842 | 0.6609003122 | +| 23 | 70368744177664 | 13 | 11626681248842 | 0.165225078 | +| 24 | 281474976710656 | 14 | 81386768741882 | 0.2891438866 | +| 25 | 1125899906842620 | 15 | 569707381193162 | 0.5060018015 | +| 26 | 4503599627370500 | 15 | 569707381193162 | 0.1265004504 | +| 27 | 18014398509482000 | 15 | 569707381193162 | 0.03162511259 | +| 28 | 72057594037927900 | 15 | 569707381193162 | 0.007906278149 | +| 29 | 288230376151712000 | 15 | 569707381193162 | 0.001976569537 | + +Hexagonal cells don't align perfectly on a vector tile. +Some cells may intersect more than one vector tile. +To compute the H3 resolution for each precision, Elasticsearch compares the average density of hexagonal bins at each resolution with the average density of tile bins at each zoom level. +Elasticsearch uses the H3 resolution that is closest to the corresponding geotile density. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-mvt[Endpoint documentation] [source,ts] ---- client.searchMvt({ index, field, zoom, x, y }) @@ -1755,20 +1926,20 @@ client.searchMvt({ index, field, zoom, x, y }) ** *`zoom` (number)*: Zoom level for the vector tile to search ** *`x` (number)*: X coordinate for the vector tile to search ** *`y` (number)*: Y coordinate for the vector tile to search -** *`aggs` (Optional, Record)*: Sub-aggregations for the geotile_grid. Supports the following aggregation types: - avg - cardinality - max - min - sum -** *`buffer` (Optional, number)*: Size, in pixels, of a clipping buffer outside the tile. This allows renderers to avoid outline artifacts from geometries that extend past the extent of the tile. -** *`exact_bounds` (Optional, 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. The aggregation runs on values that intersect the // tile with wrap_longitude set to false. The resulting bounding box may be larger than the vector tile. -** *`extent` (Optional, number)*: Size, in pixels, of a side of the tile. Vector tiles are square with equal sides. -** *`fields` (Optional, string | string[])*: Fields to return in the `hits` layer. Supports wildcards (`*`). This parameter does not support fields with array values. Fields with array values may return inconsistent results. -** *`grid_agg` (Optional, Enum("geotile" | "geohex"))*: Aggregation used to create a grid for the `field`. -** *`grid_precision` (Optional, number)*: Additional zoom levels available through the aggs layer. For example, if is 7 and grid_precision is 8, you can zoom in up to level 15. Accepts 0-8. If 0, results don’t include the aggs layer. -** *`grid_type` (Optional, Enum("grid" | "point" | "centroid"))*: Determines the geometry type for features in the aggs layer. In the aggs layer, each feature represents a geotile_grid cell. If 'grid' each feature is a Polygon of the cells bounding box. If 'point' each feature is a Point that is the centroid of the cell. -** *`query` (Optional, { bool, boosting, common, combined_fields, constant_score, dis_max, distance_feature, exists, function_score, fuzzy, geo_bounding_box, geo_distance, geo_polygon, geo_shape, has_child, has_parent, ids, intervals, knn, match, match_all, match_bool_prefix, match_none, match_phrase, match_phrase_prefix, more_like_this, multi_match, nested, parent_id, percolate, pinned, prefix, query_string, range, rank_feature, regexp, rule, script, script_score, semantic, shape, simple_query_string, span_containing, span_field_masking, span_first, span_multi, span_near, span_not, span_or, span_term, span_within, sparse_vector, term, terms, terms_set, text_expansion, weighted_tokens, wildcard, wrapper, type })*: Query DSL used to filter documents for the search. +** *`aggs` (Optional, Record)*: Sub-aggregations for the geotile_grid. It supports the following aggregation types: - `avg` - `boxplot` - `cardinality` - `extended stats` - `max` - `median absolute deviation` - `min` - `percentile` - `percentile-rank` - `stats` - `sum` - `value count` The aggregation names can't start with `_mvt_`. The `_mvt_` prefix is reserved for internal aggregations. +** *`buffer` (Optional, number)*: The size, in pixels, of a clipping buffer outside the tile. This allows renderers to avoid outline artifacts from geometries that extend past the extent of the tile. +** *`exact_bounds` (Optional, 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. The aggregation runs on values that intersect the `//` tile with `wrap_longitude` set to `false`. The resulting bounding box may be larger than the vector tile. +** *`extent` (Optional, number)*: The size, in pixels, of a side of the tile. Vector tiles are square with equal sides. +** *`fields` (Optional, string | string[])*: The fields to return in the `hits` layer. It supports wildcards (`*`). This parameter does not support fields with array values. Fields with array values may return inconsistent results. +** *`grid_agg` (Optional, Enum("geotile" | "geohex"))*: The aggregation used to create a grid for the `field`. +** *`grid_precision` (Optional, number)*: Additional zoom levels available through the aggs layer. For example, if `` is `7` and `grid_precision` is `8`, you can zoom in up to level 15. Accepts 0-8. If 0, results don't include the aggs layer. +** *`grid_type` (Optional, Enum("grid" | "point" | "centroid"))*: Determines the geometry type for features in the aggs layer. In the aggs layer, each feature represents a `geotile_grid` cell. If `grid, each feature is a polygon of the cells bounding box. If `point`, each feature is a Point that is the centroid of the cell. +** *`query` (Optional, { bool, boosting, common, combined_fields, constant_score, dis_max, distance_feature, exists, function_score, fuzzy, geo_bounding_box, geo_distance, geo_polygon, geo_shape, has_child, has_parent, ids, intervals, knn, match, match_all, match_bool_prefix, match_none, match_phrase, match_phrase_prefix, more_like_this, multi_match, nested, parent_id, percolate, pinned, prefix, query_string, range, rank_feature, regexp, rule, script, script_score, semantic, shape, simple_query_string, span_containing, span_field_masking, span_first, span_multi, span_near, span_not, span_or, span_term, span_within, sparse_vector, term, terms, terms_set, text_expansion, weighted_tokens, wildcard, wrapper, type })*: The query DSL used to filter documents for the search. ** *`runtime_mappings` (Optional, Record)*: Defines one or more runtime fields in the search request. These fields take precedence over mapped fields with the same name. -** *`size` (Optional, number)*: Maximum number of features to return in the hits layer. Accepts 0-10000. If 0, results don’t include the hits layer. -** *`sort` (Optional, string | { _score, _doc, _geo_distance, _script } | string | { _score, _doc, _geo_distance, _script }[])*: Sorts features in the hits layer. By default, the API calculates a bounding box for each feature. It sorts features based on this box’s diagonal length, from longest to shortest. -** *`track_total_hits` (Optional, boolean | number)*: Number of hits matching the query to count accurately. If `true`, the exact number of hits is returned at the cost of some performance. If `false`, the response does not include the total number of hits matching the query. -** *`with_labels` (Optional, boolean)*: If `true`, the hits and aggs layers will contain additional point features representing suggested label positions for the original features. +** *`size` (Optional, number)*: The maximum number of features to return in the hits layer. Accepts 0-10000. If 0, results don't include the hits layer. +** *`sort` (Optional, string | { _score, _doc, _geo_distance, _script } | string | { _score, _doc, _geo_distance, _script }[])*: Sort the features in the hits layer. By default, the API calculates a bounding box for each feature. It sorts features based on this box's diagonal length, from longest to shortest. +** *`track_total_hits` (Optional, boolean | number)*: The number of hits matching the query to count accurately. If `true`, the exact number of hits is returned at the cost of some performance. If `false`, the response does not include the total number of hits matching the query. +** *`with_labels` (Optional, boolean)*: If `true`, the hits and aggs layers will contain additional point features representing suggested label positions for the original features. * `Point` and `MultiPoint` features will have one of the points selected. * `Polygon` and `MultiPolygon` features will have a single point generated, either the centroid, if it is within the polygon, or another point within the polygon selected from the sorted triangle-tree. * `LineString` features will likewise provide a roughly central point selected from the triangle-tree. * The aggregation results will provide one central point for each aggregation bucket. All attributes from the original features will also be copied to the new label features. In addition, the new features will be distinguishable using the tag `_mvt_label_position`. [discrete] === search_shards @@ -1776,9 +1947,11 @@ Get the search shards. Get the indices and shards that a search request would be run against. This information can be useful for working out issues or planning optimizations with routing and shard preferences. -When filtered aliases are used, the filter is returned as part of the indices section. +When filtered aliases are used, the filter is returned as part of the `indices` section. + +If the Elasticsearch security features are enabled, you must have the `view_index_metadata` or `manage` index privilege for the target data stream, index, or alias. -{ref}/search-shards.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-shards[Endpoint documentation] [source,ts] ---- client.searchShards({ ... }) @@ -1787,20 +1960,20 @@ client.searchShards({ ... }) ==== Arguments * *Request (object):* -** *`index` (Optional, string | string[])*: Returns the indices and shards that a search request would be executed against. +** *`index` (Optional, string | string[])*: A list of data streams, indices, and aliases to search. It supports wildcards (`*`). To search all data streams and indices, omit this parameter or use `*` or `_all`. ** *`allow_no_indices` (Optional, boolean)*: If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targeting `foo*,bar*` returns an error if an index starts with `foo` but no index starts with `bar`. ** *`expand_wildcards` (Optional, Enum("all" | "open" | "closed" | "hidden" | "none") | Enum("all" | "open" | "closed" | "hidden" | "none")[])*: Type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports a list of values, such as `open,hidden`. Valid values are: `all`, `open`, `closed`, `hidden`, `none`. ** *`ignore_unavailable` (Optional, boolean)*: If `false`, the request returns an error if it targets a missing or closed index. ** *`local` (Optional, boolean)*: If `true`, the request retrieves information from the local node only. -** *`master_timeout` (Optional, string | -1 | 0)*: Period to wait for a connection to the master node. -** *`preference` (Optional, string)*: Specifies the node or shard the operation should be performed on. Random by default. -** *`routing` (Optional, string)*: Custom value used to route operations to a specific shard. +** *`master_timeout` (Optional, string | -1 | 0)*: The period to wait for a connection to the master node. If the master node is not available before the timeout expires, the request fails and returns an error. IT can also be set to `-1` to indicate that the request should never timeout. +** *`preference` (Optional, string)*: The node or shard the operation should be performed on. It is random by default. +** *`routing` (Optional, string)*: A custom value used to route operations to a specific shard. [discrete] === search_template Run a search with a search template. -{ref}/search-template.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-template[Endpoint documentation] [source,ts] ---- client.searchTemplate({ ... }) @@ -1809,22 +1982,22 @@ client.searchTemplate({ ... }) ==== Arguments * *Request (object):* -** *`index` (Optional, string | string[])*: List of data streams, indices, and aliases to search. Supports wildcards (*). -** *`explain` (Optional, boolean)*: If `true`, returns detailed information about score calculation as part of each hit. -** *`id` (Optional, string)*: ID of the search template to use. If no source is specified, this parameter is required. +** *`index` (Optional, string | string[])*: A list of data streams, indices, and aliases to search. It supports wildcards (`*`). +** *`explain` (Optional, boolean)*: If `true`, returns detailed information about score calculation as part of each hit. If you specify both this and the `explain` query parameter, the API uses only the query parameter. +** *`id` (Optional, string)*: The ID of the search template to use. If no `source` is specified, this parameter is required. ** *`params` (Optional, Record)*: Key-value pairs used to replace Mustache variables in the template. The key is the variable name. The value is the variable value. ** *`profile` (Optional, boolean)*: If `true`, the query execution is profiled. -** *`source` (Optional, string)*: An inline search template. Supports the same parameters as the search API's request body. Also supports Mustache variables. If no id is specified, this parameter is required. +** *`source` (Optional, string)*: An inline search template. Supports the same parameters as the search API's request body. It also supports Mustache variables. If no `id` is specified, this parameter is required. ** *`allow_no_indices` (Optional, boolean)*: If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targeting `foo*,bar*` returns an error if an index starts with `foo` but no index starts with `bar`. ** *`ccs_minimize_roundtrips` (Optional, boolean)*: If `true`, network round-trips are minimized for cross-cluster search requests. -** *`expand_wildcards` (Optional, Enum("all" | "open" | "closed" | "hidden" | "none") | Enum("all" | "open" | "closed" | "hidden" | "none")[])*: Type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports a list of values, such as `open,hidden`. Valid values are: `all`, `open`, `closed`, `hidden`, `none`. +** *`expand_wildcards` (Optional, Enum("all" | "open" | "closed" | "hidden" | "none") | Enum("all" | "open" | "closed" | "hidden" | "none")[])*: The type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports a list of values, such as `open,hidden`. Valid values are: `all`, `open`, `closed`, `hidden`, `none`. ** *`ignore_throttled` (Optional, boolean)*: If `true`, specified concrete, expanded, or aliased indices are not included in the response when throttled. ** *`ignore_unavailable` (Optional, boolean)*: If `false`, the request returns an error if it targets a missing or closed index. -** *`preference` (Optional, string)*: Specifies the node or shard the operation should be performed on. Random by default. -** *`routing` (Optional, string)*: Custom value used to route operations to a specific shard. +** *`preference` (Optional, string)*: The node or shard the operation should be performed on. It is random by default. +** *`routing` (Optional, string)*: A custom value used to route operations to a specific shard. ** *`scroll` (Optional, string | -1 | 0)*: Specifies how long a consistent view of the index should be maintained for scrolled search. ** *`search_type` (Optional, Enum("query_then_fetch" | "dfs_query_then_fetch"))*: The type of the search operation. -** *`rest_total_hits_as_int` (Optional, boolean)*: If true, hits.total are rendered as an integer in the response. +** *`rest_total_hits_as_int` (Optional, boolean)*: If `true`, `hits.total` is rendered as an integer in the response. If `false`, it is rendered as an object. ** *`typed_keys` (Optional, boolean)*: If `true`, the response prefixes aggregation and suggester names with their respective types. [discrete] @@ -1832,14 +2005,12 @@ client.searchTemplate({ ... }) Get terms in an index. Discover terms that match a partial string in an index. -This "terms enum" API is designed for low-latency look-ups used in auto-complete scenarios. - -If the `complete` property in the response is false, the returned terms set may be incomplete and should be treated as approximate. -This can occur due to a few reasons, such as a request timeout or a node error. +This API is designed for low-latency look-ups used in auto-complete scenarios. -NOTE: The terms enum API may return terms from deleted documents. Deleted documents are initially only marked as deleted. It is not until their segments are merged that documents are actually deleted. Until that happens, the terms enum API will return terms from these documents. +> info +> The terms enum API may return terms from deleted documents. Deleted documents are initially only marked as deleted. It is not until their segments are merged that documents are actually deleted. Until that happens, the terms enum API will return terms from these documents. -{ref}/search-terms-enum.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-terms-enum[Endpoint documentation] [source,ts] ---- client.termsEnum({ index, field }) @@ -1848,14 +2019,14 @@ client.termsEnum({ index, field }) ==== Arguments * *Request (object):* -** *`index` (string)*: List of data streams, indices, and index aliases to search. Wildcard (*) expressions are supported. +** *`index` (string)*: A list of data streams, indices, and index aliases to search. Wildcard (`*`) expressions are supported. To search all data streams or indices, omit this parameter or use `*` or `_all`. ** *`field` (string)*: The string to match at the start of indexed terms. If not provided, all terms in the field are considered. -** *`size` (Optional, number)*: How many matching terms to return. -** *`timeout` (Optional, string | -1 | 0)*: The maximum length of time to spend collecting results. Defaults to "1s" (one second). If the timeout is exceeded the complete flag set to false in the response and the results may be partial or empty. -** *`case_insensitive` (Optional, boolean)*: When true the provided search string is matched against index terms without case sensitivity. -** *`index_filter` (Optional, { bool, boosting, common, combined_fields, constant_score, dis_max, distance_feature, exists, function_score, fuzzy, geo_bounding_box, geo_distance, geo_polygon, geo_shape, has_child, has_parent, ids, intervals, knn, match, match_all, match_bool_prefix, match_none, match_phrase, match_phrase_prefix, more_like_this, multi_match, nested, parent_id, percolate, pinned, prefix, query_string, range, rank_feature, regexp, rule, script, script_score, semantic, shape, simple_query_string, span_containing, span_field_masking, span_first, span_multi, span_near, span_not, span_or, span_term, span_within, sparse_vector, term, terms, terms_set, text_expansion, weighted_tokens, wildcard, wrapper, type })*: Allows to filter an index shard if the provided query rewrites to match_none. -** *`string` (Optional, string)*: The string after which terms in the index should be returned. Allows for a form of pagination if the last result from one request is passed as the search_after parameter for a subsequent request. -** *`search_after` (Optional, string)* +** *`size` (Optional, number)*: The number of matching terms to return. +** *`timeout` (Optional, string | -1 | 0)*: The maximum length of time to spend collecting results. If the timeout is exceeded the `complete` flag set to `false` in the response and the results may be partial or empty. +** *`case_insensitive` (Optional, boolean)*: When `true`, the provided search string is matched against index terms without case sensitivity. +** *`index_filter` (Optional, { bool, boosting, common, combined_fields, constant_score, dis_max, distance_feature, exists, function_score, fuzzy, geo_bounding_box, geo_distance, geo_polygon, geo_shape, has_child, has_parent, ids, intervals, knn, match, match_all, match_bool_prefix, match_none, match_phrase, match_phrase_prefix, more_like_this, multi_match, nested, parent_id, percolate, pinned, prefix, query_string, range, rank_feature, regexp, rule, script, script_score, semantic, shape, simple_query_string, span_containing, span_field_masking, span_first, span_multi, span_near, span_not, span_or, span_term, span_within, sparse_vector, term, terms, terms_set, text_expansion, weighted_tokens, wildcard, wrapper, type })*: Filter an index shard if the provided query rewrites to `match_none`. +** *`string` (Optional, string)*: The string to match at the start of indexed terms. If it is not provided, all terms in the field are considered. > info > The prefix string cannot be larger than the largest possible keyword value, which is Lucene's term byte-length limit of 32766. +** *`search_after` (Optional, string)*: The string after which terms in the index should be returned. It allows for a form of pagination if the last result from one request is passed as the `search_after` parameter for a subsequent request. [discrete] === termvectors @@ -1863,7 +2034,45 @@ Get term vector information. Get information and statistics about terms in the fields of a particular document. -{ref}/docs-termvectors.html[Endpoint documentation] +You can retrieve term vectors for documents stored in the index or for artificial documents passed in the body of the request. +You can specify the fields you are interested in through the `fields` parameter or by adding the fields to the request body. +For example: + +---- +GET /my-index-000001/_termvectors/1?fields=message +---- + +Fields can be specified using wildcards, similar to the multi match query. + +Term vectors are real-time by default, not near real-time. +This can be changed by setting `realtime` parameter to `false`. + +You can request three types of values: _term information_, _term statistics_, and _field statistics_. +By default, all term information and field statistics are returned for all fields but term statistics are excluded. + +**Term information** + +* term frequency in the field (always returned) +* term positions (`positions: true`) +* start and end offsets (`offsets: true`) +* term payloads (`payloads: true`), as base64 encoded bytes + +If the requested information wasn't stored in the index, it will be computed on the fly if possible. +Additionally, term vectors could be computed for documents not even existing in the index, but instead provided by the user. + +> warn +> Start and end offsets assume UTF-16 encoding is being used. If you want to use these offsets in order to get the original text that produced this token, you should make sure that the string you are taking a sub-string of is also encoded using UTF-16. + +**Behaviour** + +The term and field statistics are not accurate. +Deleted documents are not taken into account. +The information is only retrieved for the shard the requested document resides in. +The term and field statistics are therefore only useful as relative measures whereas the absolute numbers have no meaning in this context. +By default, when requesting term vectors of artificial documents, a shard to get the statistics from is randomly selected. +Use `routing` only to hit a particular shard. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-termvectors[Endpoint documentation] [source,ts] ---- client.termvectors({ index }) @@ -1872,22 +2081,22 @@ client.termvectors({ index }) ==== Arguments * *Request (object):* -** *`index` (string)*: Name of the index that contains the document. -** *`id` (Optional, string)*: Unique identifier of the document. +** *`index` (string)*: The name of the index that contains the document. +** *`id` (Optional, string)*: A unique identifier for the document. ** *`doc` (Optional, object)*: An artificial document (a document not present in the index) for which you want to retrieve term vectors. -** *`filter` (Optional, { max_doc_freq, max_num_terms, max_term_freq, max_word_length, min_doc_freq, min_term_freq, min_word_length })*: Filter terms based on their tf-idf scores. -** *`per_field_analyzer` (Optional, Record)*: Overrides the default per-field analyzer. -** *`fields` (Optional, string | string[])*: List or wildcard expressions of fields to include in the statistics. Used as the default list unless a specific field list is provided in the `completion_fields` or `fielddata_fields` parameters. -** *`field_statistics` (Optional, boolean)*: If `true`, the response includes the document count, sum of document frequencies, and sum of total term frequencies. +** *`filter` (Optional, { max_doc_freq, max_num_terms, max_term_freq, max_word_length, min_doc_freq, min_term_freq, min_word_length })*: Filter terms based on their tf-idf scores. This could be useful in order find out a good characteristic vector of a document. This feature works in a similar manner to the second phase of the More Like This Query. +** *`per_field_analyzer` (Optional, Record)*: Override the default per-field analyzer. This is useful in order to generate term vectors in any fashion, especially when using artificial documents. When providing an analyzer for a field that already stores term vectors, the term vectors will be regenerated. +** *`fields` (Optional, string | string[])*: A list or wildcard expressions of fields to include in the statistics. It is used as the default list unless a specific field list is provided in the `completion_fields` or `fielddata_fields` parameters. +** *`field_statistics` (Optional, boolean)*: If `true`, the response includes: * The document count (how many documents contain this field). * The sum of document frequencies (the sum of document frequencies for all terms in this field). * The sum of total term frequencies (the sum of total term frequencies of each term in this field). ** *`offsets` (Optional, boolean)*: If `true`, the response includes term offsets. ** *`payloads` (Optional, boolean)*: If `true`, the response includes term payloads. ** *`positions` (Optional, boolean)*: If `true`, the response includes term positions. -** *`preference` (Optional, string)*: Specifies the node or shard the operation should be performed on. Random by default. +** *`preference` (Optional, string)*: The node or shard the operation should be performed on. It is random by default. ** *`realtime` (Optional, boolean)*: If true, the request is real-time as opposed to near-real-time. -** *`routing` (Optional, string)*: Custom value used to route operations to a specific shard. -** *`term_statistics` (Optional, boolean)*: If `true`, the response includes term frequency and document frequency. +** *`routing` (Optional, string)*: A custom value that is used to route operations to a specific shard. +** *`term_statistics` (Optional, boolean)*: If `true`, the response includes: * The total term frequency (how often a term occurs in all documents). * The document frequency (the number of documents containing the current term). By default these values are not returned since term statistics can have a serious performance impact. ** *`version` (Optional, number)*: If `true`, returns the document version as part of a hit. -** *`version_type` (Optional, Enum("internal" | "external" | "external_gte" | "force"))*: Specific version type. +** *`version_type` (Optional, Enum("internal" | "external" | "external_gte" | "force"))*: The version type. [discrete] === update @@ -1911,7 +2120,7 @@ The document must still be reindexed, but using this API removes some network ro The `_source` field must be enabled to use this API. In addition to `_source`, you can access the following variables through the `ctx` map: `_index`, `_type`, `_id`, `_version`, `_routing`, and `_now` (the current timestamp). -{ref}/docs-update.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-update[Endpoint documentation] [source,ts] ---- client.update({ id, index }) @@ -2028,7 +2237,7 @@ Setting `ctx.op` to anything else is an error. Setting any other field in `ctx` is an error. This API enables you to only modify the source of matching documents; you cannot move them. -{ref}/docs-update-by-query.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-update-by-query[Endpoint documentation] [source,ts] ---- client.updateByQuery({ index }) @@ -2080,7 +2289,7 @@ Throttle an update by query operation. Change the number of requests per second for a particular update by query operation. Rethrottling that speeds up the query takes effect immediately but rethrotting that slows down the query takes effect after completing the current batch to prevent scroll timeouts. -{ref}/docs-update-by-query.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-update-by-query-rethrottle[Endpoint documentation] [source,ts] ---- client.updateByQueryRethrottle({ task_id }) @@ -2102,7 +2311,7 @@ If the asynchronous search is still running, it is cancelled. Otherwise, the saved search results are deleted. If the Elasticsearch security features are enabled, the deletion of a specific async search is restricted to: the authenticated user that submitted the original search request; users that have the `cancel_task` cluster privilege. -{ref}/async-search.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-async-search-submit[Endpoint documentation] [source,ts] ---- client.asyncSearch.delete({ id }) @@ -2121,7 +2330,7 @@ Get async search results. Retrieve the results of a previously submitted asynchronous search request. If the Elasticsearch security features are enabled, access to the results of a specific async search is restricted to the user or API key that submitted it. -{ref}/async-search.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-async-search-submit[Endpoint documentation] [source,ts] ---- client.asyncSearch.get({ id }) @@ -2149,7 +2358,7 @@ Get the async search status. Get the status of a previously submitted async search request given its identifier, without retrieving search results. If the Elasticsearch security features are enabled, use of this API is restricted to the `monitoring_user` role. -{ref}/async-search.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-async-search-submit[Endpoint documentation] [source,ts] ---- client.asyncSearch.status({ id }) @@ -2174,7 +2383,7 @@ Warning: Asynchronous search does not support scroll or search requests that inc By default, Elasticsearch does not allow you to store an async search response larger than 10Mb and an attempt to do this results in an error. The maximum allowed size for a stored async search response can be set by changing the `search.max_async_search_response_size` cluster level setting. -{ref}/async-search.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-async-search-submit[Endpoint documentation] [source,ts] ---- client.asyncSearch.submit({ ... }) @@ -2281,7 +2490,7 @@ Delete an autoscaling policy. NOTE: This feature is designed for indirect use by Elasticsearch Service, Elastic Cloud Enterprise, and Elastic Cloud on Kubernetes. Direct use is not supported. -{ref}/autoscaling-delete-autoscaling-policy.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-autoscaling-delete-autoscaling-policy[Endpoint documentation] [source,ts] ---- client.autoscaling.deleteAutoscalingPolicy({ name }) @@ -2313,7 +2522,7 @@ The response contains decider-specific information you can use to diagnose how a This information is provided for diagnosis only. Do not use this information to make autoscaling decisions. -{ref}/autoscaling-get-autoscaling-capacity.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-autoscaling-get-autoscaling-capacity[Endpoint documentation] [source,ts] ---- client.autoscaling.getAutoscalingCapacity({ ... }) @@ -2332,7 +2541,7 @@ Get an autoscaling policy. NOTE: This feature is designed for indirect use by Elasticsearch Service, Elastic Cloud Enterprise, and Elastic Cloud on Kubernetes. Direct use is not supported. -{ref}/autoscaling-get-autoscaling-capacity.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-autoscaling-get-autoscaling-capacity[Endpoint documentation] [source,ts] ---- client.autoscaling.getAutoscalingPolicy({ name }) @@ -2352,7 +2561,7 @@ Create or update an autoscaling policy. NOTE: This feature is designed for indirect use by Elasticsearch Service, Elastic Cloud Enterprise, and Elastic Cloud on Kubernetes. Direct use is not supported. -{ref}/autoscaling-put-autoscaling-policy.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-autoscaling-put-autoscaling-policy[Endpoint documentation] [source,ts] ---- client.autoscaling.putAutoscalingPolicy({ name }) @@ -2379,7 +2588,7 @@ This API does not return data stream aliases. IMPORTANT: CAT APIs are only intended for human consumption using the command line or the Kibana console. They are not intended for use by applications. For application consumption, use the aliases API. -{ref}/cat-alias.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-aliases[Endpoint documentation] [source,ts] ---- client.cat.aliases({ ... }) @@ -2405,7 +2614,7 @@ Get a snapshot of the number of shards allocated to each data node and their dis IMPORTANT: CAT APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. -{ref}/cat-allocation.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-allocation[Endpoint documentation] [source,ts] ---- client.cat.allocation({ ... }) @@ -2433,7 +2642,7 @@ Component templates are building blocks for constructing index templates that sp IMPORTANT: CAT APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the get component template API. -{ref}/cat-component-templates.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-component-templates[Endpoint documentation] [source,ts] ---- client.cat.componentTemplates({ ... }) @@ -2462,7 +2671,7 @@ The document count only includes live documents, not deleted documents which hav IMPORTANT: CAT APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the count API. -{ref}/cat-count.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-count[Endpoint documentation] [source,ts] ---- client.cat.count({ ... }) @@ -2485,7 +2694,7 @@ Get the amount of heap memory currently used by the field data cache on every da IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the nodes stats API. -{ref}/cat-fielddata.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-fielddata[Endpoint documentation] [source,ts] ---- client.cat.fielddata({ ... }) @@ -2513,7 +2722,7 @@ The latter format is useful for cluster recoveries that take multiple days. You can use the cat health API to verify cluster health across multiple nodes. You also can use the API to track the recovery of a large cluster over a longer period of time. -{ref}/cat-health.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-health[Endpoint documentation] [source,ts] ---- client.cat.health({ ... }) @@ -2532,7 +2741,7 @@ Get CAT help. Get help for the CAT APIs. -{ref}/cat.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-cat[Endpoint documentation] [source,ts] ---- client.cat.help() @@ -2558,7 +2767,7 @@ To get an accurate count of Elasticsearch documents, use the cat count or count CAT APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use an index endpoint. -{ref}/cat-indices.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-indices[Endpoint documentation] [source,ts] ---- client.cat.indices({ ... }) @@ -2586,7 +2795,7 @@ Get information about the master node, including the ID, bound IP address, and n IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the nodes info API. -{ref}/cat-master.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-master[Endpoint documentation] [source,ts] ---- client.cat.master({ ... }) @@ -2612,7 +2821,7 @@ IMPORTANT: CAT APIs are only intended for human consumption using the Kibana console or command line. They are not intended for use by applications. For application consumption, use the get data frame analytics jobs statistics API. -{ref}/cat-dfanalytics.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-ml-data-frame-analytics[Endpoint documentation] [source,ts] ---- client.cat.mlDataFrameAnalytics({ ... }) @@ -2643,7 +2852,7 @@ IMPORTANT: CAT APIs are only intended for human consumption using the Kibana console or command line. They are not intended for use by applications. For application consumption, use the get datafeed statistics API. -{ref}/cat-datafeeds.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-ml-datafeeds[Endpoint documentation] [source,ts] ---- client.cat.mlDatafeeds({ ... }) @@ -2680,7 +2889,7 @@ IMPORTANT: CAT APIs are only intended for human consumption using the Kibana console or command line. They are not intended for use by applications. For application consumption, use the get anomaly detection job statistics API. -{ref}/cat-anomaly-detectors.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-ml-jobs[Endpoint documentation] [source,ts] ---- client.cat.mlJobs({ ... }) @@ -2715,7 +2924,7 @@ IMPORTANT: CAT APIs are only intended for human consumption using the Kibana console or command line. They are not intended for use by applications. For application consumption, use the get trained models statistics API. -{ref}/cat-trained-model.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-ml-trained-models[Endpoint documentation] [source,ts] ---- client.cat.mlTrainedModels({ ... }) @@ -2743,7 +2952,7 @@ Get node attribute information. Get information about custom node attributes. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the nodes info API. -{ref}/cat-nodeattrs.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-nodeattrs[Endpoint documentation] [source,ts] ---- client.cat.nodeattrs({ ... }) @@ -2766,7 +2975,7 @@ Get node information. Get information about the nodes in a cluster. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the nodes info API. -{ref}/cat-nodes.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-nodes[Endpoint documentation] [source,ts] ---- client.cat.nodes({ ... }) @@ -2789,7 +2998,7 @@ Get pending task information. Get information about cluster-level changes that have not yet taken effect. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the pending cluster tasks API. -{ref}/cat-pending-tasks.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-pending-tasks[Endpoint documentation] [source,ts] ---- client.cat.pendingTasks({ ... }) @@ -2813,7 +3022,7 @@ Get plugin information. Get a list of plugins running on each node of a cluster. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the nodes info API. -{ref}/cat-plugins.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-plugins[Endpoint documentation] [source,ts] ---- client.cat.plugins({ ... }) @@ -2839,7 +3048,7 @@ Shard recovery is the process of initializing a shard copy, such as restoring a For data streams, the API returns information about the stream’s backing indices. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the index recovery API. -{ref}/cat-recovery.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-recovery[Endpoint documentation] [source,ts] ---- client.cat.recovery({ ... }) @@ -2863,7 +3072,7 @@ Get snapshot repository information. Get a list of snapshot repositories for a cluster. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the get snapshot repository API. -{ref}/cat-repositories.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-repositories[Endpoint documentation] [source,ts] ---- client.cat.repositories({ ... }) @@ -2887,7 +3096,7 @@ Get low-level information about the Lucene segments in index shards. For data streams, the API returns information about the backing indices. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the index segments API. -{ref}/cat-segments.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-segments[Endpoint documentation] [source,ts] ---- client.cat.segments({ ... }) @@ -2915,7 +3124,7 @@ Get information about the shards in a cluster. For data streams, the API returns information about the backing indices. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. -{ref}/cat-shards.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-shards[Endpoint documentation] [source,ts] ---- client.cat.shards({ ... }) @@ -2940,7 +3149,7 @@ Get information about the snapshots stored in one or more repositories. A snapshot is a backup of an index or running Elasticsearch cluster. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the get snapshot API. -{ref}/cat-snapshots.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-snapshots[Endpoint documentation] [source,ts] ---- client.cat.snapshots({ ... }) @@ -2965,7 +3174,7 @@ Get task information. Get information about tasks currently running in the cluster. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the task management API. -{ref}/tasks.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-tasks[Endpoint documentation] [source,ts] ---- client.cat.tasks({ ... }) @@ -2992,7 +3201,7 @@ Get information about the index templates in a cluster. You can use index templates to apply index settings and field mappings to new indices at creation. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the get index template API. -{ref}/cat-templates.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-templates[Endpoint documentation] [source,ts] ---- client.cat.templates({ ... }) @@ -3018,7 +3227,7 @@ Get thread pool statistics for each node in a cluster. Returned information includes all built-in thread pools and custom thread pools. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the nodes info API. -{ref}/cat-thread-pool.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-thread-pool[Endpoint documentation] [source,ts] ---- client.cat.threadPool({ ... }) @@ -3047,7 +3256,7 @@ CAT APIs are only intended for human consumption using the Kibana console or command line. They are not intended for use by applications. For application consumption, use the get transform statistics API. -{ref}/cat-transforms.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-transforms[Endpoint documentation] [source,ts] ---- client.cat.transforms({ ... }) @@ -3075,7 +3284,7 @@ If `false`, the request returns a 404 status code when there are no matches or o Delete auto-follow patterns. Delete a collection of cross-cluster replication auto-follow patterns. -{ref}/ccr-delete-auto-follow-pattern.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-delete-auto-follow-pattern[Endpoint documentation] [source,ts] ---- client.ccr.deleteAutoFollowPattern({ name }) @@ -3094,7 +3303,7 @@ Create a follower. Create a cross-cluster replication follower index that follows a specific leader index. When the API returns, the follower index exists and cross-cluster replication starts replicating operations from the leader index to the follower index. -{ref}/ccr-put-follow.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-follow[Endpoint documentation] [source,ts] ---- client.ccr.follow({ index, leader_index, remote_cluster }) @@ -3136,7 +3345,7 @@ Get follower information. Get information about all cross-cluster replication follower indices. For example, the results include follower index names, leader index names, replication options, and whether the follower indices are active or paused. -{ref}/ccr-get-follow-info.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-follow-info[Endpoint documentation] [source,ts] ---- client.ccr.followInfo({ index }) @@ -3152,10 +3361,11 @@ client.ccr.followInfo({ index }) [discrete] ==== follow_stats Get follower stats. + Get cross-cluster replication follower stats. The API returns shard-level stats about the "following tasks" associated with each shard for the specified indices. -{ref}/ccr-get-follow-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-follow-stats[Endpoint documentation] [source,ts] ---- client.ccr.followStats({ index }) @@ -3165,8 +3375,9 @@ client.ccr.followStats({ index }) ==== Arguments * *Request (object):* -** *`index` (string | string[])*: A list of index patterns; use `_all` to perform the operation on all indices -** *`timeout` (Optional, string | -1 | 0)*: Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. +** *`index` (string | string[])*: A comma-delimited list of index patterns. +** *`timeout` (Optional, string | -1 | 0)*: The period to wait for a response. +If no response is received before the timeout expires, the request fails and returns an error. [discrete] ==== forget_follower @@ -3183,7 +3394,7 @@ This API exists to enable manually removing the leases when the unfollow API is NOTE: This API does not stop replication by a following index. If you use this API with a follower index that is still actively following, the following index will add back retention leases on the leader. The only purpose of this API is to handle the case of failure to remove the following retention leases after the unfollow API is invoked. -{ref}/ccr-post-forget-follower.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-forget-follower[Endpoint documentation] [source,ts] ---- client.ccr.forgetFollower({ index }) @@ -3203,9 +3414,10 @@ client.ccr.forgetFollower({ index }) [discrete] ==== get_auto_follow_pattern Get auto-follow patterns. + Get cross-cluster replication auto-follow patterns. -{ref}/ccr-get-auto-follow-pattern.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-get-auto-follow-pattern-1[Endpoint documentation] [source,ts] ---- client.ccr.getAutoFollowPattern({ ... }) @@ -3215,12 +3427,16 @@ client.ccr.getAutoFollowPattern({ ... }) ==== Arguments * *Request (object):* -** *`name` (Optional, string)*: Specifies the auto-follow pattern collection that you want to retrieve. If you do not specify a name, the API returns information for all collections. -** *`master_timeout` (Optional, string | -1 | 0)*: Period to wait for a connection to the master node. +** *`name` (Optional, string)*: The auto-follow pattern collection that you want to retrieve. +If you do not specify a name, the API returns information for all collections. +** *`master_timeout` (Optional, string | -1 | 0)*: The period to wait for a connection to the master node. +If the master node is not available before the timeout expires, the request fails and returns an error. +It can also be set to `-1` to indicate that the request should never timeout. [discrete] ==== pause_auto_follow_pattern Pause an auto-follow pattern. + Pause a cross-cluster replication auto-follow pattern. When the API returns, the auto-follow pattern is inactive. New indices that are created on the remote cluster and match the auto-follow patterns are ignored. @@ -3229,7 +3445,7 @@ You can resume auto-following with the resume auto-follow pattern API. When it resumes, the auto-follow pattern is active again and automatically configures follower indices for newly created indices on the remote cluster that match its patterns. Remote indices that were created while the pattern was paused will also be followed, unless they have been deleted or closed in the interim. -{ref}/ccr-pause-auto-follow-pattern.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-pause-auto-follow-pattern[Endpoint documentation] [source,ts] ---- client.ccr.pauseAutoFollowPattern({ name }) @@ -3239,18 +3455,21 @@ client.ccr.pauseAutoFollowPattern({ name }) ==== Arguments * *Request (object):* -** *`name` (string)*: The name of the auto follow pattern that should pause discovering new indices to follow. -** *`master_timeout` (Optional, string | -1 | 0)*: Period to wait for a connection to the master node. +** *`name` (string)*: The name of the auto-follow pattern to pause. +** *`master_timeout` (Optional, string | -1 | 0)*: The period to wait for a connection to the master node. +If the master node is not available before the timeout expires, the request fails and returns an error. +It can also be set to `-1` to indicate that the request should never timeout. [discrete] ==== pause_follow Pause a follower. + Pause a cross-cluster replication follower index. The follower index will not fetch any additional operations from the leader index. You can resume following with the resume follower API. You can pause and resume a follower index to change the configuration of the following task. -{ref}/ccr-post-pause-follow.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-pause-follow[Endpoint documentation] [source,ts] ---- client.ccr.pauseFollow({ index }) @@ -3260,8 +3479,10 @@ client.ccr.pauseFollow({ index }) ==== Arguments * *Request (object):* -** *`index` (string)*: The name of the follower index that should pause following its leader index. -** *`master_timeout` (Optional, string | -1 | 0)*: Period to wait for a connection to the master node. +** *`index` (string)*: The name of the follower index. +** *`master_timeout` (Optional, string | -1 | 0)*: The period to wait for a connection to the master node. +If the master node is not available before the timeout expires, the request fails and returns an error. +It can also be set to `-1` to indicate that the request should never timeout. [discrete] ==== put_auto_follow_pattern @@ -3273,7 +3494,7 @@ Indices on the remote cluster that were created before the auto-follow pattern w This API can also be used to update auto-follow patterns. NOTE: Follower indices that were configured automatically before updating an auto-follow pattern will remain unchanged even if they do not match against the new patterns. -{ref}/ccr-put-auto-follow-pattern.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-put-auto-follow-pattern[Endpoint documentation] [source,ts] ---- client.ccr.putAutoFollowPattern({ name, remote_cluster }) @@ -3304,11 +3525,12 @@ client.ccr.putAutoFollowPattern({ name, remote_cluster }) [discrete] ==== resume_auto_follow_pattern Resume an auto-follow pattern. + Resume a cross-cluster replication auto-follow pattern that was paused. The auto-follow pattern will resume configuring following indices for newly created indices that match its patterns on the remote cluster. Remote indices created while the pattern was paused will also be followed unless they have been deleted or closed in the interim. -{ref}/ccr-resume-auto-follow-pattern.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-resume-auto-follow-pattern[Endpoint documentation] [source,ts] ---- client.ccr.resumeAutoFollowPattern({ name }) @@ -3318,8 +3540,10 @@ client.ccr.resumeAutoFollowPattern({ name }) ==== Arguments * *Request (object):* -** *`name` (string)*: The name of the auto follow pattern to resume discovering new indices to follow. -** *`master_timeout` (Optional, string | -1 | 0)*: Period to wait for a connection to the master node. +** *`name` (string)*: The name of the auto-follow pattern to resume. +** *`master_timeout` (Optional, string | -1 | 0)*: The period to wait for a connection to the master node. +If the master node is not available before the timeout expires, the request fails and returns an error. +It can also be set to `-1` to indicate that the request should never timeout. [discrete] ==== resume_follow @@ -3329,7 +3553,7 @@ The follower index could have been paused with the pause follower API. Alternatively it could be paused due to replication that cannot be retried due to failures during following tasks. When this API returns, the follower index will resume fetching operations from the leader index. -{ref}/ccr-post-resume-follow.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-resume-follow[Endpoint documentation] [source,ts] ---- client.ccr.resumeFollow({ index }) @@ -3355,9 +3579,10 @@ client.ccr.resumeFollow({ index }) [discrete] ==== stats Get cross-cluster replication stats. + This API returns stats about auto-following and the same shard-level stats as the get follower stats API. -{ref}/ccr-get-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-stats[Endpoint documentation] [source,ts] ---- client.ccr.stats({ ... }) @@ -3367,19 +3592,23 @@ client.ccr.stats({ ... }) ==== Arguments * *Request (object):* -** *`master_timeout` (Optional, string | -1 | 0)*: Period to wait for a connection to the master node. -** *`timeout` (Optional, string | -1 | 0)*: Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. +** *`master_timeout` (Optional, string | -1 | 0)*: The period to wait for a connection to the master node. +If the master node is not available before the timeout expires, the request fails and returns an error. +It can also be set to `-1` to indicate that the request should never timeout. +** *`timeout` (Optional, string | -1 | 0)*: The period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. [discrete] ==== unfollow Unfollow an index. + Convert a cross-cluster replication follower index to a regular index. The API stops the following task associated with a follower index and removes index metadata and settings associated with cross-cluster replication. The follower index must be paused and closed before you call the unfollow API. -NOTE: Currently cross-cluster replication does not support converting an existing regular index to a follower index. Converting a follower index to a regular index is an irreversible operation. +> info +> Currently cross-cluster replication does not support converting an existing regular index to a follower index. Converting a follower index to a regular index is an irreversible operation. -{ref}/ccr-post-unfollow.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-unfollow[Endpoint documentation] [source,ts] ---- client.ccr.unfollow({ index }) @@ -3389,8 +3618,10 @@ client.ccr.unfollow({ index }) ==== Arguments * *Request (object):* -** *`index` (string)*: The name of the follower index that should be turned into a regular index. -** *`master_timeout` (Optional, string | -1 | 0)*: Period to wait for a connection to the master node. +** *`index` (string)*: The name of the follower index. +** *`master_timeout` (Optional, string | -1 | 0)*: The period to wait for a connection to the master node. +If the master node is not available before the timeout expires, the request fails and returns an error. +It can also be set to `-1` to indicate that the request should never timeout. [discrete] === cluster @@ -3402,7 +3633,7 @@ For unassigned shards, it provides an explanation for why the shard is unassigne For assigned shards, it provides an explanation for why the shard is remaining on its current node and has not moved or rebalanced to another node. This API can be very useful when attempting to diagnose why a shard is unassigned or why a shard continues to remain on its current node when you might expect otherwise. -{ref}/cluster-allocation-explain.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-allocation-explain[Endpoint documentation] [source,ts] ---- client.cluster.allocationExplain({ ... }) @@ -3425,7 +3656,7 @@ client.cluster.allocationExplain({ ... }) Delete component templates. Component templates are building blocks for constructing index templates that specify index mappings, settings, and aliases. -{ref}/indices-component-template.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-put-component-template[Endpoint documentation] [source,ts] ---- client.cluster.deleteComponentTemplate({ name }) @@ -3446,7 +3677,7 @@ If no response is received before the timeout expires, the request fails and ret Clear cluster voting config exclusions. Remove master-eligible nodes from the voting configuration exclusion list. -{ref}/voting-config-exclusions.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-post-voting-config-exclusions[Endpoint documentation] [source,ts] ---- client.cluster.deleteVotingConfigExclusions({ ... }) @@ -3469,7 +3700,7 @@ nodes are still in the cluster. Check component templates. Returns information about whether a particular component template exists. -{ref}/indices-component-template.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-put-component-template[Endpoint documentation] [source,ts] ---- client.cluster.existsComponentTemplate({ name }) @@ -3492,7 +3723,7 @@ Defaults to false, which means information is retrieved from the master node. Get component templates. Get information about component templates. -{ref}/indices-component-template.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-put-component-template[Endpoint documentation] [source,ts] ---- client.cluster.getComponentTemplate({ ... }) @@ -3516,7 +3747,7 @@ If no response is received before the timeout expires, the request fails and ret Get cluster-wide settings. By default, it returns only settings that have been explicitly defined. -{ref}/cluster-get-settings.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-get-settings[Endpoint documentation] [source,ts] ---- client.cluster.getSettings({ ... }) @@ -3536,6 +3767,7 @@ If no response is received before the timeout expires, the request fails and ret [discrete] ==== health Get the cluster health status. + You can also use the API to get the health status of only specified data streams and indices. For data streams, the API retrieves the health status of the stream’s backing indices. @@ -3546,7 +3778,7 @@ The index level status is controlled by the worst shard status. One of the main benefits of the API is the ability to wait until the cluster reaches a certain high watermark health level. The cluster status is controlled by the worst index status. -{ref}/cluster-health.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-health[Endpoint documentation] [source,ts] ---- client.cluster.health({ ... }) @@ -3574,7 +3806,7 @@ client.cluster.health({ ... }) Get cluster info. Returns basic information about the cluster. -{ref}/cluster-info.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-info[Endpoint documentation] [source,ts] ---- client.cluster.info({ target }) @@ -3595,7 +3827,7 @@ NOTE: This API returns a list of any pending updates to the cluster state. These are distinct from the tasks reported by the task management API which include periodic tasks and tasks initiated by the user, such as node stats, search queries, or create index requests. However, if a user-initiated task such as a create index command causes a cluster state update, the activity of this task might be reported by both task api and pending cluster tasks API. -{ref}/cluster-pending.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-pending-tasks[Endpoint documentation] [source,ts] ---- client.cluster.pendingTasks({ ... }) @@ -3631,7 +3863,7 @@ In that case, you may safely retry the call. NOTE: Voting exclusions are required only when you remove at least half of the master-eligible nodes from a cluster in a short time period. They are not required when removing master-ineligible nodes or when removing fewer than half of the master-eligible nodes. -{ref}/voting-config-exclusions.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-post-voting-config-exclusions[Endpoint documentation] [source,ts] ---- client.cluster.postVotingConfigExclusions({ ... }) @@ -3674,7 +3906,7 @@ You can include comments anywhere in the request body except before the opening You cannot directly apply a component template to a data stream or index. To be applied, a component template must be included in an index template's `composed_of` list. -{ref}/indices-component-template.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-put-component-template[Endpoint documentation] [source,ts] ---- client.cluster.putComponentTemplate({ name, template }) @@ -3706,6 +3938,7 @@ If no response is received before the timeout expires, the request fails and ret [discrete] ==== put_settings Update the cluster settings. + Configure and update dynamic settings on a running cluster. You can also configure dynamic settings locally on an unstarted or shut down node in `elasticsearch.yml`. @@ -3724,7 +3957,7 @@ The API doesn’t require a restart and ensures a setting’s value is the same WARNING: Transient cluster settings are no longer recommended. Use persistent cluster settings instead. If a cluster becomes unstable, transient settings can clear unexpectedly, resulting in a potentially undesired cluster configuration. -{ref}/cluster-update-settings.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-put-settings[Endpoint documentation] [source,ts] ---- client.cluster.putSettings({ ... }) @@ -3743,10 +3976,17 @@ client.cluster.putSettings({ ... }) [discrete] ==== remote_info Get remote cluster information. -Get all of the configured remote cluster information. -This API returns connection and endpoint information keyed by the configured remote cluster alias. -{ref}/cluster-remote-info.html[Endpoint documentation] +Get information about configured remote clusters. +The API returns connection and endpoint information keyed by the configured remote cluster alias. + +> info +> This API returns information that reflects current state on the local cluster. +> The `connected` field does not necessarily reflect whether a remote cluster is down or unavailable, only whether there is currently an open connection to it. +> Elasticsearch does not spontaneously try to reconnect to a disconnected remote cluster. +> To trigger a reconnection, attempt a cross-cluster search, ES|QL cross-cluster search, or try the [resolve cluster endpoint](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-resolve-cluster). + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-remote-info[Endpoint documentation] [source,ts] ---- client.cluster.remoteInfo() @@ -3770,7 +4010,7 @@ This scenario can be caused by structural problems such as having an analyzer wh Once the problem has been corrected, allocation can be manually retried by calling the reroute API with the `?retry_failed` URI query parameter, which will attempt a single retry round for these shards. -{ref}/cluster-reroute.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-reroute[Endpoint documentation] [source,ts] ---- client.cluster.reroute({ ... }) @@ -3811,7 +4051,7 @@ Its format is not subject to the same compatibility guarantees as other more sta Do not query this API using external monitoring tools. Instead, obtain the information you require using other more stable cluster APIs. -{ref}/cluster-state.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-state[Endpoint documentation] [source,ts] ---- client.cluster.state({ ... }) @@ -3837,7 +4077,7 @@ client.cluster.state({ ... }) Get cluster statistics. Get basic index metrics (shard numbers, store size, memory usage) and information about the current nodes that form the cluster (number, roles, os, jvm versions, memory usage, cpu and installed plugins). -{ref}/cluster-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-stats[Endpoint documentation] [source,ts] ---- client.cluster.stats({ ... }) @@ -3861,7 +4101,7 @@ Check in a connector. Update the `last_seen` field in the connector and set it to the current timestamp. -{ref}/check-in-connector-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-check-in[Endpoint documentation] [source,ts] ---- client.connector.checkIn({ connector_id }) @@ -3882,7 +4122,7 @@ This is a destructive action that is not recoverable. NOTE: This action doesn’t delete any API keys, ingest pipelines, or data indices associated with the connector. These need to be removed manually. -{ref}/delete-connector-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-delete[Endpoint documentation] [source,ts] ---- client.connector.delete({ connector_id }) @@ -3902,7 +4142,7 @@ Get a connector. Get the details about a connector. -{ref}/get-connector-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-get[Endpoint documentation] [source,ts] ---- client.connector.get({ connector_id }) @@ -3921,7 +4161,7 @@ Get all connectors. Get information about all connectors. -{ref}/list-connector-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-list[Endpoint documentation] [source,ts] ---- client.connector.list({ ... }) @@ -3947,7 +4187,7 @@ Connectors are Elasticsearch integrations that bring content from third-party da Elastic managed connectors (Native connectors) are a managed service on Elastic Cloud. Self-managed connectors (Connector clients) are self-managed on your infrastructure. -{ref}/create-connector-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-put[Endpoint documentation] [source,ts] ---- client.connector.post({ ... }) @@ -3968,7 +4208,7 @@ client.connector.post({ ... }) ==== put Create or update a connector. -{ref}/create-connector-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-put[Endpoint documentation] [source,ts] ---- client.connector.put({ ... }) @@ -3993,7 +4233,7 @@ Cancel a connector sync job. Cancel a connector sync job, which sets the status to cancelling and updates `cancellation_requested_at` to the current time. The connector service is then responsible for setting the status of connector sync jobs to cancelled. -{ref}/cancel-connector-sync-job-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-cancel[Endpoint documentation] [source,ts] ---- client.connector.syncJobCancel({ connector_sync_job_id }) @@ -4013,7 +4253,7 @@ Check in a connector sync job and set the `last_seen` field to the current time To sync data using self-managed connectors, you need to deploy the Elastic connector service on your own infrastructure. This service runs automatically on Elastic Cloud for Elastic managed connectors. -{ref}/check-in-connector-sync-job-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-check-in[Endpoint documentation] [source,ts] ---- client.connector.syncJobCheckIn({ connector_sync_job_id }) @@ -4036,6 +4276,8 @@ It supports the implementation of services that utilize the connector protocol t To sync data using self-managed connectors, you need to deploy the Elastic connector service on your own infrastructure. This service runs automatically on Elastic Cloud for Elastic managed connectors. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-claim[Endpoint documentation] [source,ts] ---- client.connector.syncJobClaim({ connector_sync_job_id, worker_hostname }) @@ -4057,7 +4299,7 @@ Delete a connector sync job. Remove a connector sync job and its associated data. This is a destructive action that is not recoverable. -{ref}/delete-connector-sync-job-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-delete[Endpoint documentation] [source,ts] ---- client.connector.syncJobDelete({ connector_sync_job_id }) @@ -4077,7 +4319,7 @@ Set the `error` field for a connector sync job and set its `status` to `error`. To sync data using self-managed connectors, you need to deploy the Elastic connector service on your own infrastructure. This service runs automatically on Elastic Cloud for Elastic managed connectors. -{ref}/set-connector-sync-job-error-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-error[Endpoint documentation] [source,ts] ---- client.connector.syncJobError({ connector_sync_job_id, error }) @@ -4094,7 +4336,7 @@ client.connector.syncJobError({ connector_sync_job_id, error }) ==== sync_job_get Get a connector sync job. -{ref}/get-connector-sync-job-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-get[Endpoint documentation] [source,ts] ---- client.connector.syncJobGet({ connector_sync_job_id }) @@ -4112,7 +4354,7 @@ Get all connector sync jobs. Get information about all stored connector sync jobs listed by their creation date in ascending order. -{ref}/list-connector-sync-jobs-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-list[Endpoint documentation] [source,ts] ---- client.connector.syncJobList({ ... }) @@ -4134,7 +4376,7 @@ Create a connector sync job. Create a connector sync job document in the internal index and initialize its counters and timestamps with default values. -{ref}/create-connector-sync-job-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-post[Endpoint documentation] [source,ts] ---- client.connector.syncJobPost({ id }) @@ -4158,7 +4400,7 @@ This API is mainly used by the connector service for updating sync job informati To sync data using self-managed connectors, you need to deploy the Elastic connector service on your own infrastructure. This service runs automatically on Elastic Cloud for Elastic managed connectors. -{ref}/set-connector-sync-job-stats-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-update-stats[Endpoint documentation] [source,ts] ---- client.connector.syncJobUpdateStats({ connector_sync_job_id, deleted_document_count, indexed_document_count, indexed_document_volume }) @@ -4182,7 +4424,7 @@ Activate the connector draft filter. Activates the valid draft filtering for a connector. -{ref}/update-connector-filtering-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-filtering[Endpoint documentation] [source,ts] ---- client.connector.updateActiveFiltering({ connector_id }) @@ -4203,7 +4445,7 @@ You can specify the ID of the API key used for authorization and the ID of the c The connector secret ID is required only for Elastic managed (native) connectors. Self-managed connectors (connector clients) do not use this field. -{ref}/update-connector-api-key-id-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-api-key-id[Endpoint documentation] [source,ts] ---- client.connector.updateApiKeyId({ connector_id }) @@ -4223,7 +4465,7 @@ Update the connector configuration. Update the configuration field in the connector document. -{ref}/update-connector-configuration-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-configuration[Endpoint documentation] [source,ts] ---- client.connector.updateConfiguration({ connector_id }) @@ -4245,7 +4487,7 @@ Set the error field for the connector. If the error provided in the request body is non-null, the connector’s status is updated to error. Otherwise, if the error is reset to null, the connector status is updated to connected. -{ref}/update-connector-error-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-error[Endpoint documentation] [source,ts] ---- client.connector.updateError({ connector_id, error }) @@ -4275,7 +4517,7 @@ However, you can use this API to override the default behavior. To sync data using self-managed connectors, you need to deploy the Elastic connector service on your own infrastructure. This service runs automatically on Elastic Cloud for Elastic managed connectors. -{ref}/update-connector-features-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-features[Endpoint documentation] [source,ts] ---- client.connector.updateFeatures({ connector_id, features }) @@ -4296,7 +4538,7 @@ Update the draft filtering configuration of a connector and marks the draft vali The filtering draft is activated once validated by the running Elastic connector service. The filtering property is used to configure sync rules (both basic and advanced) for a connector. -{ref}/update-connector-filtering-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-filtering[Endpoint documentation] [source,ts] ---- client.connector.updateFiltering({ connector_id }) @@ -4334,7 +4576,7 @@ Update the connector index name. Update the `index_name` field of a connector, specifying the index where the data ingested by the connector is stored. -{ref}/update-connector-index-name-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-index-name[Endpoint documentation] [source,ts] ---- client.connector.updateIndexName({ connector_id, index_name }) @@ -4351,7 +4593,7 @@ client.connector.updateIndexName({ connector_id, index_name }) ==== update_name Update the connector name and description. -{ref}/update-connector-name-description-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-name[Endpoint documentation] [source,ts] ---- client.connector.updateName({ connector_id }) @@ -4386,7 +4628,7 @@ Update the connector pipeline. When you create a new connector, the configuration of an ingest pipeline is populated with default settings. -{ref}/update-connector-pipeline-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-pipeline[Endpoint documentation] [source,ts] ---- client.connector.updatePipeline({ connector_id, pipeline }) @@ -4403,7 +4645,7 @@ client.connector.updatePipeline({ connector_id, pipeline }) ==== update_scheduling Update the connector scheduling. -{ref}/update-connector-scheduling-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-scheduling[Endpoint documentation] [source,ts] ---- client.connector.updateScheduling({ connector_id, scheduling }) @@ -4420,7 +4662,7 @@ client.connector.updateScheduling({ connector_id, scheduling }) ==== update_service_type Update the connector service type. -{ref}/update-connector-service-type-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-service-type[Endpoint documentation] [source,ts] ---- client.connector.updateServiceType({ connector_id, service_type }) @@ -4437,7 +4679,7 @@ client.connector.updateServiceType({ connector_id, service_type }) ==== update_status Update the connector status. -{ref}/update-connector-status-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-status[Endpoint documentation] [source,ts] ---- client.connector.updateStatus({ connector_id, status }) @@ -4458,7 +4700,7 @@ Delete a dangling index. If Elasticsearch encounters index data that is absent from the current cluster state, those indices are considered to be dangling. For example, this can happen if you delete more than `cluster.indices.tombstones.size` indices while an Elasticsearch node is offline. -{ref}/dangling-index-delete.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-dangling-indices-delete-dangling-index[Endpoint documentation] [source,ts] ---- client.danglingIndices.deleteDanglingIndex({ index_uuid, accept_data_loss }) @@ -4480,7 +4722,7 @@ Import a dangling index. If Elasticsearch encounters index data that is absent from the current cluster state, those indices are considered to be dangling. For example, this can happen if you delete more than `cluster.indices.tombstones.size` indices while an Elasticsearch node is offline. -{ref}/dangling-index-import.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-dangling-indices-import-dangling-index[Endpoint documentation] [source,ts] ---- client.danglingIndices.importDanglingIndex({ index_uuid, accept_data_loss }) @@ -4505,7 +4747,7 @@ For example, this can happen if you delete more than `cluster.indices.tombstones Use this API to list dangling indices, which you can then import or delete. -{ref}/dangling-indices-list.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-dangling-indices-list-dangling-indices[Endpoint documentation] [source,ts] ---- client.danglingIndices.listDanglingIndices() @@ -4519,7 +4761,7 @@ client.danglingIndices.listDanglingIndices() Delete an enrich policy. Deletes an existing enrich policy and its enrich index. -{ref}/delete-enrich-policy-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-enrich-delete-policy[Endpoint documentation] [source,ts] ---- client.enrich.deletePolicy({ name }) @@ -4537,7 +4779,7 @@ client.enrich.deletePolicy({ name }) Run an enrich policy. Create the enrich index for an existing enrich policy. -{ref}/execute-enrich-policy-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-enrich-execute-policy[Endpoint documentation] [source,ts] ---- client.enrich.executePolicy({ name }) @@ -4556,7 +4798,7 @@ client.enrich.executePolicy({ name }) Get an enrich policy. Returns information about an enrich policy. -{ref}/get-enrich-policy-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-enrich-get-policy[Endpoint documentation] [source,ts] ---- client.enrich.getPolicy({ ... }) @@ -4575,7 +4817,7 @@ To return information for all enrich policies, omit this parameter. Create an enrich policy. Creates an enrich policy. -{ref}/put-enrich-policy-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-enrich-put-policy[Endpoint documentation] [source,ts] ---- client.enrich.putPolicy({ name }) @@ -4596,7 +4838,7 @@ client.enrich.putPolicy({ name }) Get enrich stats. Returns enrich coordinator statistics and information about enrich policies that are currently executing. -{ref}/enrich-stats-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-enrich-stats[Endpoint documentation] [source,ts] ---- client.enrich.stats({ ... }) @@ -4616,7 +4858,7 @@ Delete an async EQL search. Delete an async EQL search or a stored synchronous EQL search. The API also deletes results for the search. -{ref}/eql-search-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-eql-delete[Endpoint documentation] [source,ts] ---- client.eql.delete({ id }) @@ -4635,7 +4877,7 @@ A search ID is also provided if the request’s `keep_on_completion` parameter i Get async EQL search results. Get the current status and available results for an async EQL search or a stored synchronous EQL search. -{ref}/get-async-eql-search-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-eql-get[Endpoint documentation] [source,ts] ---- client.eql.get({ id }) @@ -4656,7 +4898,7 @@ Defaults to no timeout, meaning the request waits for complete search results. Get the async EQL status. Get the current status for an async EQL search or a stored synchronous EQL search without returning results. -{ref}/get-async-eql-status-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-eql-get-status[Endpoint documentation] [source,ts] ---- client.eql.getStatus({ id }) @@ -4674,7 +4916,7 @@ Get EQL search results. Returns search results for an Event Query Language (EQL) query. EQL assumes each document in a data stream or index corresponds to an event. -{ref}/eql-search-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-eql-search[Endpoint documentation] [source,ts] ---- client.eql.search({ index, query }) @@ -4695,8 +4937,12 @@ client.eql.search({ index, query }) ** *`keep_alive` (Optional, string | -1 | 0)* ** *`keep_on_completion` (Optional, boolean)* ** *`wait_for_completion_timeout` (Optional, string | -1 | 0)* -** *`allow_partial_search_results` (Optional, boolean)* -** *`allow_partial_sequence_results` (Optional, boolean)* +** *`allow_partial_search_results` (Optional, boolean)*: Allow query execution also in case of shard failures. +If true, the query will keep running and will return results based on the available shards. +For sequences, the behavior can be further refined using allow_partial_sequence_results +** *`allow_partial_sequence_results` (Optional, boolean)*: This flag applies only to sequences and has effect only if allow_partial_search_results=true. +If true, the sequence query will return results based on the available shards, ignoring the others. +If false, the sequence query will return successfully, but will always have empty results. ** *`size` (Optional, number)*: For basic queries, the maximum number of matching events to return. Defaults to 10 ** *`fields` (Optional, { field, format, include_unmapped } | { field, format, include_unmapped }[])*: Array of wildcard (*) patterns. The response returns values for field names matching these patterns in the fields property of each hit. ** *`result_position` (Optional, Enum("tail" | "head"))* @@ -4717,7 +4963,7 @@ Asynchronously run an ES|QL (Elasticsearch query language) query, monitor its pr The API accepts the same parameters and request body as the synchronous query API, along with additional async related properties. -{ref}/esql-async-query-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-esql-async-query[Endpoint documentation] [source,ts] ---- client.esql.asyncQuery({ query }) @@ -4765,7 +5011,7 @@ If the Elasticsearch security features are enabled, only the following users can * The authenticated user that submitted the original query request * Users with the `cancel_task` cluster privilege -{ref}/esql-async-query-delete-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-esql-async-query-delete[Endpoint documentation] [source,ts] ---- client.esql.asyncQueryDelete({ id }) @@ -4785,7 +5031,7 @@ Get async ES|QL query results. Get the current status and available results or stored results for an ES|QL asynchronous query. If the Elasticsearch security features are enabled, only the user who first submitted the ES|QL query can retrieve the results using this API. -{ref}/esql-async-query-get-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-esql-async-query-get[Endpoint documentation] [source,ts] ---- client.esql.asyncQueryGet({ id }) @@ -4807,6 +5053,29 @@ By default, the request waits for complete query results. If the request completes during the period specified in this parameter, complete query results are returned. Otherwise, the response returns an `is_running` value of `true` and no results. +[discrete] +==== async_query_stop +Stop async ES|QL query. + +This API interrupts the query execution and returns the results so far. +If the Elasticsearch security features are enabled, only the user who first submitted the ES|QL query can stop it. + +{ref}/esql-async-query-stop-api.html[Endpoint documentation] +[source,ts] +---- +client.esql.asyncQueryStop({ id }) +---- + +[discrete] +==== Arguments + +* *Request (object):* +** *`id` (string)*: The unique identifier of the query. +A query ID is provided in the ES|QL async query API response for a query that does not complete in the designated time. +A query ID is also provided when the request was submitted with the `keep_on_completion` parameter set to `true`. +** *`drop_null_columns` (Optional, boolean)*: Indicates whether columns that are entirely `null` will be removed from the `columns` and `values` portion of the results. +If `true`, the response will include an extra section under the name `all_columns` which has the name of all the columns. + [discrete] ==== query Run an ES|QL query. @@ -4853,7 +5122,7 @@ In order to ensure data integrity, all system indices that comprise a feature st The features listed by this API are a combination of built-in features and features defined by plugins. In order for a feature state to be listed in this API and recognized as a valid feature state by the create snapshot API, the plugin that defines that feature must be installed on the master node. -{ref}/get-features-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-features-get-features[Endpoint documentation] [source,ts] ---- client.features.getFeatures({ ... }) @@ -4885,7 +5154,7 @@ To list the features that will be affected, use the get features API. IMPORTANT: The features installed on the node you submit this request to are the features that will be reset. Run on the master node if you have any doubts about which plugins are installed on individual nodes. -{ref}/modules-snapshots.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-features-reset-features[Endpoint documentation] [source,ts] ---- client.features.resetFeatures({ ... }) @@ -4902,10 +5171,11 @@ client.features.resetFeatures({ ... }) [discrete] ==== global_checkpoints Get global checkpoints. + Get the current global checkpoints for an index. This API is designed for internal use by the Fleet server project. -{ref}/get-global-checkpoints.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-fleet[Endpoint documentation] [source,ts] ---- client.fleet.globalCheckpoints({ index }) @@ -4931,6 +5201,8 @@ Run multiple Fleet searches. Run several Fleet searches with a single API request. The API follows the same structure as the multi search API. However, similar to the Fleet search API, it supports the `wait_for_checkpoints` parameter. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-fleet-msearch[Endpoint documentation] [source,ts] ---- client.fleet.msearch({ ... }) @@ -4965,6 +5237,8 @@ which is true by default. Run a Fleet search. The purpose of the Fleet search API is to provide an API where the search will be run only after the provided checkpoint has been processed and is visible for searches inside of Elasticsearch. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-fleet-search[Endpoint documentation] [source,ts] ---- client.fleet.search({ index }) @@ -5074,7 +5348,7 @@ An initial request to the `_explore` API contains a seed query that identifies t Subsequent requests enable you to spider out from one more vertices of interest. You can exclude vertices that have already been returned. -{ref}/graph-explore-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-graph[Endpoint documentation] [source,ts] ---- client.graph.explore({ index }) @@ -5101,7 +5375,7 @@ Defaults to no timeout. Delete a lifecycle policy. You cannot delete policies that are currently in use. If the policy is being used to manage any indices, the request fails and returns an error. -{ref}/ilm-delete-lifecycle.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-delete-lifecycle[Endpoint documentation] [source,ts] ---- client.ilm.deleteLifecycle({ policy }) @@ -5123,7 +5397,7 @@ For data streams, the API retrieves the current lifecycle status for the stream' The response indicates when the index entered each lifecycle state, provides the definition of the running phase, and information about any failures. -{ref}/ilm-explain-lifecycle.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-explain-lifecycle[Endpoint documentation] [source,ts] ---- client.ilm.explainLifecycle({ index }) @@ -5143,7 +5417,7 @@ To target all data streams and indices, use `*` or `_all`. ==== get_lifecycle Get lifecycle policies. -{ref}/ilm-get-lifecycle.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-get-lifecycle[Endpoint documentation] [source,ts] ---- client.ilm.getLifecycle({ ... }) @@ -5160,9 +5434,10 @@ client.ilm.getLifecycle({ ... }) [discrete] ==== get_status Get the ILM status. + Get the current index lifecycle management status. -{ref}/ilm-get-status.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-get-status[Endpoint documentation] [source,ts] ---- client.ilm.getStatus() @@ -5186,7 +5461,7 @@ This API provides an automated way of performing three out of the four manual st ILM must be stopped before performing the migration. Use the stop ILM and get ILM status APIs to wait until the reported operation mode is `STOPPED`. -{ref}/ilm-migrate-to-data-tiers.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-migrate-to-data-tiers[Endpoint documentation] [source,ts] ---- client.ilm.migrateToDataTiers({ ... }) @@ -5218,7 +5493,7 @@ If the phase and action are specified, the index will move to the first step of Only actions specified in the ILM policy are considered valid. An index cannot move to a step that is not part of its policy. -{ref}/ilm-move-to-step.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-move-to-step[Endpoint documentation] [source,ts] ---- client.ilm.moveToStep({ index, current_step, next_step }) @@ -5239,7 +5514,7 @@ If the specified policy exists, it is replaced and the policy version is increme NOTE: Only the latest version of the policy is stored, you cannot revert to previous versions. -{ref}/ilm-put-lifecycle.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-put-lifecycle[Endpoint documentation] [source,ts] ---- client.ilm.putLifecycle({ policy }) @@ -5259,7 +5534,7 @@ Remove policies from an index. Remove the assigned lifecycle policies from an index or a data stream's backing indices. It also stops managing the indices. -{ref}/ilm-remove-policy.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-remove-policy[Endpoint documentation] [source,ts] ---- client.ilm.removePolicy({ index }) @@ -5278,7 +5553,7 @@ Retry running the lifecycle policy for an index that is in the ERROR step. The API sets the policy back to the step where the error occurred and runs the step. Use the explain lifecycle state API to determine whether an index is in the ERROR step. -{ref}/ilm-retry-policy.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-retry[Endpoint documentation] [source,ts] ---- client.ilm.retry({ index }) @@ -5297,7 +5572,7 @@ Start the index lifecycle management plugin if it is currently stopped. ILM is started automatically when the cluster is formed. Restarting ILM is necessary only when it has been stopped using the stop ILM API. -{ref}/ilm-start.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-start[Endpoint documentation] [source,ts] ---- client.ilm.start({ ... }) @@ -5319,7 +5594,7 @@ This is useful when you are performing maintenance on the cluster and need to pr The API returns as soon as the stop request has been acknowledged, but the plugin might continue to run until in-progress operations complete and the plugin can be safely stopped. Use the get ILM status API to check whether ILM is running. -{ref}/ilm-stop.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-stop[Endpoint documentation] [source,ts] ---- client.ilm.stop({ ... }) @@ -5337,9 +5612,11 @@ client.ilm.stop({ ... }) [discrete] ==== add_block Add an index block. -Limits the operations allowed on an index by blocking specific operation types. -{ref}/index-modules-blocks.html[Endpoint documentation] +Add an index block to an index. +Index blocks limit the operations allowed on an index by blocking specific operation types. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-add-block[Endpoint documentation] [source,ts] ---- client.indices.addBlock({ index, block }) @@ -5349,13 +5626,24 @@ client.indices.addBlock({ index, block }) ==== Arguments * *Request (object):* -** *`index` (string)*: A comma separated list of indices to add a block to -** *`block` (Enum("metadata" | "read" | "read_only" | "write"))*: The block to add (one of read, write, read_only or metadata) -** *`allow_no_indices` (Optional, 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` (Optional, Enum("all" | "open" | "closed" | "hidden" | "none") | Enum("all" | "open" | "closed" | "hidden" | "none")[])*: Whether to expand wildcard expression to concrete indices that are open, closed or both. -** *`ignore_unavailable` (Optional, boolean)*: Whether specified concrete indices should be ignored when unavailable (missing or closed) -** *`master_timeout` (Optional, string | -1 | 0)*: Specify timeout for connection to master -** *`timeout` (Optional, string | -1 | 0)*: Explicit operation timeout +** *`index` (string)*: A list or wildcard expression of index names used to limit the request. +By default, you must explicitly name the indices you are adding blocks to. +To allow the adding of blocks to indices with `_all`, `*`, or other wildcard expressions, change the `action.destructive_requires_name` setting to `false`. +You can update this setting in the `elasticsearch.yml` file or by using the cluster update settings API. +** *`block` (Enum("metadata" | "read" | "read_only" | "write"))*: The block type to add to the index. +** *`allow_no_indices` (Optional, boolean)*: If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. +This behavior applies even if the request targets other open indices. +For example, a request targeting `foo*,bar*` returns an error if an index starts with `foo` but no index starts with `bar`. +** *`expand_wildcards` (Optional, Enum("all" | "open" | "closed" | "hidden" | "none") | Enum("all" | "open" | "closed" | "hidden" | "none")[])*: The type of index that wildcard patterns can match. +If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. +It supports a list of values, such as `open,hidden`. +** *`ignore_unavailable` (Optional, boolean)*: If `false`, the request returns an error if it targets a missing or closed index. +** *`master_timeout` (Optional, string | -1 | 0)*: The period to wait for the master node. +If the master node is not available before the timeout expires, the request fails and returns an error. +It can also be set to `-1` to indicate that the request should never timeout. +** *`timeout` (Optional, string | -1 | 0)*: The period to wait for a response from all relevant nodes in the cluster after updating the cluster metadata. +If no response is received before the timeout expires, the cluster metadata update still applies but the response will indicate that it was not completely acknowledged. +It can also be set to `-1` to indicate that the request should never timeout. [discrete] ==== analyze @@ -5367,7 +5655,7 @@ The `index.analyze.max_token_count` setting enables you to limit the number of t If more than this limit of tokens gets generated, an error occurs. The `_analyze` endpoint without a specified index will always use `10000` as its limit. -{ref}/indices-analyze.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-analyze[Endpoint documentation] [source,ts] ---- client.indices.analyze({ ... }) @@ -5420,7 +5708,7 @@ By default, the clear cache API clears all caches. To clear only specific caches, use the `fielddata`, `query`, or `request` parameters. To clear the cache only of specific fields, use the `fields` parameter. -{ref}/indices-clearcache.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-clear-cache[Endpoint documentation] [source,ts] ---- client.indices.clearCache({ ... }) @@ -5494,7 +5782,7 @@ At that point, Elasticsearch will try to allocate any replicas and may decide to Because the clone operation creates a new index to clone the shards to, the wait for active shards setting on index creation applies to the clone index action as well. -{ref}/indices-clone-index.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-clone[Endpoint documentation] [source,ts] ---- client.indices.clone({ index, target }) @@ -5536,7 +5824,7 @@ To open or close indices with `_all`, `*`, or other wildcard expressions, change Closed indices consume a significant amount of disk-space which can cause problems in managed environments. Closing indices can be turned off with the cluster settings API by setting `cluster.indices.close.enable` to `false`. -{ref}/indices-close.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-close[Endpoint documentation] [source,ts] ---- client.indices.close({ index }) @@ -5584,7 +5872,7 @@ If `shards_acknowledged` is false, then the request timed out before the requisi You can change the default of only waiting for the primary shards to start through the index setting `index.write.wait_for_active_shards`. Note that changing this setting will also affect the `wait_for_active_shards` value on all subsequent write operations. -{ref}/indices-create-index.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-create[Endpoint documentation] [source,ts] ---- client.indices.create({ index }) @@ -5611,10 +5899,10 @@ Set to `all` or any positive integer up to the total number of shards in the ind [discrete] ==== create_data_stream Create a data stream. -Creates a data stream. + You must have a matching index template with data stream enabled. -{ref}/data-streams.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-create-data-stream[Endpoint documentation] [source,ts] ---- client.indices.createDataStream({ name }) @@ -5654,9 +5942,10 @@ client.indices.createFrom({ source, dest }) [discrete] ==== data_streams_stats Get data stream stats. -Retrieves statistics for one or more data streams. -{ref}/data-streams.html[Endpoint documentation] +Get statistics for one or more data streams. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-data-streams-stats-1[Endpoint documentation] [source,ts] ---- client.indices.dataStreamsStats({ ... }) @@ -5682,7 +5971,7 @@ You cannot delete the current write index of a data stream. To delete the index, you must roll over the data stream so a new write index is created. You can then use the delete index API to delete the previous write index. -{ref}/indices-delete-index.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-delete[Endpoint documentation] [source,ts] ---- client.indices.delete({ index }) @@ -5713,7 +6002,7 @@ If no response is received before the timeout expires, the request fails and ret Delete an alias. Removes a data stream or index from an alias. -{ref}/indices-delete-alias.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-delete-alias[Endpoint documentation] [source,ts] ---- client.indices.deleteAlias({ index, name }) @@ -5737,7 +6026,7 @@ If no response is received before the timeout expires, the request fails and ret Delete data stream lifecycles. Removes the data stream lifecycle from a data stream, rendering it not managed by the data stream lifecycle. -{ref}/data-streams-delete-lifecycle.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-delete-data-lifecycle[Endpoint documentation] [source,ts] ---- client.indices.deleteDataLifecycle({ name }) @@ -5757,7 +6046,7 @@ client.indices.deleteDataLifecycle({ name }) Delete data streams. Deletes one or more data streams and their backing indices. -{ref}/data-streams.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-delete-data-stream[Endpoint documentation] [source,ts] ---- client.indices.deleteDataStream({ name }) @@ -5778,7 +6067,7 @@ The provided may contain multiple template names separated by a names are specified then there is no wildcard support and the provided names should match completely with existing templates. -{ref}/indices-delete-template.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-delete-index-template[Endpoint documentation] [source,ts] ---- client.indices.deleteIndexTemplate({ name }) @@ -5796,7 +6085,7 @@ client.indices.deleteIndexTemplate({ name }) ==== delete_template Delete a legacy index template. -{ref}/indices-delete-template-v1.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-delete-template[Endpoint documentation] [source,ts] ---- client.indices.deleteTemplate({ name }) @@ -5824,7 +6113,7 @@ NOTE: The total size of fields of the analyzed shards of the index in the respon Since stored fields are stored together in a compressed format, the sizes of stored fields are also estimates and can be inaccurate. The stored size of the `_id` field is likely underestimated while the `_source` field is overestimated. -{ref}/indices-disk-usage.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-disk-usage[Endpoint documentation] [source,ts] ---- client.indices.diskUsage({ index }) @@ -5859,7 +6148,7 @@ NOTE: Only indices in a time series data stream are supported. Neither field nor document level security can be defined on the source index. The source index must be read only (`index.blocks.write: true`). -{ref}/indices-downsample-data-stream.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-downsample[Endpoint documentation] [source,ts] ---- client.indices.downsample({ index, target_index }) @@ -5878,7 +6167,7 @@ client.indices.downsample({ index, target_index }) Check indices. Check if one or more indices, index aliases, or data streams exist. -{ref}/indices-exists.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-exists[Endpoint documentation] [source,ts] ---- client.indices.exists({ index }) @@ -5903,9 +6192,10 @@ Valid values are: `all`, `open`, `closed`, `hidden`, `none`. [discrete] ==== exists_alias Check aliases. -Checks if one or more data stream or index aliases exist. -{ref}/indices-aliases.html[Endpoint documentation] +Check if one or more data stream or index aliases exist. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-exists-alias[Endpoint documentation] [source,ts] ---- client.indices.existsAlias({ name }) @@ -5931,9 +6221,10 @@ If no response is received before the timeout expires, the request fails and ret [discrete] ==== exists_index_template Check index templates. + Check whether index templates exist. -{ref}/index-templates.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-exists-index-template[Endpoint documentation] [source,ts] ---- client.indices.existsIndexTemplate({ name }) @@ -5954,7 +6245,7 @@ Index templates define settings, mappings, and aliases that can be applied autom IMPORTANT: This documentation is about legacy index templates, which are deprecated and will be replaced by the composable templates introduced in Elasticsearch 7.8. -{ref}/indices-template-exists-v1.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-exists-template[Endpoint documentation] [source,ts] ---- client.indices.existsTemplate({ name }) @@ -5977,7 +6268,7 @@ To indicate that the request should never timeout, set it to `-1`. Get the status for a data stream lifecycle. Get information about an index or data stream's current data stream lifecycle status, such as time since index creation, time since rollover, the lifecycle configuration managing the index, or any errors encountered during lifecycle execution. -{ref}/data-streams-explain-lifecycle.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-explain-data-lifecycle[Endpoint documentation] [source,ts] ---- client.indices.explainDataLifecycle({ index }) @@ -6001,7 +6292,7 @@ A shard-level search request that accesses a given field, even if multiple times The response body reports the per-shard usage count of the data structures that back the fields in the index. A given request will increment each count by a maximum value of 1, even if the request accesses the same field multiple times. -{ref}/field-usage-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-field-usage-stats[Endpoint documentation] [source,ts] ---- client.indices.fieldUsageStats({ index }) @@ -6037,7 +6328,7 @@ The transaction log is made up of multiple files, called generations, and Elasti It is also possible to trigger a flush on one or more indices using the flush API, although it is rare for users to need to call this API directly. If you call the flush API after indexing some documents then a successful response indicates that Elasticsearch has flushed all the documents that were indexed before the flush API was called. -{ref}/indices-flush.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-flush[Endpoint documentation] [source,ts] ---- client.indices.flush({ ... }) @@ -6117,7 +6408,7 @@ For example: POST /.ds-my-data-stream-2099.03.07-000001/_forcemerge?max_num_segments=1 ---- -{ref}/indices-forcemerge.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-forcemerge[Endpoint documentation] [source,ts] ---- client.indices.forcemerge({ ... }) @@ -6142,7 +6433,7 @@ Get index information. Get information about one or more indices. For data streams, the API returns information about the stream’s backing indices. -{ref}/indices-get-index.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get[Endpoint documentation] [source,ts] ---- client.indices.get({ index }) @@ -6172,7 +6463,7 @@ such as open,hidden. Get aliases. Retrieves information for one or more data stream or index aliases. -{ref}/indices-get-alias.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-alias[Endpoint documentation] [source,ts] ---- client.indices.getAlias({ ... }) @@ -6201,9 +6492,10 @@ If no response is received before the timeout expires, the request fails and ret [discrete] ==== get_data_lifecycle Get data stream lifecycles. -Retrieves the data stream lifecycle configuration of one or more data streams. -{ref}/data-streams-get-lifecycle.html[Endpoint documentation] +Get the data stream lifecycle configuration of one or more data streams. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-data-lifecycle[Endpoint documentation] [source,ts] ---- client.indices.getDataLifecycle({ name }) @@ -6227,7 +6519,7 @@ Valid values are: `all`, `open`, `closed`, `hidden`, `none`. Get data stream lifecycle stats. Get statistics about the data streams that are managed by a data stream lifecycle. -{ref}/data-streams-get-lifecycle-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-data-lifecycle-stats[Endpoint documentation] [source,ts] ---- client.indices.getDataLifecycleStats() @@ -6237,9 +6529,10 @@ client.indices.getDataLifecycleStats() [discrete] ==== get_data_stream Get data streams. -Retrieves information about one or more data streams. -{ref}/data-streams.html[Endpoint documentation] +Get information about one or more data streams. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-data-stream[Endpoint documentation] [source,ts] ---- client.indices.getDataStream({ ... }) @@ -6265,7 +6558,7 @@ For data streams, the API retrieves field mappings for the stream’s backing in This API is useful if you don't need a complete mapping or if an index mapping contains a large number of fields. -{ref}/indices-get-field-mapping.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-mapping[Endpoint documentation] [source,ts] ---- client.indices.getFieldMapping({ fields }) @@ -6295,7 +6588,7 @@ Valid values are: `all`, `open`, `closed`, `hidden`, `none`. Get index templates. Get information about one or more index templates. -{ref}/indices-get-template.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-index-template[Endpoint documentation] [source,ts] ---- client.indices.getIndexTemplate({ ... }) @@ -6316,7 +6609,7 @@ client.indices.getIndexTemplate({ ... }) Get mapping definitions. For data streams, the API retrieves mappings for the stream’s backing indices. -{ref}/indices-get-mapping.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-mapping[Endpoint documentation] [source,ts] ---- client.indices.getMapping({ ... }) @@ -6362,7 +6655,7 @@ Get index settings. Get setting information for one or more indices. For data streams, it returns setting information for the stream's backing indices. -{ref}/indices-get-settings.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-settings[Endpoint documentation] [source,ts] ---- client.indices.getSettings({ ... }) @@ -6400,7 +6693,7 @@ Get information about one or more index templates. IMPORTANT: This documentation is about legacy index templates, which are deprecated and will be replaced by the composable templates introduced in Elasticsearch 7.8. -{ref}/indices-get-template-v1.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-template[Endpoint documentation] [source,ts] ---- client.indices.getTemplate({ ... }) @@ -6507,7 +6800,7 @@ Closing indices can be turned off with the cluster settings API by setting `clus Because opening or closing an index allocates its shards, the `wait_for_active_shards` setting on index creation applies to the `_open` and `_close` index actions as well. -{ref}/indices-open-close.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-open[Endpoint documentation] [source,ts] ---- client.indices.open({ index }) @@ -6737,7 +7030,7 @@ If you need to change the mapping of a field in other indices, create a new inde Renaming a field would invalidate data already indexed under the old field name. Instead, add an alias field to create an alternate field name. -{ref}/indices-put-mapping.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-put-mapping[Endpoint documentation] [source,ts] ---- client.indices.putMapping({ index }) @@ -6799,7 +7092,7 @@ This affects searches and any new data added to the stream after the rollover. However, it does not affect the data stream's backing indices or their existing data. To change the analyzer for existing backing indices, you must create a new data stream and reindex your data into it. -{ref}/indices-update-settings.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-put-settings[Endpoint documentation] [source,ts] ---- client.indices.putSettings({ ... }) @@ -6855,7 +7148,7 @@ Multiple index templates can potentially match an index, in this case, both the The order of the merging can be controlled using the order parameter, with lower order being applied first, and higher orders overriding them. NOTE: Multiple matching templates with the same order value will result in a non-deterministic merging order. -{ref}/indices-templates-v1.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-put-template[Endpoint documentation] [source,ts] ---- client.indices.putTemplate({ name }) @@ -6910,7 +7203,7 @@ The index recovery API reports information about completed recoveries only for s It only reports the last recovery for each shard copy and does not report historical information about earlier recoveries, nor does it report information about the recoveries of shard copies that no longer exist. This means that if a shard copy completes a recovery and then Elasticsearch relocates it onto a different node then the information about the original recovery will not be shown in the recovery API. -{ref}/indices-recovery.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-recovery[Endpoint documentation] [source,ts] ---- client.indices.recovery({ ... }) @@ -6943,7 +7236,7 @@ To ensure good cluster performance, it's recommended to wait for Elasticsearch's If your application workflow indexes documents and then runs a search to retrieve the indexed document, it's recommended to use the index API's `refresh=wait_for` query parameter option. This option ensures the indexing operation waits for a periodic refresh before running the search. -{ref}/indices-refresh.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-refresh[Endpoint documentation] [source,ts] ---- client.indices.refresh({ ... }) @@ -6981,7 +7274,7 @@ As a result, the total shard count returned by the API can differ from the numbe Because reloading affects every node with an index shard, it is important to update the synonym file on every data node in the cluster--including nodes that don't contain a shard replica--before using this API. This ensures the synonym file is updated everywhere in the cluster in case shards are relocated in the future. -{ref}/indices-reload-analyzers.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-reload-search-analyzers[Endpoint documentation] [source,ts] ---- client.indices.reloadSearchAnalyzers({ index }) @@ -6999,8 +7292,9 @@ client.indices.reloadSearchAnalyzers({ index }) [discrete] ==== resolve_cluster Resolve the cluster. -Resolve the specified index expressions to return information about each cluster, including the local cluster, if included. -Multiple patterns and remote clusters are supported. + +Resolve the specified index expressions to return information about each cluster, including the local "querying" cluster, if included. +If no index expression is provided, the API will return information about all the remote clusters that are configured on the querying cluster. This endpoint is useful before doing a cross-cluster search in order to determine which remote clusters should be included in a search. @@ -7009,7 +7303,7 @@ Index and cluster exclusions are also supported with this endpoint. For each cluster in the index expression, information is returned about: -* Whether the querying ("local") cluster is currently connected to each remote cluster in the index expression scope. +* Whether the querying ("local") cluster is currently connected to each remote cluster specified in the index expression. Note that this endpoint actively attempts to contact the remote clusters, unlike the `remote/info` endpoint. * Whether each remote cluster is configured with `skip_unavailable` as `true` or `false`. * Whether there are any indices, aliases, or data streams on that cluster that match the index expression. * Whether the search is likely to have errors returned when you do the cross-cluster search (including any authorization errors if you do not have permission to query the index). @@ -7018,7 +7312,14 @@ For each cluster in the index expression, information is returned about: For example, `GET /_resolve/cluster/my-index-*,cluster*:my-index-*` returns information about the local cluster and all remotely configured clusters that start with the alias `cluster*`. Each cluster returns information about whether it has any indices, aliases or data streams that match `my-index-*`. -**Advantages of using this endpoint before a cross-cluster search** +## Note on backwards compatibility +The ability to query without an index expression was added in version 8.18, so when +querying remote clusters older than that, the local cluster will send the index +expression `dummy*` to those remote clusters. Thus, if an errors occur, you may see a reference +to that index expression even though you didn't request it. If it causes a problem, you can +instead include an index expression like `*:*` to bypass the issue. + +## Advantages of using this endpoint before a cross-cluster search You may want to exclude a cluster or index from a search when: @@ -7027,27 +7328,56 @@ You may want to exclude a cluster or index from a search when: * The index expression (combined with any query parameters you specify) will likely cause an exception to be thrown when you do the search. In these cases, the "error" field in the `_resolve/cluster` response will be present. (This is also where security/permission errors will be shown.) * A remote cluster is an older version that does not support the feature you want to use in your search. -{ref}/indices-resolve-cluster-api.html[Endpoint documentation] +## Test availability of remote clusters + +The `remote/info` endpoint is commonly used to test whether the "local" cluster (the cluster being queried) is connected to its remote clusters, but it does not necessarily reflect whether the remote cluster is available or not. +The remote cluster may be available, while the local cluster is not currently connected to it. + +You can use the `_resolve/cluster` API to attempt to reconnect to remote clusters. +For example with `GET _resolve/cluster` or `GET _resolve/cluster/*:*`. +The `connected` field in the response will indicate whether it was successful. +If a connection was (re-)established, this will also cause the `remote/info` endpoint to now indicate a connected status. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-resolve-cluster[Endpoint documentation] [source,ts] ---- -client.indices.resolveCluster({ name }) +client.indices.resolveCluster({ ... }) ---- [discrete] ==== Arguments * *Request (object):* -** *`name` (string | string[])*: Comma-separated name(s) or index pattern(s) of the indices, aliases, and data streams to resolve. +** *`name` (Optional, string | string[])*: A list of names or index patterns for the indices, aliases, and data streams to resolve. Resources on remote clusters can be specified using the ``:`` syntax. -** *`allow_no_indices` (Optional, boolean)*: If false, the request returns an error if any wildcard expression, index alias, or _all value targets only missing +Index and cluster exclusions (e.g., `-cluster1:*`) are also supported. +If no index expression is specified, information about all remote clusters configured on the local cluster +is returned without doing any index matching +** *`allow_no_indices` (Optional, boolean)*: If false, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request -targeting foo*,bar* returns an error if an index starts with foo but no index starts with bar. +targeting `foo*,bar*` returns an error if an index starts with `foo` but no index starts with `bar`. +NOTE: This option is only supported when specifying an index expression. You will get an error if you specify index +options to the `_resolve/cluster` API endpoint that takes no index expression. ** *`expand_wildcards` (Optional, Enum("all" | "open" | "closed" | "hidden" | "none") | Enum("all" | "open" | "closed" | "hidden" | "none")[])*: Type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports a list of values, such as `open,hidden`. Valid values are: `all`, `open`, `closed`, `hidden`, `none`. -** *`ignore_throttled` (Optional, boolean)*: If true, concrete, expanded or aliased indices are ignored when frozen. Defaults to false. -** *`ignore_unavailable` (Optional, boolean)*: If false, the request returns an error if it targets a missing or closed index. Defaults to false. +NOTE: This option is only supported when specifying an index expression. You will get an error if you specify index +options to the `_resolve/cluster` API endpoint that takes no index expression. +** *`ignore_throttled` (Optional, boolean)*: If true, concrete, expanded, or aliased indices are ignored when frozen. +NOTE: This option is only supported when specifying an index expression. You will get an error if you specify index +options to the `_resolve/cluster` API endpoint that takes no index expression. +** *`ignore_unavailable` (Optional, boolean)*: If false, the request returns an error if it targets a missing or closed index. +NOTE: This option is only supported when specifying an index expression. You will get an error if you specify index +options to the `_resolve/cluster` API endpoint that takes no index expression. +** *`timeout` (Optional, string | -1 | 0)*: The maximum time to wait for remote clusters to respond. +If a remote cluster does not respond within this timeout period, the API response +will show the cluster as not connected and include an error message that the +request timed out. + +The default timeout is unset and the query can take +as long as the networking layer is configured to wait for remote clusters that are +not responding (typically 30 seconds). [discrete] ==== resolve_index @@ -7055,7 +7385,7 @@ Resolve indices. Resolve the names and/or index patterns for indices, aliases, and data streams. Multiple patterns and remote clusters are supported. -{ref}/indices-resolve-index-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-resolve-index[Endpoint documentation] [source,ts] ---- client.indices.resolveIndex({ name }) @@ -7117,7 +7447,7 @@ For example, you can create an alias that points to an index named ` info +> The inference APIs enable you to use certain services, such as built-in machine learning models (ELSER, E5), models uploaded through Eland, Cohere, OpenAI, Azure, Google AI Studio, Google Vertex AI, Anthropic, Watsonx.ai, or Hugging Face. For built-in models and models uploaded through Eland, the inference APIs offer an alternative way to use and manage trained models. However, if you do not plan to use the inference APIs to use these models or if you want to use non-NLP models, use the machine learning trained model APIs. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-inference-inference[Endpoint documentation] [source,ts] ---- client.inference.inference({ inference_id, input }) @@ -7538,14 +7875,18 @@ client.inference.inference({ inference_id, input }) ==== Arguments * *Request (object):* -** *`inference_id` (string)*: The inference Id -** *`input` (string | string[])*: Inference input. -Either a string or an array of strings. -** *`task_type` (Optional, Enum("sparse_embedding" | "text_embedding" | "rerank" | "completion"))*: The task type -** *`query` (Optional, string)*: Query input, required for rerank task. -Not required for other tasks. -** *`task_settings` (Optional, User-defined value)*: Optional task settings -** *`timeout` (Optional, string | -1 | 0)*: Specifies the amount of time to wait for the inference request to complete. +** *`inference_id` (string)*: The unique identifier for the inference endpoint. +** *`input` (string | string[])*: The text on which you want to perform the inference task. +It can be a single string or an array. + +> info +> Inference endpoints for the `completion` task type currently only support a single string as input. +** *`task_type` (Optional, Enum("sparse_embedding" | "text_embedding" | "rerank" | "completion"))*: The type of inference task that the model performs. +** *`query` (Optional, string)*: The query input, which is required only for the `rerank` task. +It is not required for other tasks. +** *`task_settings` (Optional, User-defined value)*: Task settings for the individual inference request. +These settings are specific to the task type you specified and override the task settings specified when initializing the service. +** *`timeout` (Optional, string | -1 | 0)*: The amount of time to wait for the inference request to complete. [discrete] ==== put @@ -7560,7 +7901,7 @@ IMPORTANT: The inference APIs enable you to use certain services, such as built- For built-in models and models uploaded through Eland, the inference APIs offer an alternative way to use and manage trained models. However, if you do not plan to use the inference APIs to use these models or if you want to use non-NLP models, use the machine learning trained model APIs. -{ref}/put-inference-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-inference-put[Endpoint documentation] [source,ts] ---- client.inference.put({ inference_id }) @@ -7584,7 +7925,7 @@ IMPORTANT: The inference APIs enable you to use certain services, such as built- This API requires the `monitor_inference` cluster privilege (the built-in `inference_admin` and `inference_user` roles grant this privilege). You must use a client that supports streaming. -{ref}/stream-inference-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-inference-stream-inference[Endpoint documentation] [source,ts] ---- client.inference.streamInference({ inference_id, input }) @@ -7635,7 +7976,7 @@ IMPORTANT: The inference APIs enable you to use certain services, such as built- For built-in models and models uploaded through Eland, the inference APIs offer an alternative way to use and manage trained models. However, if you do not plan to use the inference APIs to use these models or if you want to use non-NLP models, use the machine learning trained model APIs. -{ref}/update-inference-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-inference-update[Endpoint documentation] [source,ts] ---- client.inference.update({ inference_id }) @@ -7654,9 +7995,10 @@ client.inference.update({ inference_id }) [discrete] ==== delete_geoip_database Delete GeoIP database configurations. + Delete one or more IP geolocation database configurations. -{ref}/delete-geoip-database-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-delete-geoip-database[Endpoint documentation] [source,ts] ---- client.ingest.deleteGeoipDatabase({ id }) @@ -7667,15 +8009,15 @@ client.ingest.deleteGeoipDatabase({ id }) * *Request (object):* ** *`id` (string | string[])*: A list of geoip database configurations to delete -** *`master_timeout` (Optional, string | -1 | 0)*: Period to wait for a connection to the master node. +** *`master_timeout` (Optional, string | -1 | 0)*: The period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error. -** *`timeout` (Optional, string | -1 | 0)*: Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. +** *`timeout` (Optional, string | -1 | 0)*: The period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. [discrete] ==== delete_ip_location_database Delete IP geolocation database configurations. -{ref}/delete-ip-location-database-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-delete-ip-location-database[Endpoint documentation] [source,ts] ---- client.ingest.deleteIpLocationDatabase({ id }) @@ -7698,7 +8040,7 @@ A value of `-1` indicates that the request should never time out. Delete pipelines. Delete one or more ingest pipelines. -{ref}/delete-pipeline-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-delete-pipeline[Endpoint documentation] [source,ts] ---- client.ingest.deletePipeline({ id }) @@ -7730,9 +8072,10 @@ client.ingest.geoIpStats() [discrete] ==== get_geoip_database Get GeoIP database configurations. + Get information about one or more IP geolocation database configurations. -{ref}/get-geoip-database-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-get-geoip-database[Endpoint documentation] [source,ts] ---- client.ingest.getGeoipDatabase({ ... }) @@ -7742,7 +8085,7 @@ client.ingest.getGeoipDatabase({ ... }) ==== Arguments * *Request (object):* -** *`id` (Optional, string | string[])*: List of database configuration IDs to retrieve. +** *`id` (Optional, string | string[])*: A list of database configuration IDs to retrieve. Wildcard (`*`) expressions are supported. To get all database configurations, omit this parameter or use `*`. @@ -7750,7 +8093,7 @@ To get all database configurations, omit this parameter or use `*`. ==== get_ip_location_database Get IP geolocation database configurations. -{ref}/get-ip-location-database-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-get-ip-location-database[Endpoint documentation] [source,ts] ---- client.ingest.getIpLocationDatabase({ ... }) @@ -7770,10 +8113,11 @@ A value of `-1` indicates that the request should never time out. [discrete] ==== get_pipeline Get pipelines. + Get information about one or more ingest pipelines. This API returns a local reference of the pipeline. -{ref}/get-pipeline-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-get-pipeline[Endpoint documentation] [source,ts] ---- client.ingest.getPipeline({ ... }) @@ -7807,9 +8151,10 @@ client.ingest.processorGrok() [discrete] ==== put_geoip_database Create or update a GeoIP database configuration. + Refer to the create or update IP geolocation database configuration API. -{ref}/put-geoip-database-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-put-geoip-database[Endpoint documentation] [source,ts] ---- client.ingest.putGeoipDatabase({ id, name, maxmind }) @@ -7831,7 +8176,7 @@ If no response is received before the timeout expires, the request fails and ret ==== put_ip_location_database Create or update an IP geolocation database configuration. -{ref}/put-ip-location-database-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-put-ip-location-database[Endpoint documentation] [source,ts] ---- client.ingest.putIpLocationDatabase({ id }) @@ -7880,10 +8225,11 @@ When a deprecated ingest pipeline is referenced as the default or final pipeline [discrete] ==== simulate Simulate a pipeline. + Run an ingest pipeline against a set of provided documents. You can either specify an existing pipeline to use with the provided documents or supply a pipeline definition in the body of the request. -{ref}/simulate-pipeline-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-simulate[Endpoint documentation] [source,ts] ---- client.ingest.simulate({ docs }) @@ -7894,10 +8240,10 @@ client.ingest.simulate({ docs }) * *Request (object):* ** *`docs` ({ _id, _index, _source }[])*: Sample documents to test in the pipeline. -** *`id` (Optional, string)*: Pipeline to test. -If you don’t specify a `pipeline` in the request body, this parameter is required. -** *`pipeline` (Optional, { description, on_failure, processors, version, deprecated, _meta })*: Pipeline to test. -If you don’t specify the `pipeline` request path parameter, this parameter is required. +** *`id` (Optional, string)*: The pipeline to test. +If you don't specify a `pipeline` in the request body, this parameter is required. +** *`pipeline` (Optional, { description, on_failure, processors, version, deprecated, _meta })*: The pipeline to test. +If you don't specify the `pipeline` request path parameter, this parameter is required. If you specify both this and the request path parameter, the API only uses the request path parameter. ** *`verbose` (Optional, boolean)*: If `true`, the response includes output data for each processor in the executed pipeline. @@ -7906,11 +8252,12 @@ If you specify both this and the request path parameter, the API only uses the r [discrete] ==== delete Delete the license. + When the license expires, your subscription level reverts to Basic. If the operator privileges feature is enabled, only operator users can use this API. -{ref}/delete-license.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-delete[Endpoint documentation] [source,ts] ---- client.license.delete({ ... }) @@ -7920,18 +8267,20 @@ client.license.delete({ ... }) ==== Arguments * *Request (object):* -** *`master_timeout` (Optional, string | -1 | 0)*: Period to wait for a connection to the master node. -** *`timeout` (Optional, string | -1 | 0)*: Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. +** *`master_timeout` (Optional, string | -1 | 0)*: The period to wait for a connection to the master node. +** *`timeout` (Optional, string | -1 | 0)*: The period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. [discrete] ==== get Get license information. + Get information about your Elastic license including its type, its status, when it was issued, and when it expires. -NOTE: If the master node is generating a new cluster state, the get license API may return a `404 Not Found` response. -If you receive an unexpected 404 response after cluster startup, wait a short period and retry the request. +>info +> If the master node is generating a new cluster state, the get license API may return a `404 Not Found` response. +> If you receive an unexpected 404 response after cluster startup, wait a short period and retry the request. -{ref}/get-license.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-get[Endpoint documentation] [source,ts] ---- client.license.get({ ... }) @@ -7949,7 +8298,7 @@ This parameter is deprecated and will always be set to true in 8.x. ==== get_basic_status Get the basic license status. -{ref}/get-basic-status.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-get-basic-status[Endpoint documentation] [source,ts] ---- client.license.getBasicStatus() @@ -7960,7 +8309,7 @@ client.license.getBasicStatus() ==== get_trial_status Get the trial status. -{ref}/get-trial-status.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-get-trial-status[Endpoint documentation] [source,ts] ---- client.license.getTrialStatus() @@ -7970,6 +8319,7 @@ client.license.getTrialStatus() [discrete] ==== post Update the license. + You can update your license at runtime without shutting down your nodes. License updates take effect immediately. If the license you are installing does not support all of the features that were available with your previous license, however, you are notified in the response. @@ -7978,7 +8328,7 @@ You must then re-submit the API request with the acknowledge parameter set to tr NOTE: If Elasticsearch security features are enabled and you are installing a gold or higher license, you must enable TLS on the transport networking layer before you install the license. If the operator privileges feature is enabled, only operator users can use this API. -{ref}/update-license.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-post[Endpoint documentation] [source,ts] ---- client.license.post({ ... }) @@ -7991,12 +8341,13 @@ client.license.post({ ... }) ** *`license` (Optional, { expiry_date_in_millis, issue_date_in_millis, start_date_in_millis, issued_to, issuer, max_nodes, max_resource_units, signature, type, uid })* ** *`licenses` (Optional, { expiry_date_in_millis, issue_date_in_millis, start_date_in_millis, issued_to, issuer, max_nodes, max_resource_units, signature, type, uid }[])*: A sequence of one or more JSON documents containing the license information. ** *`acknowledge` (Optional, boolean)*: Specifies whether you acknowledge the license changes. -** *`master_timeout` (Optional, string | -1 | 0)*: Period to wait for a connection to the master node. -** *`timeout` (Optional, string | -1 | 0)*: Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. +** *`master_timeout` (Optional, string | -1 | 0)*: The period to wait for a connection to the master node. +** *`timeout` (Optional, string | -1 | 0)*: The period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. [discrete] ==== post_start_basic Start a basic license. + Start an indefinite basic license, which gives access to all the basic features. NOTE: In order to start a basic license, you must not currently have a basic license. @@ -8006,7 +8357,7 @@ You must then re-submit the API request with the `acknowledge` parameter set to To check the status of your basic license, use the get basic license API. -{ref}/start-basic.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-post-start-basic[Endpoint documentation] [source,ts] ---- client.license.postStartBasic({ ... }) @@ -8030,7 +8381,7 @@ For example, if you have already activated a trial for v8.0, you cannot start a To check the status of your trial, use the get trial status API. -{ref}/start-trial.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-post-start-trial[Endpoint documentation] [source,ts] ---- client.license.postStartTrial({ ... }) @@ -8052,7 +8403,7 @@ Delete a Logstash pipeline. Delete a pipeline that is used for Logstash Central Management. If the request succeeds, you receive an empty response with an appropriate status code. -{ref}/logstash-api-delete-pipeline.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-logstash-delete-pipeline[Endpoint documentation] [source,ts] ---- client.logstash.deletePipeline({ id }) @@ -8069,7 +8420,7 @@ client.logstash.deletePipeline({ id }) Get Logstash pipelines. Get pipelines that are used for Logstash Central Management. -{ref}/logstash-api-get-pipeline.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-logstash-get-pipeline[Endpoint documentation] [source,ts] ---- client.logstash.getPipeline({ ... }) @@ -8088,7 +8439,7 @@ Create or update a Logstash pipeline. Create a pipeline that is used for Logstash Central Management. If the specified pipeline exists, it is replaced. -{ref}/logstash-api-put-pipeline.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-logstash-put-pipeline[Endpoint documentation] [source,ts] ---- client.logstash.putPipeline({ id }) @@ -8111,7 +8462,7 @@ Get information about different cluster, node, and index level settings that use TIP: This APIs is designed for indirect use by the Upgrade Assistant. You are strongly recommended to use the Upgrade Assistant. -{ref}/migration-api-deprecation.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-migration-deprecations[Endpoint documentation] [source,ts] ---- client.migration.deprecations({ ... }) @@ -8132,7 +8483,7 @@ Check which features need to be migrated and the status of any migrations that a TIP: This API is designed for indirect use by the Upgrade Assistant. You are strongly recommended to use the Upgrade Assistant. -{ref}/feature-migration-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-migration-get-feature-upgrade-status[Endpoint documentation] [source,ts] ---- client.migration.getFeatureUpgradeStatus() @@ -8149,7 +8500,7 @@ Some functionality might be temporarily unavailable during the migration process TIP: The API is designed for indirect use by the Upgrade Assistant. We strongly recommend you use the Upgrade Assistant. -{ref}/feature-migration-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-migration-get-feature-upgrade-status[Endpoint documentation] [source,ts] ---- client.migration.postFeatureUpgrade() @@ -8161,12 +8512,13 @@ client.migration.postFeatureUpgrade() [discrete] ==== clear_trained_model_deployment_cache Clear trained model deployment cache. + Cache will be cleared on all nodes where the trained model is assigned. A trained model deployment may have an inference cache enabled. As requests are handled by each allocated node, their responses may be cached on that individual node. Calling this API clears the caches without restarting the deployment. -{ref}/clear-trained-model-deployment-cache.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-clear-trained-model-deployment-cache[Endpoint documentation] [source,ts] ---- client.ml.clearTrainedModelDeploymentCache({ model_id }) @@ -8181,12 +8533,13 @@ client.ml.clearTrainedModelDeploymentCache({ model_id }) [discrete] ==== close_job Close anomaly detection jobs. + A job can be opened and closed multiple times throughout its lifecycle. A closed job cannot receive data or perform analysis operations, but you can still explore and navigate results. When you close a job, it runs housekeeping tasks such as pruning the model history, flushing buffers, calculating final results and persisting the model snapshots. Depending upon the size of the job, it could take several minutes to close and the equivalent time to re-open. After it is closed, the job has a minimal overhead on the cluster except for maintaining its meta data. Therefore it is a best practice to close jobs that are no longer required to process data. If you close an anomaly detection job whose datafeed is running, the request first tries to stop the datafeed. This behavior is equivalent to calling stop datafeed API with the same timeout and force parameters as the close job request. When a datafeed that has a specified end date stops, it automatically closes its associated job. -{ref}/ml-close-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-close-job[Endpoint documentation] [source,ts] ---- client.ml.closeJob({ job_id }) @@ -8204,9 +8557,10 @@ client.ml.closeJob({ job_id }) [discrete] ==== delete_calendar Delete a calendar. -Removes all scheduled events from a calendar, then deletes it. -{ref}/ml-delete-calendar.html[Endpoint documentation] +Remove all scheduled events from a calendar, then delete it. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-calendar[Endpoint documentation] [source,ts] ---- client.ml.deleteCalendar({ calendar_id }) @@ -8222,7 +8576,7 @@ client.ml.deleteCalendar({ calendar_id }) ==== delete_calendar_event Delete events from a calendar. -{ref}/ml-delete-calendar-event.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-calendar-event[Endpoint documentation] [source,ts] ---- client.ml.deleteCalendarEvent({ calendar_id, event_id }) @@ -8240,7 +8594,7 @@ You can obtain this identifier by using the get calendar events API. ==== delete_calendar_job Delete anomaly jobs from a calendar. -{ref}/ml-delete-calendar-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-calendar-job[Endpoint documentation] [source,ts] ---- client.ml.deleteCalendarJob({ calendar_id, job_id }) @@ -8258,7 +8612,7 @@ list of jobs or groups. ==== delete_data_frame_analytics Delete a data frame analytics job. -{ref}/delete-dfanalytics.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-data-frame-analytics[Endpoint documentation] [source,ts] ---- client.ml.deleteDataFrameAnalytics({ id }) @@ -8276,7 +8630,7 @@ client.ml.deleteDataFrameAnalytics({ id }) ==== delete_datafeed Delete a datafeed. -{ref}/ml-delete-datafeed.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-datafeed[Endpoint documentation] [source,ts] ---- client.ml.deleteDatafeed({ datafeed_id }) @@ -8296,16 +8650,17 @@ stopping and deleting the datafeed. [discrete] ==== delete_expired_data Delete expired ML data. -Deletes all job results, model snapshots and forecast data that have exceeded + +Delete all job results, model snapshots and forecast data that have exceeded their retention days period. Machine learning state documents that are not associated with any job are also deleted. You can limit the request to a single or set of anomaly detection jobs by using a job identifier, a group name, a list of jobs, or a wildcard expression. You can delete expired data for all anomaly detection -jobs by using _all, by specifying * as the , or by omitting the -. +jobs by using `_all`, by specifying `*` as the ``, or by omitting the +``. -{ref}/ml-delete-expired-data.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-expired-data[Endpoint documentation] [source,ts] ---- client.ml.deleteExpiredData({ ... }) @@ -8324,10 +8679,11 @@ behavior is no throttling. [discrete] ==== delete_filter Delete a filter. + If an anomaly detection job references the filter, you cannot delete the filter. You must update or delete the job before you can delete the filter. -{ref}/ml-delete-filter.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-filter[Endpoint documentation] [source,ts] ---- client.ml.deleteFilter({ filter_id }) @@ -8342,12 +8698,13 @@ client.ml.deleteFilter({ filter_id }) [discrete] ==== delete_forecast Delete forecasts from a job. + By default, forecasts are retained for 14 days. You can specify a different retention period with the `expires_in` parameter in the forecast jobs API. The delete forecast API enables you to delete one or more forecasts before they expire. -{ref}/ml-delete-forecast.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-forecast[Endpoint documentation] [source,ts] ---- client.ml.deleteForecast({ job_id }) @@ -8372,6 +8729,7 @@ error. [discrete] ==== delete_job Delete an anomaly detection job. + All job configuration, model state and results are deleted. It is not currently possible to delete multiple jobs using wildcards or a comma separated list. If you delete a job that has a datafeed, the request @@ -8379,7 +8737,7 @@ first tries to delete the datafeed. This behavior is equivalent to calling the delete datafeed API with the same timeout and force parameters as the delete job request. -{ref}/ml-delete-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-job[Endpoint documentation] [source,ts] ---- client.ml.deleteJob({ job_id }) @@ -8401,11 +8759,12 @@ job deletion completes. [discrete] ==== delete_model_snapshot Delete a model snapshot. + You cannot delete the active model snapshot. To delete that snapshot, first revert to a different one. To identify the active model snapshot, refer to the `model_snapshot_id` in the results from the get jobs API. -{ref}/ml-delete-snapshot.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-model-snapshot[Endpoint documentation] [source,ts] ---- client.ml.deleteModelSnapshot({ job_id, snapshot_id }) @@ -8421,9 +8780,10 @@ client.ml.deleteModelSnapshot({ job_id, snapshot_id }) [discrete] ==== delete_trained_model Delete an unreferenced trained model. + The request deletes a trained inference model that is not referenced by an ingest pipeline. -{ref}/delete-trained-models.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-trained-model[Endpoint documentation] [source,ts] ---- client.ml.deleteTrainedModel({ model_id }) @@ -8440,11 +8800,12 @@ client.ml.deleteTrainedModel({ model_id }) [discrete] ==== delete_trained_model_alias Delete a trained model alias. + This API deletes an existing model alias that refers to a trained model. If the model alias is missing or refers to a model other than the one identified by the `model_id`, this API returns an error. -{ref}/delete-trained-models-aliases.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-trained-model-alias[Endpoint documentation] [source,ts] ---- client.ml.deleteTrainedModelAlias({ model_alias, model_id }) @@ -8460,11 +8821,12 @@ client.ml.deleteTrainedModelAlias({ model_alias, model_id }) [discrete] ==== estimate_model_memory Estimate job model memory usage. -Makes an estimation of the memory usage for an anomaly detection job model. -It is based on analysis configuration details for the job and cardinality + +Make an estimation of the memory usage for an anomaly detection job model. +The estimate is based on analysis configuration details for the job and cardinality estimates for the fields it references. -{ref}/ml-apis.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-estimate-model-memory[Endpoint documentation] [source,ts] ---- client.ml.estimateModelMemory({ ... }) @@ -8492,12 +8854,13 @@ omitted from the request if no detectors have a `by_field_name`, [discrete] ==== evaluate_data_frame Evaluate data frame analytics. + The API packages together commonly used evaluation metrics for various types of machine learning features. This has been designed for use on indexes created by data frame analytics. Evaluation requires both a ground truth field and an analytics result field to be present. -{ref}/evaluate-dfanalytics.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-evaluate-data-frame[Endpoint documentation] [source,ts] ---- client.ml.evaluateDataFrame({ evaluation, index }) @@ -8514,6 +8877,7 @@ client.ml.evaluateDataFrame({ evaluation, index }) [discrete] ==== explain_data_frame_analytics Explain data frame analytics config. + This API provides explanations for a data frame analytics config that either exists already or one that has not been created yet. The following explanations are provided: @@ -8521,7 +8885,7 @@ explanations are provided: * how much memory is estimated to be required. The estimate can be used when deciding the appropriate value for model_memory_limit setting later on. If you have object fields or fields that are excluded via source filtering, they are not included in the explanation. -{ref}/explain-dfanalytics.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-explain-data-frame-analytics[Endpoint documentation] [source,ts] ---- client.ml.explainDataFrameAnalytics({ ... }) @@ -8571,7 +8935,7 @@ to continue analyzing data. A close operation additionally prunes and persists the model state to disk and the job must be opened again before analyzing further data. -{ref}/ml-flush-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-flush-job[Endpoint documentation] [source,ts] ---- client.ml.flushJob({ job_id }) @@ -8597,7 +8961,7 @@ error occurs if you try to create a forecast for a job that has an `over_field_name` in its configuration. Forcasts predict future behavior based on historical data. -{ref}/ml-forecast.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-forecast[Endpoint documentation] [source,ts] ---- client.ml.forecast({ job_id }) @@ -8618,7 +8982,7 @@ create a forecast; otherwise, an error occurs. Get anomaly detection job results for buckets. The API presents a chronological view of the records, grouped by bucket. -{ref}/ml-get-bucket.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-buckets[Endpoint documentation] [source,ts] ---- client.ml.getBuckets({ job_id }) @@ -8646,7 +9010,7 @@ parameter, the API returns information about all buckets. ==== get_calendar_events Get info about events in calendars. -{ref}/ml-get-calendar-event.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-calendar-events[Endpoint documentation] [source,ts] ---- client.ml.getCalendarEvents({ calendar_id }) @@ -8667,7 +9031,7 @@ client.ml.getCalendarEvents({ calendar_id }) ==== get_calendars Get calendar configuration info. -{ref}/ml-get-calendar.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-calendars[Endpoint documentation] [source,ts] ---- client.ml.getCalendars({ ... }) @@ -8686,7 +9050,7 @@ client.ml.getCalendars({ ... }) ==== get_categories Get anomaly detection job results for categories. -{ref}/ml-get-category.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-categories[Endpoint documentation] [source,ts] ---- client.ml.getCategories({ job_id }) @@ -8715,7 +9079,7 @@ You can get information for multiple data frame analytics jobs in a single API request by using a list of data frame analytics jobs or a wildcard expression. -{ref}/get-dfanalytics.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-data-frame-analytics[Endpoint documentation] [source,ts] ---- client.ml.getDataFrameAnalytics({ ... }) @@ -8749,7 +9113,7 @@ be retrieved and then added to another cluster. ==== get_data_frame_analytics_stats Get data frame analytics jobs usage info. -{ref}/get-dfanalytics-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-data-frame-analytics-stats[Endpoint documentation] [source,ts] ---- client.ml.getDataFrameAnalyticsStats({ ... }) @@ -8787,7 +9151,7 @@ get statistics for all datafeeds by using `_all`, by specifying `*` as the only information you receive is the `datafeed_id` and the `state`. This API returns a maximum of 10,000 datafeeds. -{ref}/ml-get-datafeed-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-datafeed-stats[Endpoint documentation] [source,ts] ---- client.ml.getDatafeedStats({ ... }) @@ -8820,7 +9184,7 @@ get information for all datafeeds by using `_all`, by specifying `*` as the ``, or by omitting the ``. This API returns a maximum of 10,000 datafeeds. -{ref}/ml-get-datafeed.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-datafeeds[Endpoint documentation] [source,ts] ---- client.ml.getDatafeeds({ ... }) @@ -8852,7 +9216,7 @@ be retrieved and then added to another cluster. Get filters. You can get a single filter or all filters. -{ref}/ml-get-filter.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-filters[Endpoint documentation] [source,ts] ---- client.ml.getFilters({ ... }) @@ -8873,7 +9237,7 @@ Influencers are the entities that have contributed to, or are to blame for, the anomalies. Influencer results are available only if an `influencer_field_name` is specified in the job configuration. -{ref}/ml-get-influencer.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-influencers[Endpoint documentation] [source,ts] ---- client.ml.getInfluencers({ job_id }) @@ -8905,7 +9269,7 @@ means it is unset and results are not limited to specific timestamps. ==== get_job_stats Get anomaly detection jobs usage info. -{ref}/ml-get-job-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-job-stats[Endpoint documentation] [source,ts] ---- client.ml.getJobStats({ ... }) @@ -8938,7 +9302,7 @@ request by using a group name, a list of jobs, or a wildcard expression. You can get information for all anomaly detection jobs by using `_all`, by specifying `*` as the ``, or by omitting the ``. -{ref}/ml-get-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-jobs[Endpoint documentation] [source,ts] ---- client.ml.getJobs({ ... }) @@ -8971,7 +9335,7 @@ Get machine learning memory usage info. Get information about how machine learning jobs and trained models are using memory, on each node, both within the JVM heap, and natively, outside of the JVM. -{ref}/get-ml-memory.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-memory-stats[Endpoint documentation] [source,ts] ---- client.ml.getMemoryStats({ ... }) @@ -8992,7 +9356,7 @@ fails and returns an error. ==== get_model_snapshot_upgrade_stats Get anomaly detection job model snapshot upgrade usage info. -{ref}/ml-get-job-model-snapshot-upgrade-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-model-snapshot-upgrade-stats[Endpoint documentation] [source,ts] ---- client.ml.getModelSnapshotUpgradeStats({ job_id, snapshot_id }) @@ -9020,7 +9384,7 @@ no matches or only partial matches. ==== get_model_snapshots Get model snapshots info. -{ref}/ml-get-snapshot.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-model-snapshots[Endpoint documentation] [source,ts] ---- client.ml.getModelSnapshots({ job_id }) @@ -9064,7 +9428,7 @@ greater than its default), the `overall_score` is the maximum `overall_score` of the overall buckets that have a span equal to the jobs' largest bucket span. -{ref}/ml-get-overall-buckets.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-overall-buckets[Endpoint documentation] [source,ts] ---- client.ml.getOverallBuckets({ job_id }) @@ -9102,7 +9466,7 @@ The number of record results depends on the number of anomalies found in each bucket, which relates to the number of time series being modeled and the number of detectors. -{ref}/ml-get-record.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-records[Endpoint documentation] [source,ts] ---- client.ml.getRecords({ job_id }) @@ -9127,7 +9491,7 @@ client.ml.getRecords({ job_id }) ==== get_trained_models Get trained model configuration info. -{ref}/get-trained-models.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-trained-models[Endpoint documentation] [source,ts] ---- client.ml.getTrainedModels({ ... }) @@ -9170,7 +9534,7 @@ Get trained models usage info. You can get usage information for multiple trained models in a single API request by using a list of model IDs or a wildcard expression. -{ref}/get-trained-models-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-trained-models-stats[Endpoint documentation] [source,ts] ---- client.ml.getTrainedModelsStats({ ... }) @@ -9197,7 +9561,7 @@ subset of results when there are partial matches. ==== infer_trained_model Evaluate a trained model. -{ref}/infer-trained-model.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-infer-trained-model[Endpoint documentation] [source,ts] ---- client.ml.inferTrainedModel({ model_id, docs }) @@ -9225,7 +9589,7 @@ used to find out what those defaults are. It also provides information about the maximum size of machine learning jobs that could run in the current cluster configuration. -{ref}/get-ml-info.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-info[Endpoint documentation] [source,ts] ---- client.ml.info() @@ -9235,6 +9599,7 @@ client.ml.info() [discrete] ==== open_job Open anomaly detection jobs. + An anomaly detection job must be opened to be ready to receive and analyze data. It can be opened and closed multiple times throughout its lifecycle. When you open a new job, it starts with an empty model. @@ -9242,7 +9607,7 @@ When you open an existing job, the most recent model state is automatically loaded. The job is ready to resume its analysis from where it left off, once new data is received. -{ref}/ml-open-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-open-job[Endpoint documentation] [source,ts] ---- client.ml.openJob({ job_id }) @@ -9259,7 +9624,7 @@ client.ml.openJob({ job_id }) ==== post_calendar_events Add scheduled events to the calendar. -{ref}/ml-post-calendar-event.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-post-calendar-events[Endpoint documentation] [source,ts] ---- client.ml.postCalendarEvents({ calendar_id, events }) @@ -9279,7 +9644,7 @@ Send data to an anomaly detection job for analysis. IMPORTANT: For each job, data can be accepted from only a single connection at a time. It is not currently possible to post data to multiple jobs using wildcards or a list. -{ref}/ml-post-data.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-post-data[Endpoint documentation] [source,ts] ---- client.ml.postData({ job_id }) @@ -9297,9 +9662,9 @@ client.ml.postData({ job_id }) [discrete] ==== preview_data_frame_analytics Preview features used by data frame analytics. -Previews the extracted features used by a data frame analytics config. +Preview the extracted features used by a data frame analytics config. -{ref}/preview-dfanalytics.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-preview-data-frame-analytics[Endpoint documentation] [source,ts] ---- client.ml.previewDataFrameAnalytics({ ... }) @@ -9326,7 +9691,7 @@ called the API. However, when the datafeed starts it uses the roles of the last datafeed. To get a preview that accurately reflects the behavior of the datafeed, use the appropriate credentials. You can also use secondary authorization headers to supply the credentials. -{ref}/ml-preview-datafeed.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-preview-datafeed[Endpoint documentation] [source,ts] ---- client.ml.previewDatafeed({ ... }) @@ -9352,7 +9717,7 @@ used. You cannot specify a `job_config` object unless you also supply a `datafee ==== put_calendar Create a calendar. -{ref}/ml-put-calendar.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-calendar[Endpoint documentation] [source,ts] ---- client.ml.putCalendar({ calendar_id }) @@ -9370,7 +9735,7 @@ client.ml.putCalendar({ calendar_id }) ==== put_calendar_job Add anomaly detection job to calendar. -{ref}/ml-put-calendar-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-calendar-job[Endpoint documentation] [source,ts] ---- client.ml.putCalendarJob({ calendar_id, job_id }) @@ -9394,7 +9759,7 @@ If the destination index does not exist, it is created automatically when you st If you supply only a subset of the regression or classification parameters, hyperparameter optimization occurs. It determines a value for each of the undefined parameters. -{ref}/put-dfanalytics.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-data-frame-analytics[Endpoint documentation] [source,ts] ---- client.ml.putDataFrameAnalytics({ id, analysis, dest, source }) @@ -9477,7 +9842,7 @@ those credentials are used instead. You must use Kibana, this API, or the create anomaly detection jobs API to create a datafeed. Do not add a datafeed directly to the `.ml-config` index. Do not give users `write` privileges on the `.ml-config` index. -{ref}/ml-put-datafeed.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-datafeed[Endpoint documentation] [source,ts] ---- client.ml.putDatafeed({ datafeed_id }) @@ -9540,7 +9905,7 @@ Create a filter. A filter contains a list of strings. It can be used by one or more anomaly detection jobs. Specifically, filters are referenced in the `custom_rules` property of detector configuration objects. -{ref}/ml-put-filter.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-filter[Endpoint documentation] [source,ts] ---- client.ml.putFilter({ filter_id }) @@ -9558,10 +9923,11 @@ Up to 10000 items are allowed in each filter. [discrete] ==== put_job Create an anomaly detection job. + If you include a `datafeed_config`, you must have read index privileges on the source index. If you include a `datafeed_config` but do not provide a query, the datafeed uses `{"match_all": {"boost": 1}}`. -{ref}/ml-put-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-job[Endpoint documentation] [source,ts] ---- client.ml.putJob({ job_id, analysis_config, data_description }) @@ -9605,7 +9971,7 @@ whether wildcard expressions match hidden data streams. Supports a list of value Create a trained model. Enable you to supply a trained model that is not created by data frame analytics. -{ref}/put-trained-models.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-trained-model[Endpoint documentation] [source,ts] ---- client.ml.putTrainedModel({ model_id }) @@ -9667,7 +10033,7 @@ If you use this API to update an alias and there are very few input fields in common between the old and new trained models for the model alias, the API returns a warning. -{ref}/put-trained-models-aliases.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-trained-model-alias[Endpoint documentation] [source,ts] ---- client.ml.putTrainedModelAlias({ model_alias, model_id }) @@ -9687,7 +10053,7 @@ already assigned and this parameter is false, the API returns an error. ==== put_trained_model_definition_part Create part of a trained model definition. -{ref}/put-trained-model-definition-part.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-trained-model-definition-part[Endpoint documentation] [source,ts] ---- client.ml.putTrainedModelDefinitionPart({ model_id, part, definition, total_definition_length, total_parts }) @@ -9710,7 +10076,7 @@ Create a trained model vocabulary. This API is supported only for natural language processing (NLP) models. The vocabulary is stored in the index as described in `inference_config.*.vocabulary` of the trained model definition. -{ref}/put-trained-model-vocabulary.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-trained-model-vocabulary[Endpoint documentation] [source,ts] ---- client.ml.putTrainedModelVocabulary({ model_id, vocabulary }) @@ -9733,7 +10099,7 @@ it had just been created. It is not currently possible to reset multiple jobs using wildcards or a comma separated list. -{ref}/ml-reset-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-reset-job[Endpoint documentation] [source,ts] ---- client.ml.resetJob({ job_id }) @@ -9761,7 +10127,7 @@ one-off, then it might be appropriate to reset the model state to a time before this event. For example, you might consider reverting to a saved snapshot after Black Friday or a critical system failure. -{ref}/ml-revert-snapshot.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-revert-model-snapshot[Endpoint documentation] [source,ts] ---- client.ml.revertModelSnapshot({ job_id, snapshot_id }) @@ -9793,7 +10159,7 @@ indices, though stopping jobs is not a requirement in that case. You can see the current value for the upgrade_mode setting by using the get machine learning info API. -{ref}/ml-set-upgrade-mode.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-set-upgrade-mode[Endpoint documentation] [source,ts] ---- client.ml.setUpgradeMode({ ... }) @@ -9823,7 +10189,7 @@ If there are any mapping conflicts, the job fails to start. If the destination index exists, it is used as is. You can therefore set up the destination index in advance with custom settings and mappings. -{ref}/start-dfanalytics.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-start-data-frame-analytics[Endpoint documentation] [source,ts] ---- client.ml.startDataFrameAnalytics({ id }) @@ -9855,7 +10221,7 @@ When Elasticsearch security features are enabled, your datafeed remembers which update it had at the time of creation or update and runs the query using those same roles. If you provided secondary authorization headers when you created or updated the datafeed, those credentials are used instead. -{ref}/ml-start-datafeed.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-start-datafeed[Endpoint documentation] [source,ts] ---- client.ml.startDatafeed({ datafeed_id }) @@ -9877,7 +10243,7 @@ characters. Start a trained model deployment. It allocates the model to every machine learning node. -{ref}/start-trained-model-deployment.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-start-trained-model-deployment[Endpoint documentation] [source,ts] ---- client.ml.startTrainedModelDeployment({ model_id }) @@ -9915,7 +10281,7 @@ Stop data frame analytics jobs. A data frame analytics job can be started and stopped multiple times throughout its lifecycle. -{ref}/stop-dfanalytics.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-stop-data-frame-analytics[Endpoint documentation] [source,ts] ---- client.ml.stopDataFrameAnalytics({ id }) @@ -9949,7 +10315,7 @@ Stop datafeeds. A datafeed that is stopped ceases to retrieve data from Elasticsearch. A datafeed can be started and stopped multiple times throughout its lifecycle. -{ref}/ml-stop-datafeed.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-stop-datafeed[Endpoint documentation] [source,ts] ---- client.ml.stopDatafeed({ datafeed_id }) @@ -9970,7 +10336,7 @@ the identifier. ==== stop_trained_model_deployment Stop a trained model deployment. -{ref}/stop-trained-model-deployment.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-stop-trained-model-deployment[Endpoint documentation] [source,ts] ---- client.ml.stopTrainedModelDeployment({ model_id }) @@ -9992,7 +10358,7 @@ restart the model deployment. ==== update_data_frame_analytics Update a data frame analytics job. -{ref}/update-dfanalytics.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-update-data-frame-analytics[Endpoint documentation] [source,ts] ---- client.ml.updateDataFrameAnalytics({ id }) @@ -10026,7 +10392,7 @@ When Elasticsearch security features are enabled, your datafeed remembers which the time of the update and runs the query using those same roles. If you provide secondary authorization headers, those credentials are used instead. -{ref}/ml-update-datafeed.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-update-datafeed[Endpoint documentation] [source,ts] ---- client.ml.updateDatafeed({ datafeed_id }) @@ -10096,7 +10462,7 @@ whether wildcard expressions match hidden data streams. Supports a list of value Update a filter. Updates the description of a filter, adds items, or removes items from the list. -{ref}/ml-update-filter.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-update-filter[Endpoint documentation] [source,ts] ---- client.ml.updateFilter({ filter_id }) @@ -10116,7 +10482,7 @@ client.ml.updateFilter({ filter_id }) Update an anomaly detection job. Updates certain properties of an anomaly detection job. -{ref}/ml-update-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-update-job[Endpoint documentation] [source,ts] ---- client.ml.updateJob({ job_id }) @@ -10182,7 +10548,7 @@ value is null, which means all results are retained. Update a snapshot. Updates certain properties of a snapshot. -{ref}/ml-update-snapshot.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-update-model-snapshot[Endpoint documentation] [source,ts] ---- client.ml.updateModelSnapshot({ job_id, snapshot_id }) @@ -10203,7 +10569,7 @@ snapshot will be deleted when the job is deleted. ==== update_trained_model_deployment Update a trained model deployment. -{ref}/update-trained-model-deployment.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-update-trained-model-deployment[Endpoint documentation] [source,ts] ---- client.ml.updateTrainedModelDeployment({ model_id }) @@ -10224,7 +10590,7 @@ it will automatically be changed to a value less than the number of hardware thr [discrete] ==== upgrade_job_snapshot Upgrade a snapshot. -Upgrades an anomaly detection model snapshot to the latest major version. +Upgrade an anomaly detection model snapshot to the latest major version. Over time, older snapshot formats are deprecated and removed. Anomaly detection jobs support only snapshots that are from the current or previous major version. @@ -10234,7 +10600,7 @@ Only one snapshot per anomaly detection job can be upgraded at a time and the upgraded snapshot cannot be the current snapshot of the anomaly detection job. -{ref}/ml-upgrade-job-model-snapshot.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-upgrade-job-snapshot[Endpoint documentation] [source,ts] ---- client.ml.upgradeJobSnapshot({ job_id, snapshot_id }) @@ -10257,7 +10623,7 @@ Otherwise, it responds as soon as the upgrade task is assigned to a node. Clear the archived repositories metering. Clear the archived repositories metering information in the cluster. -{ref}/clear-repositories-metering-archive-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-nodes-clear-repositories-metering-archive[Endpoint documentation] [source,ts] ---- client.nodes.clearRepositoriesMeteringArchive({ node_id, max_archive_version }) @@ -10277,7 +10643,7 @@ Get repositories metering information for a cluster. This API exposes monotonically non-decreasing counters and it is expected that clients would durably store the information needed to compute aggregations over a period of time. Additionally, the information exposed by this API is volatile, meaning that it will not be present after node restarts. -{ref}/get-repositories-metering-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-nodes-get-repositories-metering-info[Endpoint documentation] [source,ts] ---- client.nodes.getRepositoriesMeteringInfo({ node_id }) @@ -10296,7 +10662,7 @@ Get the hot threads for nodes. Get a breakdown of the hot threads on each selected node in the cluster. The output is plain text with a breakdown of the top hot threads for each node. -{ref}/cluster-nodes-hot-threads.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-nodes-hot-threads[Endpoint documentation] [source,ts] ---- client.nodes.hotThreads({ ... }) @@ -10320,9 +10686,10 @@ before the timeout expires, the request fails and returns an error. [discrete] ==== info Get node information. + By default, the API returns all attributes and core settings for cluster nodes. -{ref}/cluster-nodes-info.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-nodes-info[Endpoint documentation] [source,ts] ---- client.nodes.info({ ... }) @@ -10349,7 +10716,7 @@ When the Elasticsearch keystore is password protected and not simply obfuscated, Reloading the settings for the whole cluster assumes that the keystores for all nodes are protected with the same password; this method is allowed only when inter-node communications are encrypted. Alternatively, you can reload the secure settings on each node by locally accessing the API and passing the node-specific Elasticsearch keystore password. -{ref}/secure-settings.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-nodes-reload-secure-settings[Endpoint documentation] [source,ts] ---- client.nodes.reloadSecureSettings({ ... }) @@ -10370,7 +10737,7 @@ Get node statistics. Get statistics for nodes in a cluster. By default, all stats are returned. You can limit the returned information by using metrics. -{ref}/cluster-nodes-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-nodes-stats[Endpoint documentation] [source,ts] ---- client.nodes.stats({ ... }) @@ -10397,7 +10764,7 @@ client.nodes.stats({ ... }) ==== usage Get feature usage information. -{ref}/cluster-nodes-usage.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-nodes-usage[Endpoint documentation] [source,ts] ---- client.nodes.usage({ ... }) @@ -10421,7 +10788,7 @@ Delete a query rule. Delete a query rule within a query ruleset. This is a destructive action that is only recoverable by re-adding the same rule with the create or update query rule API. -{ref}/delete-query-rule.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-delete-rule[Endpoint documentation] [source,ts] ---- client.queryRules.deleteRule({ ruleset_id, rule_id }) @@ -10440,7 +10807,7 @@ Delete a query ruleset. Remove a query ruleset and its associated data. This is a destructive action that is not recoverable. -{ref}/delete-query-ruleset.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-delete-ruleset[Endpoint documentation] [source,ts] ---- client.queryRules.deleteRuleset({ ruleset_id }) @@ -10457,7 +10824,7 @@ client.queryRules.deleteRuleset({ ruleset_id }) Get a query rule. Get details about a query rule within a query ruleset. -{ref}/get-query-rule.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-get-rule[Endpoint documentation] [source,ts] ---- client.queryRules.getRule({ ruleset_id, rule_id }) @@ -10475,7 +10842,7 @@ client.queryRules.getRule({ ruleset_id, rule_id }) Get a query ruleset. Get details about a query ruleset. -{ref}/get-query-ruleset.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-get-ruleset[Endpoint documentation] [source,ts] ---- client.queryRules.getRuleset({ ruleset_id }) @@ -10492,7 +10859,7 @@ client.queryRules.getRuleset({ ruleset_id }) Get all query rulesets. Get summarized information about the query rulesets. -{ref}/list-query-rulesets.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-list-rulesets[Endpoint documentation] [source,ts] ---- client.queryRules.listRulesets({ ... }) @@ -10515,7 +10882,7 @@ It is advised to use one or the other in query rulesets, to avoid errors. Additionally, pinned queries have a maximum limit of 100 pinned hits. If multiple matching rules pin more than 100 documents, only the first 100 documents are pinned in the order they are specified in the ruleset. -{ref}/put-query-rule.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-put-rule[Endpoint documentation] [source,ts] ---- client.queryRules.putRule({ ruleset_id, rule_id, type, criteria, actions }) @@ -10545,7 +10912,7 @@ It is advised to use one or the other in query rulesets, to avoid errors. Additionally, pinned queries have a maximum limit of 100 pinned hits. If multiple matching rules pin more than 100 documents, only the first 100 documents are pinned in the order they are specified in the ruleset. -{ref}/put-query-ruleset.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-put-ruleset[Endpoint documentation] [source,ts] ---- client.queryRules.putRuleset({ ruleset_id, rules }) @@ -10563,7 +10930,7 @@ client.queryRules.putRuleset({ ruleset_id, rules }) Test a query ruleset. Evaluate match criteria against a query ruleset to identify the rules that would match that criteria. -{ref}/test-query-ruleset.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-test[Endpoint documentation] [source,ts] ---- client.queryRules.test({ ruleset_id, match_criteria }) @@ -10606,7 +10973,7 @@ POST my_rollup_index/_delete_by_query } ---- -{ref}/rollup-delete-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-delete-job[Endpoint documentation] [source,ts] ---- client.rollup.deleteJob({ id }) @@ -10627,7 +10994,7 @@ NOTE: This API returns only active (both `STARTED` and `STOPPED`) jobs. If a job was created, ran for a while, then was deleted, the API does not return any details about it. For details about a historical rollup job, the rollup capabilities API may be more useful. -{ref}/rollup-get-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-get-jobs[Endpoint documentation] [source,ts] ---- client.rollup.getJobs({ ... }) @@ -10652,7 +11019,7 @@ This API enables you to inspect an index and determine: . Does this index have associated rollup data somewhere in the cluster? . If yes to the first question, what fields were rolled up, what aggregations can be performed, and where does the data live? -{ref}/rollup-get-rollup-caps.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-get-rollup-caps[Endpoint documentation] [source,ts] ---- client.rollup.getRollupCaps({ ... }) @@ -10674,7 +11041,7 @@ A single rollup index may store the data for multiple rollup jobs and may have a * What jobs are stored in an index (or indices specified via a pattern)? * What target indices were rolled up, what fields were used in those rollups, and what aggregations can be performed on each job? -{ref}/rollup-get-rollup-index-caps.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-get-rollup-index-caps[Endpoint documentation] [source,ts] ---- client.rollup.getRollupIndexCaps({ index }) @@ -10699,7 +11066,7 @@ There are three main sections to the job configuration: the logistical details a Jobs are created in a `STOPPED` state. You can start them with the start rollup jobs API. -{ref}/rollup-put-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-put-job[Endpoint documentation] [source,ts] ---- client.rollup.putJob({ id, cron, groups, index_pattern, page_size, rollup_index }) @@ -10775,7 +11142,7 @@ The rollup search endpoint does two things when the search runs: When the two responses are received, the endpoint rewrites the rollup response and merges the two together. During the merging process, if there is any overlap in buckets between the two responses, the buckets from the non-rollup index are used. -{ref}/rollup-search.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-rollup-search[Endpoint documentation] [source,ts] ---- client.rollup.rollupSearch({ index }) @@ -10804,7 +11171,7 @@ Start rollup jobs. If you try to start a job that does not exist, an exception occurs. If you try to start a job that is already started, nothing happens. -{ref}/rollup-start-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-start-job[Endpoint documentation] [source,ts] ---- client.rollup.startJob({ id }) @@ -10831,7 +11198,7 @@ POST _rollup/job/sensor/_stop?wait_for_completion=true&timeout=10s The parameter blocks the API call from returning until either the job has moved to STOPPED or the specified time has elapsed. If the specified time elapses without the job moving to STOPPED, a timeout exception occurs. -{ref}/rollup-stop-job.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-stop-job[Endpoint documentation] [source,ts] ---- client.rollup.stopJob({ id }) @@ -10854,9 +11221,10 @@ If set to `false`, the API returns immediately and the indexer is stopped asynch [discrete] ==== delete Delete a search application. + Remove a search application and its associated alias. Indices attached to the search application are not removed. -{ref}/delete-search-application.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-delete[Endpoint documentation] [source,ts] ---- client.searchApplication.delete({ name }) @@ -10866,14 +11234,14 @@ client.searchApplication.delete({ name }) ==== Arguments * *Request (object):* -** *`name` (string)*: The name of the search application to delete +** *`name` (string)*: The name of the search application to delete. [discrete] ==== delete_behavioral_analytics Delete a behavioral analytics collection. The associated data stream is also deleted. -{ref}/delete-analytics-collection.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-delete-behavioral-analytics[Endpoint documentation] [source,ts] ---- client.searchApplication.deleteBehavioralAnalytics({ name }) @@ -10889,7 +11257,7 @@ client.searchApplication.deleteBehavioralAnalytics({ name }) ==== get Get search application details. -{ref}/get-search-application.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-get[Endpoint documentation] [source,ts] ---- client.searchApplication.get({ name }) @@ -10905,7 +11273,7 @@ client.searchApplication.get({ name }) ==== get_behavioral_analytics Get behavioral analytics collections. -{ref}/list-analytics-collection.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-get-behavioral-analytics[Endpoint documentation] [source,ts] ---- client.searchApplication.getBehavioralAnalytics({ ... }) @@ -10922,7 +11290,7 @@ client.searchApplication.getBehavioralAnalytics({ ... }) Get search applications. Get information about search applications. -{ref}/list-search-applications.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-get-behavioral-analytics[Endpoint documentation] [source,ts] ---- client.searchApplication.list({ ... }) @@ -10940,7 +11308,7 @@ client.searchApplication.list({ ... }) ==== post_behavioral_analytics_event Create a behavioral analytics collection event. -{ref}/post-analytics-collection-event.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-post-behavioral-analytics-event[Endpoint documentation] [source,ts] ---- client.searchApplication.postBehavioralAnalyticsEvent({ collection_name, event_type }) @@ -10959,7 +11327,7 @@ client.searchApplication.postBehavioralAnalyticsEvent({ collection_name, event_t ==== put Create or update a search application. -{ref}/put-search-application.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-put[Endpoint documentation] [source,ts] ---- client.searchApplication.put({ name }) @@ -10977,7 +11345,7 @@ client.searchApplication.put({ name }) ==== put_behavioral_analytics Create a behavioral analytics collection. -{ref}/put-analytics-collection.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-put-behavioral-analytics[Endpoint documentation] [source,ts] ---- client.searchApplication.putBehavioralAnalytics({ name }) @@ -10998,7 +11366,7 @@ The API returns the specific Elasticsearch query that would be generated and run You must have `read` privileges on the backing alias of the search application. -{ref}/search-application-render-query.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-render-query[Endpoint documentation] [source,ts] ---- client.searchApplication.renderQuery({ name }) @@ -11017,7 +11385,7 @@ Run a search application search. Generate and run an Elasticsearch query that uses the specified query parameteter and the search template associated with the search application or default template. Unspecified template parameters are assigned their default values if applicable. -{ref}/search-application-search.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-search[Endpoint documentation] [source,ts] ---- client.searchApplication.search({ name }) @@ -11038,7 +11406,7 @@ client.searchApplication.search({ name }) Get cache statistics. Get statistics about the shared cache for partially mounted indices. -{ref}/searchable-snapshots-api-cache-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-searchable-snapshots-cache-stats[Endpoint documentation] [source,ts] ---- client.searchableSnapshots.cacheStats({ ... }) @@ -11056,7 +11424,7 @@ client.searchableSnapshots.cacheStats({ ... }) Clear the cache. Clear indices and data streams from the shared cache for partially mounted indices. -{ref}/searchable-snapshots-api-clear-cache.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-searchable-snapshots-clear-cache[Endpoint documentation] [source,ts] ---- client.searchableSnapshots.clearCache({ ... }) @@ -11079,7 +11447,7 @@ Mount a snapshot as a searchable snapshot index. Do not use this API for snapshots managed by index lifecycle management (ILM). Manually mounting ILM-managed snapshots can interfere with ILM processes. -{ref}/searchable-snapshots-api-mount-snapshot.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-searchable-snapshots-mount[Endpoint documentation] [source,ts] ---- client.searchableSnapshots.mount({ repository, snapshot, index }) @@ -11106,7 +11474,7 @@ To indicate that the request should never timeout, set it to `-1`. ==== stats Get searchable snapshot statistics. -{ref}/searchable-snapshots-api-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-searchable-snapshots-stats[Endpoint documentation] [source,ts] ---- client.searchableSnapshots.stats({ ... }) @@ -11138,7 +11506,7 @@ For example, in the JWT `access_token` case, the profile user's `username` is ex When updating a profile document, the API enables the document if it was disabled. Any updates do not change existing content for either the `labels` or `data` fields. -{ref}/security-api-activate-user-profile.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-activate-user-profile[Endpoint documentation] [source,ts] ---- client.security.activateUserProfile({ grant_type }) @@ -11169,7 +11537,7 @@ Include the user information in a [basic auth header](https://en.wikipedia.org/w A successful call returns a JSON structure that shows user information such as their username, the roles that are assigned to the user, any assigned metadata, and information about the realms that authenticated and authorized the user. If the user cannot be authenticated, this API returns a 401 status code. -{ref}/security-api-authenticate.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-authenticate[Endpoint documentation] [source,ts] ---- client.security.authenticate() @@ -11183,7 +11551,7 @@ Bulk delete roles. The role management APIs are generally the preferred way to manage roles, rather than using file-based role management. The bulk delete roles API cannot delete roles that are defined in roles files. -{ref}/security-api-bulk-delete-role.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-bulk-delete-role[Endpoint documentation] [source,ts] ---- client.security.bulkDeleteRole({ names }) @@ -11203,7 +11571,7 @@ Bulk create or update roles. The role management APIs are generally the preferred way to manage roles, rather than using file-based role management. The bulk create or update roles API cannot update roles that are defined in roles files. -{ref}/security-api-bulk-put-role.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-bulk-put-role[Endpoint documentation] [source,ts] ---- client.security.bulkPutRole({ roles }) @@ -11235,7 +11603,7 @@ IMPORTANT: If you don't specify `role_descriptors` in the request, a call to thi A successful request returns a JSON structure that contains the IDs of all updated API keys, the IDs of API keys that already had the requested changes and did not require an update, and error details for any failed update. -{ref}/security-api-bulk-update-api-keys.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-bulk-update-api-keys[Endpoint documentation] [source,ts] ---- client.security.bulkUpdateApiKeys({ ids }) @@ -11266,7 +11634,7 @@ Change passwords. Change the passwords of users in the native realm and built-in users. -{ref}/security-api-change-password.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-change-password[Endpoint documentation] [source,ts] ---- client.security.changePassword({ ... }) @@ -11292,7 +11660,7 @@ Clear the API key cache. Evict a subset of all entries from the API key cache. The cache is also automatically cleared on state changes of the security index. -{ref}/security-api-clear-api-key-cache.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-clear-api-key-cache[Endpoint documentation] [source,ts] ---- client.security.clearApiKeyCache({ ids }) @@ -11313,7 +11681,7 @@ Clear the privileges cache. Evict privileges from the native application privilege cache. The cache is also automatically cleared for applications that have their privileges updated. -{ref}/security-api-clear-privilege-cache.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-clear-cached-privileges[Endpoint documentation] [source,ts] ---- client.security.clearCachedPrivileges({ application }) @@ -11338,7 +11706,7 @@ User credentials are cached in memory on each node to avoid connecting to a remo There are realm settings that you can use to configure the user cache. For more information, refer to the documentation about controlling the user cache. -{ref}/security-api-clear-cache.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-clear-cached-realms[Endpoint documentation] [source,ts] ---- client.security.clearCachedRealms({ realms }) @@ -11360,7 +11728,7 @@ Clear the roles cache. Evict roles from the native role cache. -{ref}/security-api-clear-role-cache.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-clear-cached-roles[Endpoint documentation] [source,ts] ---- client.security.clearCachedRoles({ name }) @@ -11385,7 +11753,7 @@ This API clears matching entries from both caches. The cache for service account tokens backed by the `.security` index is cleared automatically on state changes of the security index. The cache for tokens backed by the `service_tokens` file is cleared automatically on file changes. -{ref}/security-api-clear-service-token-caches.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-clear-cached-service-tokens[Endpoint documentation] [source,ts] ---- client.security.clearCachedServiceTokens({ namespace, service, name }) @@ -11418,7 +11786,7 @@ NOTE: By default, API keys never expire. You can specify expiration information The API keys are created by the Elasticsearch API key service, which is automatically enabled. To configure or turn off the API key service, refer to API key service setting documentation. -{ref}/security-api-create-api-key.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-create-api-key[Endpoint documentation] [source,ts] ---- client.security.createApiKey({ ... }) @@ -11463,7 +11831,7 @@ By default, API keys never expire. You can specify expiration information when y Cross-cluster API keys can only be updated with the update cross-cluster API key API. Attempting to update them with the update REST API key API or the bulk update REST API keys API will result in an error. -{ref}/security-api-create-cross-cluster-api-key.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-create-cross-cluster-api-key[Endpoint documentation] [source,ts] ---- client.security.createCrossClusterApiKey({ access, name }) @@ -11495,7 +11863,7 @@ Create a service accounts token for access without requiring basic authenticatio NOTE: Service account tokens never expire. You must actively delete them if they are no longer needed. -{ref}/security-api-create-service-token.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-create-service-token[Endpoint documentation] [source,ts] ---- client.security.createServiceToken({ namespace, service }) @@ -11531,7 +11899,7 @@ IMPORTANT: The association between the subject public key in the target certific This is part of the TLS authentication process and it is delegated to the proxy that calls this API. The proxy is trusted to have performed the TLS authentication and this API translates that authentication into an Elasticsearch access token. -{ref}/security-api-delegate-pki-authentication.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-delegate-pki[Endpoint documentation] [source,ts] ---- client.security.delegatePki({ x509_certificate_chain }) @@ -11556,7 +11924,7 @@ To use this API, you must have one of the following privileges: * The `manage_security` cluster privilege (or a greater privilege such as `all`). * The "Manage Application Privileges" global privilege for the application being referenced in the request. -{ref}/security-api-delete-privilege.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-delete-privileges[Endpoint documentation] [source,ts] ---- client.security.deletePrivileges({ application, name }) @@ -11579,7 +11947,7 @@ Delete roles in the native realm. The role management APIs are generally the preferred way to manage roles, rather than using file-based role management. The delete roles API cannot remove roles that are defined in roles files. -{ref}/security-api-delete-role.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-delete-role[Endpoint documentation] [source,ts] ---- client.security.deleteRole({ name }) @@ -11600,7 +11968,7 @@ Role mappings define which roles are assigned to each user. The role mapping APIs are generally the preferred way to manage role mappings rather than using role mapping files. The delete role mappings API cannot remove role mappings that are defined in role mapping files. -{ref}/security-api-delete-role-mapping.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-delete-role-mapping[Endpoint documentation] [source,ts] ---- client.security.deleteRoleMapping({ name }) @@ -11620,7 +11988,7 @@ Delete service account tokens. Delete service account tokens for a service in a specified namespace. -{ref}/security-api-delete-service-token.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-delete-service-token[Endpoint documentation] [source,ts] ---- client.security.deleteServiceToken({ namespace, service, name }) @@ -11641,7 +12009,7 @@ Delete users. Delete users from the native realm. -{ref}/security-api-delete-user.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-delete-user[Endpoint documentation] [source,ts] ---- client.security.deleteUser({ username }) @@ -11662,7 +12030,7 @@ Disable users in the native realm. By default, when you create users, they are enabled. You can use this API to revoke a user's access to Elasticsearch. -{ref}/security-api-disable-user.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-disable-user[Endpoint documentation] [source,ts] ---- client.security.disableUser({ username }) @@ -11688,7 +12056,7 @@ Elastic reserves the right to change or remove this feature in future releases w When you activate a user profile, its automatically enabled and visible in user profile searches. You can use the disable user profile API to disable a user profile so it’s not visible in these searches. To re-enable a disabled user profile, use the enable user profile API . -{ref}/security-api-disable-user-profile.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-disable-user-profile[Endpoint documentation] [source,ts] ---- client.security.disableUserProfile({ uid }) @@ -11710,7 +12078,7 @@ Enable users. Enable users in the native realm. By default, when you create users, they are enabled. -{ref}/security-api-enable-user.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-enable-user[Endpoint documentation] [source,ts] ---- client.security.enableUser({ username }) @@ -11736,7 +12104,7 @@ Elastic reserves the right to change or remove this feature in future releases w When you activate a user profile, it's automatically enabled and visible in user profile searches. If you later disable the user profile, you can use the enable user profile API to make the profile visible in these searches again. -{ref}/security-api-enable-user-profile.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-enable-user-profile[Endpoint documentation] [source,ts] ---- client.security.enableUserProfile({ uid }) @@ -11761,7 +12129,7 @@ Enable a Kibana instance to configure itself for communication with a secured El NOTE: This API is currently intended for internal use only by Kibana. Kibana uses this API internally to configure itself for communications with an Elasticsearch cluster that already has security features enabled. -{ref}/security-api-kibana-enrollment.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-enroll-kibana[Endpoint documentation] [source,ts] ---- client.security.enrollKibana() @@ -11777,7 +12145,7 @@ Enroll a new node to allow it to join an existing cluster with security features The response contains all the necessary information for the joining node to bootstrap discovery and security related settings so that it can successfully join the cluster. The response contains key and certificate material that allows the caller to generate valid signed certificates for the HTTP layer of all nodes in the cluster. -{ref}/security-api-node-enrollment.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-enroll-node[Endpoint documentation] [source,ts] ---- client.security.enrollNode() @@ -11792,7 +12160,7 @@ Retrieves information for one or more API keys. NOTE: If you have only the `manage_own_api_key` privilege, this API returns only the API keys that you own. If you have `read_security`, `manage_api_key` or greater privileges (including `manage_security`), this API returns all API keys regardless of ownership. -{ref}/security-api-get-api-key.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-api-key[Endpoint documentation] [source,ts] ---- client.security.getApiKey({ ... }) @@ -11826,7 +12194,7 @@ Get builtin privileges. Get the list of cluster privileges and index privileges that are available in this version of Elasticsearch. -{ref}/security-api-get-builtin-privileges.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-builtin-privileges[Endpoint documentation] [source,ts] ---- client.security.getBuiltinPrivileges() @@ -11842,7 +12210,7 @@ To use this API, you must have one of the following privileges: * The `read_security` cluster privilege (or a greater privilege such as `manage_security` or `all`). * The "Manage Application Privileges" global privilege for the application being referenced in the request. -{ref}/security-api-get-privileges.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-privileges[Endpoint documentation] [source,ts] ---- client.security.getPrivileges({ ... }) @@ -11866,7 +12234,7 @@ Get roles in the native realm. The role management APIs are generally the preferred way to manage roles, rather than using file-based role management. The get roles API cannot retrieve roles that are defined in roles files. -{ref}/security-api-get-role.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-role[Endpoint documentation] [source,ts] ---- client.security.getRole({ ... }) @@ -11888,7 +12256,7 @@ Role mappings define which roles are assigned to each user. The role mapping APIs are generally the preferred way to manage role mappings rather than using role mapping files. The get role mappings API cannot retrieve role mappings that are defined in role mapping files. -{ref}/security-api-get-role-mapping.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-role-mapping[Endpoint documentation] [source,ts] ---- client.security.getRoleMapping({ ... }) @@ -11908,7 +12276,7 @@ Get a list of service accounts that match the provided path parameters. NOTE: Currently, only the `elastic/fleet-server` service account is available. -{ref}/security-api-get-service-accounts.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-service-accounts[Endpoint documentation] [source,ts] ---- client.security.getServiceAccounts({ ... }) @@ -11935,7 +12303,7 @@ The response includes service account tokens that were created with the create s NOTE: For tokens backed by the `service_tokens` file, the API collects them from all nodes of the cluster. Tokens with the same name from different nodes are assumed to be the same token and are only counted once towards the total number of service tokens. -{ref}/security-api-get-service-credentials.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-service-credentials[Endpoint documentation] [source,ts] ---- client.security.getServiceCredentials({ namespace, service }) @@ -11959,7 +12327,7 @@ This includes: * `index.auto_expand_replicas` * `index.number_of_replicas` -{ref}/security-api-get-settings.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-settings[Endpoint documentation] [source,ts] ---- client.security.getSettings({ ... }) @@ -11989,7 +12357,7 @@ The tokens returned by the get token API have a finite period of time for which That time period is defined by the `xpack.security.authc.token.timeout` setting. If you want to invalidate a token immediately, you can do so by using the invalidate token API. -{ref}/security-api-get-token.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-token[Endpoint documentation] [source,ts] ---- client.security.getToken({ ... }) @@ -12022,7 +12390,7 @@ Get users. Get information about users in the native realm and built-in users. -{ref}/security-api-get-user.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-user[Endpoint documentation] [source,ts] ---- client.security.getUser({ ... }) @@ -12044,7 +12412,7 @@ All users can use this API, but only to determine their own privileges. To check the privileges of other users, you must use the run as feature. To check whether a user has a specific list of privileges, use the has privileges API. -{ref}/security-api-get-user-privileges.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-user-privileges[Endpoint documentation] [source,ts] ---- client.security.getUserPrivileges({ ... }) @@ -12068,7 +12436,7 @@ NOTE: The user profile feature is designed only for use by Kibana and Elastic's Individual users and external applications should not call this API directly. Elastic reserves the right to change or remove this feature in future releases without prior notice. -{ref}/security-api-get-user-profile.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-user-profile[Endpoint documentation] [source,ts] ---- client.security.getUserProfile({ uid }) @@ -12109,7 +12477,7 @@ If applicable, it also returns expiration information for the API key in millise By default, API keys never expire. You can specify expiration information when you create the API keys. -{ref}/security-api-grant-api-key.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-grant-api-key[Endpoint documentation] [source,ts] ---- client.security.grantApiKey({ api_key, grant_type }) @@ -12140,7 +12508,7 @@ Determine whether the specified user has a specified list of privileges. All users can use this API, but only to determine their own privileges. To check the privileges of other users, you must use the run as feature. -{ref}/security-api-has-privileges.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-has-privileges[Endpoint documentation] [source,ts] ---- client.security.hasPrivileges({ ... }) @@ -12164,7 +12532,7 @@ Determine whether the users associated with the specified user profile IDs have NOTE: The user profile feature is designed only for use by Kibana and Elastic's Observability, Enterprise Search, and Elastic Security solutions. Individual users and external applications should not call this API directly. Elastic reserves the right to change or remove this feature in future releases without prior notice. -{ref}/security-api-has-privileges-user-profile.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-has-privileges-user-profile[Endpoint documentation] [source,ts] ---- client.security.hasPrivilegesUserProfile({ uids, privileges }) @@ -12194,7 +12562,7 @@ In addition, with the `manage_own_api_key` privilege, an invalidation request mu - Or, set both `username` and `realm_name` to match the user's identity. - Or, if the request is issued by an API key, that is to say an API key invalidates itself, specify its ID in the `ids` field. -{ref}/security-api-invalidate-api-key.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-invalidate-api-key[Endpoint documentation] [source,ts] ---- client.security.invalidateApiKey({ ... }) @@ -12234,7 +12602,7 @@ NOTE: While all parameters are optional, at least one of them is required. More specifically, either one of `token` or `refresh_token` parameters is required. If none of these two are specified, then `realm_name` and/or `username` need to be specified. -{ref}/security-api-invalidate-token.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-invalidate-token[Endpoint documentation] [source,ts] ---- client.security.invalidateToken({ ... }) @@ -12262,7 +12630,7 @@ Exchange an OpenID Connect authentication response message for an Elasticsearch Elasticsearch exposes all the necessary OpenID Connect related functionality with the OpenID Connect APIs. These APIs are used internally by Kibana in order to provide OpenID Connect based authentication, but can also be used by other, custom web applications or other clients. -{ref}/security-api-oidc-authenticate.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-oidc-authenticate[Endpoint documentation] [source,ts] ---- client.security.oidcAuthenticate({ nonce, redirect_uri, state }) @@ -12292,7 +12660,7 @@ If the OpenID Connect authentication realm in Elasticsearch is accordingly confi Elasticsearch exposes all the necessary OpenID Connect related functionality with the OpenID Connect APIs. These APIs are used internally by Kibana in order to provide OpenID Connect based authentication, but can also be used by other, custom web applications or other clients. -{ref}/security-api-oidc-logout.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-oidc-logout[Endpoint documentation] [source,ts] ---- client.security.oidcLogout({ access_token }) @@ -12316,7 +12684,7 @@ The response of this API is a URL pointing to the Authorization Endpoint of the Elasticsearch exposes all the necessary OpenID Connect related functionality with the OpenID Connect APIs. These APIs are used internally by Kibana in order to provide OpenID Connect based authentication, but can also be used by other, custom web applications or other clients. -{ref}/security-api-oidc-prepare-authentication.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-oidc-prepare-authentication[Endpoint documentation] [source,ts] ---- client.security.oidcPrepareAuthentication({ ... }) @@ -12361,7 +12729,7 @@ Privilege names must begin with a lowercase ASCII letter and must contain only A Action names can contain any number of printable ASCII characters and must contain at least one of the following characters: `/`, `*`, `:`. -{ref}/security-api-put-privileges.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-put-privileges[Endpoint documentation] [source,ts] ---- client.security.putPrivileges({ ... }) @@ -12382,7 +12750,7 @@ The role management APIs are generally the preferred way to manage roles in the The create or update roles API cannot update roles that are defined in roles files. File-based role management is not available in Elastic Serverless. -{ref}/security-api-put-role.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-put-role[Endpoint documentation] [source,ts] ---- client.security.putRole({ name }) @@ -12437,7 +12805,7 @@ Thus it is possible to assign a user to a role that reflects their username, the By default a template is evaluated to produce a single string that is the name of the role which should be assigned to the user. If the format of the template is set to "json" then the template is expected to produce a JSON string or an array of JSON strings for the role names. -{ref}/security-api-put-role-mapping.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-put-role-mapping[Endpoint documentation] [source,ts] ---- client.security.putRoleMapping({ name }) @@ -12469,7 +12837,7 @@ Add and update users in the native realm. A password is required for adding a new user but is optional when updating an existing user. To change a user's password without updating any other fields, use the change password API. -{ref}/security-api-put-user.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-put-user[Endpoint documentation] [source,ts] ---- client.security.putUser({ username }) @@ -12514,7 +12882,7 @@ To use this API, you must have at least the `manage_own_api_key` or the `read_se If you have only the `manage_own_api_key` privilege, this API returns only the API keys that you own. If you have the `read_security`, `manage_api_key`, or greater privileges (including `manage_security`), this API returns all API keys regardless of ownership. -{ref}/security-api-query-api-key.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-query-api-keys[Endpoint documentation] [source,ts] ---- client.security.queryApiKeys({ ... }) @@ -12569,7 +12937,7 @@ The query roles API does not retrieve roles that are defined in roles files, nor You can optionally filter the results with a query. Also, the results can be paginated and sorted. -{ref}/security-api-query-role.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-query-role[Endpoint documentation] [source,ts] ---- client.security.queryRole({ ... }) @@ -12608,7 +12976,7 @@ You can optionally filter the results with a query. NOTE: As opposed to the get user API, built-in users are excluded from the result. This API is only for native users. -{ref}/security-api-query-user.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-query-user[Endpoint documentation] [source,ts] ---- client.security.queryUser({ ... }) @@ -12656,7 +13024,7 @@ In either case, the SAML message needs to be a base64 encoded XML document with After successful validation, Elasticsearch responds with an Elasticsearch internal access token and refresh token that can be subsequently used for authentication. This API endpoint essentially exchanges SAML responses that indicate successful authentication in the IdP for Elasticsearch access and refresh tokens, which can be used for authentication against Elasticsearch. -{ref}/security-api-saml-authenticate.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-saml-authenticate[Endpoint documentation] [source,ts] ---- client.security.samlAuthenticate({ content, ids }) @@ -12685,7 +13053,7 @@ An empty response is returned if the verification process is successful. The response can be sent by the IdP with either the HTTP-Redirect or the HTTP-Post binding. The caller of this API must prepare the request accordingly so that this API can handle either of them. -{ref}/security-api-saml-complete-logout.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-saml-complete-logout[Endpoint documentation] [source,ts] ---- client.security.samlCompleteLogout({ realm, ids }) @@ -12714,7 +13082,7 @@ The custom web application can use this API to have Elasticsearch process the `L After successful validation of the request, Elasticsearch invalidates the access token and refresh token that corresponds to that specific SAML principal and provides a URL that contains a SAML LogoutResponse message. Thus the user can be redirected back to their IdP. -{ref}/security-api-saml-invalidate.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-saml-invalidate[Endpoint documentation] [source,ts] ---- client.security.samlInvalidate({ query_string }) @@ -12744,7 +13112,7 @@ If you are using Kibana, refer to the documentation for configuring SAML single- This API invalidates the tokens that were generated for a user by the SAML authenticate API. If the SAML realm in Elasticsearch is configured accordingly and the SAML IdP supports this, the Elasticsearch response contains a URL to redirect the user to the IdP that contains a SAML logout request (starting an SP-initiated SAML Single Logout). -{ref}/security-api-saml-logout.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-saml-logout[Endpoint documentation] [source,ts] ---- client.security.samlLogout({ token }) @@ -12776,7 +13144,7 @@ These parameters contain the algorithm used for the signature and the signature It also returns a random string that uniquely identifies this SAML Authentication request. The caller of this API needs to store this identifier as it needs to be used in a following step of the authentication process. -{ref}/security-api-saml-prepare-authentication.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-saml-prepare-authentication[Endpoint documentation] [source,ts] ---- client.security.samlPrepareAuthentication({ ... }) @@ -12802,7 +13170,7 @@ Generate SAML metadata for a SAML 2.0 Service Provider. The SAML 2.0 specification provides a mechanism for Service Providers to describe their capabilities and configuration using a metadata file. This API generates Service Provider metadata based on the configuration of a SAML realm in Elasticsearch. -{ref}/security-api-saml-sp-metadata.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-saml-service-provider-metadata[Endpoint documentation] [source,ts] ---- client.security.samlServiceProviderMetadata({ realm_name }) @@ -12824,7 +13192,7 @@ NOTE: The user profile feature is designed only for use by Kibana and Elastic's Individual users and external applications should not call this API directly. Elastic reserves the right to change or remove this feature in future releases without prior notice. -{ref}/security-api-suggest-user-profile.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-suggest-user-profiles[Endpoint documentation] [source,ts] ---- client.security.suggestUserProfiles({ ... }) @@ -12869,7 +13237,7 @@ The snapshot of the owner's permissions is updated automatically on every call. IMPORTANT: If you don't specify `role_descriptors` in the request, a call to this API might still change the API key's access scope. This change can occur if the owner user's permissions have changed since the API key was created or last modified. -{ref}/security-api-update-api-key.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-update-api-key[Endpoint documentation] [source,ts] ---- client.security.updateApiKey({ id }) @@ -12915,7 +13283,7 @@ The owner user's information, such as the `username` and `realm`, is also update NOTE: This API cannot update REST API keys, which should be updated by either the update API key or bulk update API keys API. -{ref}/security-api-update-cross-cluster-api-key.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-update-cross-cluster-api-key[Endpoint documentation] [source,ts] ---- client.security.updateCrossClusterApiKey({ id, access }) @@ -12948,7 +13316,7 @@ NOTE: If `index.auto_expand_replicas` is set, `index.number_of_replicas` will be If a specific index is not in use on the system and settings are provided for it, the request will be rejected. This API does not yet support configuring the settings for indices before they are in use. -{ref}/security-api-update-settings.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-update-settings[Endpoint documentation] [source,ts] ---- client.security.updateSettings({ ... }) @@ -12987,7 +13355,7 @@ New keys and their values are added to the profile document and conflicting keys For both labels and data, content is namespaced by the top-level fields. The `update_profile_data` global privilege grants privileges for updating only the allowed namespaces. -{ref}/security-api-update-user-profile-data.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-update-user-profile-data[Endpoint documentation] [source,ts] ---- client.security.updateUserProfileData({ uid }) @@ -13026,7 +13394,7 @@ Direct use is not supported. If the operator privileges feature is enabled, you must be an operator to use this API. -{ref}/delete-shutdown.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-shutdown-delete-node[Endpoint documentation] [source,ts] ---- client.shutdown.deleteNode({ node_id }) @@ -13051,7 +13419,7 @@ NOTE: This feature is designed for indirect use by Elasticsearch Service, Elasti If the operator privileges feature is enabled, you must be an operator to use this API. -{ref}/get-shutdown.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-shutdown-get-node[Endpoint documentation] [source,ts] ---- client.shutdown.getNode({ ... }) @@ -13083,7 +13451,7 @@ If a node is already being prepared for shutdown, you can use this API to change IMPORTANT: This API does NOT terminate the Elasticsearch process. Monitor the node shutdown status to determine when it is safe to stop Elasticsearch. -{ref}/put-shutdown.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-shutdown-put-node[Endpoint documentation] [source,ts] ---- client.shutdown.putNode({ node_id, type, reason }) @@ -13141,7 +13509,7 @@ By default, the pipeline definitions that are currently in the system are used. However, you can supply substitute pipeline definitions in the body of the request. These will be used in place of the pipeline definitions that are already in the system. This can be used to replace existing pipeline definitions or to create new ones. The pipeline substitutions are used only within this request. -{ref}/simulate-ingest-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-simulate-ingest[Endpoint documentation] [source,ts] ---- client.simulate.ingest({ docs }) @@ -13155,7 +13523,7 @@ client.simulate.ingest({ docs }) ** *`index` (Optional, string)*: The index to simulate ingesting into. This value can be overridden by specifying an index on each document. If you specify this parameter in the request path, it is used for any documents that do not explicitly specify an index argument. -** *`component_template_substitutions` (Optional, Record)*: A map of component template names to substitute component template definition objects. +** *`component_template_substitutions` (Optional, Record)*: A map of component template names to substitute component template definition objects. ** *`index_template_subtitutions` (Optional, Record)*: A map of index template names to substitute index template definition objects. ** *`mapping_addition` (Optional, { all_field, date_detection, dynamic, dynamic_date_formats, dynamic_templates, _field_names, index_field, _meta, numeric_detection, properties, _routing, _size, _source, runtime, enabled, subobjects, _data_stream_timestamp })* ** *`pipeline_substitutions` (Optional, Record)*: Pipelines to test. @@ -13172,7 +13540,7 @@ Delete a policy. Delete a snapshot lifecycle policy definition. This operation prevents any future snapshots from being taken but does not cancel in-progress snapshots or remove previously-taken snapshots. -{ref}/slm-api-delete-policy.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-delete-lifecycle[Endpoint documentation] [source,ts] ---- client.slm.deleteLifecycle({ policy_id }) @@ -13194,7 +13562,7 @@ Run a policy. Immediately create a snapshot according to the snapshot lifecycle policy without waiting for the scheduled time. The snapshot policy is normally applied according to its schedule, but you might want to manually run a policy before performing an upgrade or other maintenance. -{ref}/slm-api-execute-lifecycle.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-execute-lifecycle[Endpoint documentation] [source,ts] ---- client.slm.executeLifecycle({ policy_id }) @@ -13216,7 +13584,7 @@ Run a retention policy. Manually apply the retention policy to force immediate removal of snapshots that are expired according to the snapshot lifecycle policy retention rules. The retention policy is normally applied according to its schedule. -{ref}/slm-api-execute-retention.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-execute-retention[Endpoint documentation] [source,ts] ---- client.slm.executeRetention({ ... }) @@ -13236,7 +13604,7 @@ If no response is received before the timeout expires, the request fails and ret Get policy information. Get snapshot lifecycle policy definitions and information about the latest snapshot attempts. -{ref}/slm-api-get-policy.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-get-lifecycle[Endpoint documentation] [source,ts] ---- client.slm.getLifecycle({ ... }) @@ -13257,7 +13625,7 @@ If no response is received before the timeout expires, the request fails and ret Get snapshot lifecycle management statistics. Get global and policy-level statistics about actions taken by snapshot lifecycle management. -{ref}/slm-api-get-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-get-stats[Endpoint documentation] [source,ts] ---- client.slm.getStats({ ... }) @@ -13274,7 +13642,7 @@ client.slm.getStats({ ... }) ==== get_status Get the snapshot lifecycle management status. -{ref}/slm-api-get-status.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-get-status[Endpoint documentation] [source,ts] ---- client.slm.getStatus({ ... }) @@ -13298,7 +13666,7 @@ Create or update a snapshot lifecycle policy. If the policy already exists, this request increments the policy version. Only the latest version of a policy is stored. -{ref}/slm-api-put-policy.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-put-lifecycle[Endpoint documentation] [source,ts] ---- client.slm.putLifecycle({ policy_id }) @@ -13327,7 +13695,7 @@ Start snapshot lifecycle management. Snapshot lifecycle management (SLM) starts automatically when a cluster is formed. Manually starting SLM is necessary only if it has been stopped using the stop SLM API. -{ref}/slm-api-start.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-start[Endpoint documentation] [source,ts] ---- client.slm.start({ ... }) @@ -13355,7 +13723,7 @@ You can manually trigger snapshots with the run snapshot lifecycle policy API ev The API returns a response as soon as the request is acknowledged, but the plugin might continue to run until in-progress operations complete and it can be safely stopped. Use the get snapshot lifecycle management status API to see if SLM is running. -{ref}/slm-api-stop.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-stop[Endpoint documentation] [source,ts] ---- client.slm.stop({ ... }) @@ -13379,7 +13747,7 @@ To indicate that the request should never timeout, set it to `-1`. Clean up the snapshot repository. Trigger the review of the contents of a snapshot repository and delete any stale data not referenced by existing snapshots. -{ref}/clean-up-snapshot-repo-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-cleanup-repository[Endpoint documentation] [source,ts] ---- client.snapshot.cleanupRepository({ repository }) @@ -13402,7 +13770,7 @@ To indicate that the request should never timeout, set it to `-1`. Clone a snapshot. Clone part of all of a snapshot into another snapshot in the same repository. -{ref}/clone-snapshot-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-clone[Endpoint documentation] [source,ts] ---- client.snapshot.clone({ repository, snapshot, target_snapshot, indices }) @@ -13428,7 +13796,7 @@ If no response is received before the timeout expires, the request fails and ret Create a snapshot. Take a snapshot of a cluster or of data streams and indices. -{ref}/create-snapshot-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-create[Endpoint documentation] [source,ts] ---- client.snapshot.create({ repository, snapshot }) @@ -13488,7 +13856,7 @@ Ensure there are no cluster blocks (for example, `cluster.blocks.read_only` and Several options for this API can be specified using a query parameter or a request body parameter. If both parameters are specified, only the query parameter is used. -{ref}/put-snapshot-repo-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-create-repository[Endpoint documentation] [source,ts] ---- client.snapshot.createRepository({ repository }) @@ -13513,7 +13881,7 @@ You can also perform this verification with the verify snapshot repository API. ==== delete Delete snapshots. -{ref}/delete-snapshot-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-delete[Endpoint documentation] [source,ts] ---- client.snapshot.delete({ repository, snapshot }) @@ -13536,7 +13904,7 @@ Delete snapshot repositories. When a repository is unregistered, Elasticsearch removes only the reference to the location where the repository is storing the snapshots. The snapshots themselves are left untouched and in place. -{ref}/delete-snapshot-repo-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-delete-repository[Endpoint documentation] [source,ts] ---- client.snapshot.deleteRepository({ repository }) @@ -13563,7 +13931,7 @@ NOTE: The `after` parameter and `next` field enable you to iterate through snaps It is guaranteed that any snapshot that exists at the beginning of the iteration and is not concurrently deleted will be seen during the iteration. Snapshots concurrently created may be seen during an iteration. -{ref}/get-snapshot-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-get[Endpoint documentation] [source,ts] ---- client.snapshot.get({ repository, snapshot }) @@ -13613,7 +13981,7 @@ NOTE: The parameters `size`, `order`, `after`, `from_sort_value`, `offset`, `slm ==== get_repository Get snapshot repository information. -{ref}/get-snapshot-repo-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-get-repository[Endpoint documentation] [source,ts] ---- client.snapshot.getRepository({ ... }) @@ -13729,7 +14097,7 @@ If an operation fails due to contention, Elasticsearch retries the operation unt Most of the compare-and-exchange operations performed by repository analysis atomically increment a counter which is represented as an 8-byte blob. Some operations also verify the behavior on small blobs with sizes other than 8 bytes. -{ref}/repo-analysis-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-repository-analyze[Endpoint documentation] [source,ts] ---- client.snapshot.repositoryAnalyze({ repository }) @@ -13783,7 +14151,7 @@ If no such template exists, you can create one or restore a cluster state that c If your snapshot contains data from App Search or Workplace Search, you must restore the Enterprise Search encryption key before you restore the snapshot. -{ref}/restore-snapshot-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-restore[Endpoint documentation] [source,ts] ---- client.snapshot.restore({ repository, snapshot }) @@ -13874,7 +14242,7 @@ For example, if you have 100 snapshots with 1,000 shards each, an API request th Depending on the latency of your storage, such requests can take an extremely long time to return results. These requests can also tax machine resources and, when using cloud storage, incur high processing costs. -{ref}/get-snapshot-status-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-status[Endpoint documentation] [source,ts] ---- client.snapshot.status({ ... }) @@ -13900,7 +14268,7 @@ To indicate that the request should never timeout, set it to `-1`. Verify a snapshot repository. Check for common misconfigurations in a snapshot repository. -{ref}/verify-snapshot-repo-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-verify-repository[Endpoint documentation] [source,ts] ---- client.snapshot.verifyRepository({ repository }) @@ -13924,7 +14292,7 @@ To indicate that the request should never timeout, set it to `-1`. ==== clear_cursor Clear an SQL search cursor. -{ref}/clear-sql-cursor-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-sql-clear-cursor[Endpoint documentation] [source,ts] ---- client.sql.clearCursor({ cursor }) @@ -13947,7 +14315,7 @@ If the Elasticsearch security features are enabled, only the following users can * Users with the `cancel_task` cluster privilege. * The user who first submitted the search. -{ref}/delete-async-sql-search-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-sql-delete-async[Endpoint documentation] [source,ts] ---- client.sql.deleteAsync({ id }) @@ -13966,7 +14334,7 @@ Get the current status and available results for an async SQL search or stored s If the Elasticsearch security features are enabled, only the user who first submitted the SQL search can retrieve the search using this API. -{ref}/get-async-sql-search-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-sql-get-async[Endpoint documentation] [source,ts] ---- client.sql.getAsync({ id }) @@ -13992,7 +14360,7 @@ It defaults to no timeout, meaning the request waits for complete search results Get the async SQL search status. Get the current status of an async SQL search or a stored synchronous SQL search. -{ref}/get-async-sql-search-status-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-sql-get-async-status[Endpoint documentation] [source,ts] ---- client.sql.getAsyncStatus({ id }) @@ -14009,7 +14377,7 @@ client.sql.getAsyncStatus({ id }) Get SQL search results. Run an SQL request. -{ref}/sql-search-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-sql-query[Endpoint documentation] [source,ts] ---- client.sql.query({ ... }) @@ -14060,7 +14428,7 @@ Translate SQL into Elasticsearch queries. Translate an SQL search into a search API request containing Query DSL. It accepts the same request body parameters as the SQL search API, excluding `cursor`. -{ref}/sql-translate-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-sql-translate[Endpoint documentation] [source,ts] ---- client.sql.translate({ query }) @@ -14097,7 +14465,7 @@ NOTE: When a PKCS#11 token is configured as the truststore of the JRE, the API r If Elasticsearch is configured to use a keystore or truststore, the API output includes all certificates in that store, even though some of the certificates might not be in active use within the cluster. -{ref}/security-api-ssl.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ssl-certificates[Endpoint documentation] [source,ts] ---- client.ssl.certificates() @@ -14127,7 +14495,7 @@ You can migrate an index by creating a new index that does not contain the token Once finished, you can delete the index. When the synonyms set is not used in analyzers, you will be able to delete it. -{ref}/delete-synonyms-set.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-delete-synonym[Endpoint documentation] [source,ts] ---- client.synonyms.deleteSynonym({ id }) @@ -14144,7 +14512,7 @@ client.synonyms.deleteSynonym({ id }) Delete a synonym rule. Delete a synonym rule from a synonym set. -{ref}/delete-synonym-rule.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-delete-synonym-rule[Endpoint documentation] [source,ts] ---- client.synonyms.deleteSynonymRule({ set_id, rule_id }) @@ -14161,7 +14529,7 @@ client.synonyms.deleteSynonymRule({ set_id, rule_id }) ==== get_synonym Get a synonym set. -{ref}/get-synonyms-set.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-get-synonym[Endpoint documentation] [source,ts] ---- client.synonyms.getSynonym({ id }) @@ -14180,7 +14548,7 @@ client.synonyms.getSynonym({ id }) Get a synonym rule. Get a synonym rule from a synonym set. -{ref}/get-synonym-rule.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-get-synonym-rule[Endpoint documentation] [source,ts] ---- client.synonyms.getSynonymRule({ set_id, rule_id }) @@ -14198,7 +14566,7 @@ client.synonyms.getSynonymRule({ set_id, rule_id }) Get all synonym sets. Get a summary of all defined synonym sets. -{ref}/get-synonyms-set.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-get-synonym[Endpoint documentation] [source,ts] ---- client.synonyms.getSynonymsSets({ ... }) @@ -14220,7 +14588,7 @@ If you need to manage more synonym rules, you can create multiple synonym sets. When an existing synonyms set is updated, the search analyzers that use the synonyms set are reloaded automatically for all indices. This is equivalent to invoking the reload search analyzers API for all indices that use the synonyms set. -{ref}/put-synonyms-set.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-put-synonym[Endpoint documentation] [source,ts] ---- client.synonyms.putSynonym({ id, synonyms_set }) @@ -14242,7 +14610,7 @@ If any of the synonym rules included is invalid, the API returns an error. When you update a synonym rule, all analyzers using the synonyms set will be reloaded automatically to reflect the new rule. -{ref}/put-synonym-rule.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-put-synonym-rule[Endpoint documentation] [source,ts] ---- client.synonyms.putSynonymRule({ set_id, rule_id, synonyms }) @@ -14273,7 +14641,7 @@ The cancelled flag in the response indicates that the cancellation command has b To troubleshoot why a cancelled task does not complete promptly, use the get task information API with the `?detailed` parameter to identify the other tasks the system is running. You can also use the node hot threads API to obtain detailed information about the work the system is doing instead of completing the cancelled task. -{ref}/tasks.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-tasks[Endpoint documentation] [source,ts] ---- client.tasks.cancel({ ... }) @@ -14299,7 +14667,7 @@ The API may change in ways that are not backwards compatible. If the task identifier is not found, a 404 response code indicates that there are no resources that match the request. -{ref}/tasks.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-tasks[Endpoint documentation] [source,ts] ---- client.tasks.get({ task_id }) @@ -14376,7 +14744,7 @@ In this example, `X-Opaque-Id: 123456` is the ID as a part of the response heade The `X-Opaque-Id` in the task `headers` is the ID for the task that was initiated by the REST request. The `X-Opaque-Id` in the children `headers` is the child task of the task that was initiated by the REST request. -{ref}/tasks.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-tasks[Endpoint documentation] [source,ts] ---- client.tasks.list({ ... }) @@ -14424,7 +14792,7 @@ However, you can optionally override some of the decisions about the text struct If the structure finder produces unexpected results, specify the `explain` query parameter and an explanation will appear in the response. It helps determine why the returned structure was chosen. -{ref}/find-field-structure.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-text_structure[Endpoint documentation] [source,ts] ---- client.textStructure.findFieldStructure({ field, index }) @@ -14536,7 +14904,7 @@ However, you can optionally override some of the decisions about the text struct If the structure finder produces unexpected results, specify the `explain` query parameter and an explanation will appear in the response. It helps determine why the returned structure was chosen. -{ref}/find-message-structure.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-text-structure-find-message-structure[Endpoint documentation] [source,ts] ---- client.textStructure.findMessageStructure({ messages }) @@ -14642,7 +15010,7 @@ The response from the API contains: All this information can be calculated by the structure finder with no guidance. However, you can optionally override some of the decisions about the text structure by specifying one or more query parameters. -{ref}/find-structure.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-text-structure-find-structure[Endpoint documentation] [source,ts] ---- client.textStructure.findStructure({ ... }) @@ -14753,7 +15121,7 @@ Test a Grok pattern. Test a Grok pattern on one or more lines of text. The API indicates whether the lines match the pattern together with the offsets and lengths of the matched substrings. -{ref}/test-grok-pattern.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-text-structure-test-grok-pattern[Endpoint documentation] [source,ts] ---- client.textStructure.testGrokPattern({ grok_pattern, text }) @@ -14774,9 +15142,8 @@ Valid values are `disabled` and `v1`. [discrete] ==== delete_transform Delete a transform. -Deletes a transform. -{ref}/delete-transform.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-delete-transform[Endpoint documentation] [source,ts] ---- client.transform.deleteTransform({ transform_id }) @@ -14805,9 +15172,9 @@ client.transform.getNodeStats() [discrete] ==== get_transform Get transforms. -Retrieves configuration information for transforms. +Get configuration information for transforms. -{ref}/get-transform.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-get-transform[Endpoint documentation] [source,ts] ---- client.transform.getTransform({ ... }) @@ -14838,9 +15205,10 @@ be retrieved and then added to another cluster. [discrete] ==== get_transform_stats Get transform stats. -Retrieves usage information for transforms. -{ref}/get-transform-stats.html[Endpoint documentation] +Get usage information for transforms. + +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-get-transform-stats[Endpoint documentation] [source,ts] ---- client.transform.getTransformStats({ transform_id }) @@ -14875,7 +15243,7 @@ It returns a maximum of 100 results. The calculations are based on all the curre generates a list of mappings and settings for the destination index. These values are determined based on the field types of the source index and the transform aggregations. -{ref}/preview-transform.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-preview-transform[Endpoint documentation] [source,ts] ---- client.transform.previewTransform({ ... }) @@ -14931,7 +15299,7 @@ NOTE: You must use Kibana or this API to create a transform. Do not add a transf not give users any privileges on `.transform-internal*` indices. If you used transforms prior to 7.5, also do not give users any privileges on `.data-frame-internal*` indices. -{ref}/put-transform.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-put-transform[Endpoint documentation] [source,ts] ---- client.transform.putTransform({ transform_id, dest, source }) @@ -14967,11 +15335,11 @@ the exception of privilege checks. [discrete] ==== reset_transform Reset a transform. -Resets a transform. + Before you can reset it, you must stop it; alternatively, use the `force` query parameter. If the destination index was created by the transform, it is deleted. -{ref}/reset-transform.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-reset-transform[Endpoint documentation] [source,ts] ---- client.transform.resetTransform({ transform_id }) @@ -14990,14 +15358,14 @@ must be stopped before it can be reset. [discrete] ==== schedule_now_transform Schedule a transform to start now. -Instantly runs a transform to process data. -If you _schedule_now a transform, it will process the new data instantly, -without waiting for the configured frequency interval. After _schedule_now API is called, -the transform will be processed again at now + frequency unless _schedule_now API +Instantly run a transform to process data. +If you run this API, the transform will process the new data instantly, +without waiting for the configured frequency interval. After the API is called, +the transform will be processed again at `now + frequency` unless the API is called again in the meantime. -{ref}/schedule-now-transform.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-schedule-now-transform[Endpoint documentation] [source,ts] ---- client.transform.scheduleNowTransform({ transform_id }) @@ -15013,7 +15381,6 @@ client.transform.scheduleNowTransform({ transform_id }) [discrete] ==== start_transform Start a transform. -Starts a transform. When you start a transform, it creates the destination index if it does not already exist. The `number_of_shards` is set to `1` and the `auto_expand_replicas` is set to `0-1`. If it is a pivot transform, it deduces the mapping @@ -15030,7 +15397,7 @@ Elasticsearch security features are enabled, the transform remembers which roles time of creation and uses those same roles. If those roles do not have the required privileges on the source and destination indices, the transform fails when it attempts unauthorized operations. -{ref}/start-transform.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-start-transform[Endpoint documentation] [source,ts] ---- client.transform.startTransform({ transform_id }) @@ -15049,7 +15416,7 @@ client.transform.startTransform({ transform_id }) Stop transforms. Stops one or more transforms. -{ref}/stop-transform.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-stop-transform[Endpoint documentation] [source,ts] ---- client.transform.stopTransform({ transform_id }) @@ -15089,7 +15456,7 @@ privileges for the source indices. You must also have `index` and `read` privile Elasticsearch security features are enabled, the transform remembers which roles the user who updated it had at the time of update and runs with those privileges. -{ref}/update-transform.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-update-transform[Endpoint documentation] [source,ts] ---- client.transform.updateTransform({ transform_id }) @@ -15121,6 +15488,7 @@ timeout expires, the request fails and returns an error. [discrete] ==== upgrade_transforms Upgrade all transforms. + Transforms are compatible across minor versions and between supported major versions. However, over time, the format of transform configuration information may change. This API identifies transforms that have a legacy configuration format and upgrades them to the latest version. @@ -15135,7 +15503,7 @@ A summary is returned when the upgrade is finished. To ensure continuous transforms remain running during a major version upgrade of the cluster – for example, from 7.16 to 8.0 – it is recommended to upgrade transforms before upgrading the cluster. You may want to perform a recent cluster backup prior to the upgrade. -{ref}/upgrade-transforms.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-upgrade-transforms[Endpoint documentation] [source,ts] ---- client.transform.upgradeTransforms({ ... }) @@ -15164,7 +15532,7 @@ The reason for this behavior is to prevent overwriting the watch status from a w Acknowledging an action throttles further executions of that action until its `ack.state` is reset to `awaits_successful_execution`. This happens when the condition of the watch is not met (the condition evaluates to false). -{ref}/watcher-api-ack-watch.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-ack-watch[Endpoint documentation] [source,ts] ---- client.watcher.ackWatch({ watch_id }) @@ -15183,7 +15551,7 @@ If you omit this parameter, all of the actions of the watch are acknowledged. Activate a watch. A watch can be either active or inactive. -{ref}/watcher-api-activate-watch.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-activate-watch[Endpoint documentation] [source,ts] ---- client.watcher.activateWatch({ watch_id }) @@ -15200,7 +15568,7 @@ client.watcher.activateWatch({ watch_id }) Deactivate a watch. A watch can be either active or inactive. -{ref}/watcher-api-deactivate-watch.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-deactivate-watch[Endpoint documentation] [source,ts] ---- client.watcher.deactivateWatch({ watch_id }) @@ -15223,7 +15591,7 @@ IMPORTANT: Deleting a watch must be done by using only this API. Do not delete the watch directly from the `.watches` index using the Elasticsearch delete document API When Elasticsearch security features are enabled, make sure no write privileges are granted to anyone for the `.watches` index. -{ref}/watcher-api-delete-watch.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-delete-watch[Endpoint documentation] [source,ts] ---- client.watcher.deleteWatch({ id }) @@ -15252,7 +15620,7 @@ If your user is allowed to read index `a`, but not index `b`, then the exact sam When using the run watch API, the authorization data of the user that called the API will be used as a base, instead of the information who stored the watch. -{ref}/watcher-api-execute-watch.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-execute-watch[Endpoint documentation] [source,ts] ---- client.watcher.executeWatch({ ... }) @@ -15281,7 +15649,7 @@ Get Watcher index settings. Get settings for the Watcher internal index (`.watches`). Only a subset of settings are shown, for example `index.auto_expand_replicas` and `index.number_of_replicas`. -{ref}/watcher-api-get-settings.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-get-settings[Endpoint documentation] [source,ts] ---- client.watcher.getSettings({ ... }) @@ -15298,7 +15666,7 @@ If no response is received before the timeout expires, the request fails and ret ==== get_watch Get a watch. -{ref}/watcher-api-get-watch.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-get-watch[Endpoint documentation] [source,ts] ---- client.watcher.getWatch({ id }) @@ -15325,7 +15693,7 @@ When you add a watch you can also define its initial active state by setting the When Elasticsearch security features are enabled, your watch can index or search only on indices for which the user that stored the watch has privileges. If the user is able to read index `a`, but not index `b`, the same will apply when the watch runs. -{ref}/watcher-api-put-watch.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-put-watch[Endpoint documentation] [source,ts] ---- client.watcher.putWatch({ id }) @@ -15360,7 +15728,7 @@ Get all registered watches in a paginated manner and optionally filter watches b Note that only the `_id` and `metadata.*` fields are queryable or sortable. -{ref}/watcher-api-query-watches.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-query-watches[Endpoint documentation] [source,ts] ---- client.watcher.queryWatches({ ... }) @@ -15383,7 +15751,7 @@ It must be non-negative. Start the watch service. Start the Watcher service if it is not already running. -{ref}/watcher-api-start.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-start[Endpoint documentation] [source,ts] ---- client.watcher.start({ ... }) @@ -15401,7 +15769,7 @@ Get Watcher statistics. This API always returns basic metrics. You retrieve more metrics by using the metric parameter. -{ref}/watcher-api-stats.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-stats[Endpoint documentation] [source,ts] ---- client.watcher.stats({ ... }) @@ -15419,7 +15787,7 @@ client.watcher.stats({ ... }) Stop the watch service. Stop the Watcher service if it is running. -{ref}/watcher-api-stop.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-stop[Endpoint documentation] [source,ts] ---- client.watcher.stop({ ... }) @@ -15440,7 +15808,7 @@ Update settings for the Watcher internal index (`.watches`). Only a subset of settings can be modified. This includes `index.auto_expand_replicas` and `index.number_of_replicas`. -{ref}/watcher-api-update-settings.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-update-settings[Endpoint documentation] [source,ts] ---- client.watcher.updateSettings({ ... }) @@ -15468,7 +15836,7 @@ The information provided by the API includes: * License information about the currently installed license. * Feature information for the features that are currently enabled and available under the current license. -{ref}/info-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-info[Endpoint documentation] [source,ts] ---- client.xpack.info({ ... }) @@ -15490,7 +15858,7 @@ Get usage information. Get information about the features that are currently enabled and available under the current license. The API also provides some usage statistics. -{ref}/usage-api.html[Endpoint documentation] +https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-xpack[Endpoint documentation] [source,ts] ---- client.xpack.usage({ ... }) diff --git a/src/api/api/async_search.ts b/src/api/api/async_search.ts index b4d711bc4..256420631 100644 --- a/src/api/api/async_search.ts +++ b/src/api/api/async_search.ts @@ -45,7 +45,7 @@ export default class AsyncSearch { /** * Delete an async search. If the asynchronous search is still running, it is cancelled. Otherwise, the saved search results are deleted. If the Elasticsearch security features are enabled, the deletion of a specific async search is restricted to: the authenticated user that submitted the original search request; users that have the `cancel_task` cluster privilege. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/async-search.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-async-search-submit | Elasticsearch API documentation} */ async delete (this: That, params: T.AsyncSearchDeleteRequest, options?: TransportRequestOptionsWithOutMeta): Promise async delete (this: That, params: T.AsyncSearchDeleteRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class AsyncSearch { /** * Get async search results. Retrieve the results of a previously submitted asynchronous search request. If the Elasticsearch security features are enabled, access to the results of a specific async search is restricted to the user or API key that submitted it. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/async-search.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-async-search-submit | Elasticsearch API documentation} */ async get> (this: That, params: T.AsyncSearchGetRequest, options?: TransportRequestOptionsWithOutMeta): Promise> async get> (this: That, params: T.AsyncSearchGetRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> @@ -129,7 +129,7 @@ export default class AsyncSearch { /** * Get the async search status. Get the status of a previously submitted async search request given its identifier, without retrieving search results. If the Elasticsearch security features are enabled, use of this API is restricted to the `monitoring_user` role. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/async-search.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-async-search-submit | Elasticsearch API documentation} */ async status (this: That, params: T.AsyncSearchStatusRequest, options?: TransportRequestOptionsWithOutMeta): Promise async status (this: That, params: T.AsyncSearchStatusRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -171,7 +171,7 @@ export default class AsyncSearch { /** * Run an async search. When the primary sort of the results is an indexed field, shards get sorted based on minimum and maximum value that they hold for that field. Partial results become available following the sort criteria that was requested. Warning: Asynchronous search does not support scroll or search requests that include only the suggest section. By default, Elasticsearch does not allow you to store an async search response larger than 10Mb and an attempt to do this results in an error. The maximum allowed size for a stored async search response can be set by changing the `search.max_async_search_response_size` cluster level setting. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/async-search.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-async-search-submit | Elasticsearch API documentation} */ async submit> (this: That, params?: T.AsyncSearchSubmitRequest, options?: TransportRequestOptionsWithOutMeta): Promise> async submit> (this: That, params?: T.AsyncSearchSubmitRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/autoscaling.ts b/src/api/api/autoscaling.ts index f1e588e08..7f123c5a2 100644 --- a/src/api/api/autoscaling.ts +++ b/src/api/api/autoscaling.ts @@ -45,7 +45,7 @@ export default class Autoscaling { /** * Delete an autoscaling policy. NOTE: This feature is designed for indirect use by Elasticsearch Service, Elastic Cloud Enterprise, and Elastic Cloud on Kubernetes. Direct use is not supported. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/autoscaling-delete-autoscaling-policy.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-autoscaling-delete-autoscaling-policy | Elasticsearch API documentation} */ async deleteAutoscalingPolicy (this: That, params: T.AutoscalingDeleteAutoscalingPolicyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteAutoscalingPolicy (this: That, params: T.AutoscalingDeleteAutoscalingPolicyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class Autoscaling { /** * Get the autoscaling capacity. NOTE: This feature is designed for indirect use by Elasticsearch Service, Elastic Cloud Enterprise, and Elastic Cloud on Kubernetes. Direct use is not supported. This API gets the current autoscaling capacity based on the configured autoscaling policy. It will return information to size the cluster appropriately to the current workload. The `required_capacity` is calculated as the maximum of the `required_capacity` result of all individual deciders that are enabled for the policy. The operator should verify that the `current_nodes` match the operator’s knowledge of the cluster to avoid making autoscaling decisions based on stale or incomplete information. The response contains decider-specific information you can use to diagnose how and why autoscaling determined a certain capacity was required. This information is provided for diagnosis only. Do not use this information to make autoscaling decisions. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/autoscaling-get-autoscaling-capacity.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-autoscaling-get-autoscaling-capacity | Elasticsearch API documentation} */ async getAutoscalingCapacity (this: That, params?: T.AutoscalingGetAutoscalingCapacityRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getAutoscalingCapacity (this: That, params?: T.AutoscalingGetAutoscalingCapacityRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -127,7 +127,7 @@ export default class Autoscaling { /** * Get an autoscaling policy. NOTE: This feature is designed for indirect use by Elasticsearch Service, Elastic Cloud Enterprise, and Elastic Cloud on Kubernetes. Direct use is not supported. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/autoscaling-get-autoscaling-capacity.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-autoscaling-get-autoscaling-capacity | Elasticsearch API documentation} */ async getAutoscalingPolicy (this: That, params: T.AutoscalingGetAutoscalingPolicyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getAutoscalingPolicy (this: That, params: T.AutoscalingGetAutoscalingPolicyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -169,7 +169,7 @@ export default class Autoscaling { /** * Create or update an autoscaling policy. NOTE: This feature is designed for indirect use by Elasticsearch Service, Elastic Cloud Enterprise, and Elastic Cloud on Kubernetes. Direct use is not supported. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/autoscaling-put-autoscaling-policy.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-autoscaling-put-autoscaling-policy | Elasticsearch API documentation} */ async putAutoscalingPolicy (this: That, params: T.AutoscalingPutAutoscalingPolicyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putAutoscalingPolicy (this: That, params: T.AutoscalingPutAutoscalingPolicyRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/bulk.ts b/src/api/api/bulk.ts index 5654ffc1f..ccdedfcb2 100644 --- a/src/api/api/bulk.ts +++ b/src/api/api/bulk.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Bulk index or delete documents. Perform multiple `index`, `create`, `delete`, and `update` actions in a single request. This reduces overhead and can greatly increase indexing speed. If the Elasticsearch security features are enabled, you must have the following index privileges for the target data stream, index, or index alias: * To use the `create` action, you must have the `create_doc`, `create`, `index`, or `write` index privilege. Data streams support only the `create` action. * To use the `index` action, you must have the `create`, `index`, or `write` index privilege. * To use the `delete` action, you must have the `delete` or `write` index privilege. * To use the `update` action, you must have the `index` or `write` index privilege. * To automatically create a data stream or index with a bulk API request, you must have the `auto_configure`, `create_index`, or `manage` index privilege. * To make the result of a bulk operation visible to search using the `refresh` parameter, you must have the `maintenance` or `manage` index privilege. Automatic data stream creation requires a matching index template with data stream enabled. The actions are specified in the request body using a newline delimited JSON (NDJSON) structure: ``` action_and_meta_data\n optional_source\n action_and_meta_data\n optional_source\n .... action_and_meta_data\n optional_source\n ``` The `index` and `create` actions expect a source on the next line and have the same semantics as the `op_type` parameter in the standard index API. A `create` action fails if a document with the same ID already exists in the target An `index` action adds or replaces a document as necessary. NOTE: Data streams support only the `create` action. To update or delete a document in a data stream, you must target the backing index containing the document. An `update` action expects that the partial doc, upsert, and script and its options are specified on the next line. A `delete` action does not expect a source on the next line and has the same semantics as the standard delete API. NOTE: The final line of data must end with a newline character (`\n`). Each newline character may be preceded by a carriage return (`\r`). When sending NDJSON data to the `_bulk` endpoint, use a `Content-Type` header of `application/json` or `application/x-ndjson`. Because this format uses literal newline characters (`\n`) as delimiters, make sure that the JSON actions and sources are not pretty printed. If you provide a target in the request path, it is used for any actions that don't explicitly specify an `_index` argument. A note on the format: the idea here is to make processing as fast as possible. As some of the actions are redirected to other shards on other nodes, only `action_meta_data` is parsed on the receiving node side. Client libraries using this protocol should try and strive to do something similar on the client side, and reduce buffering as much as possible. There is no "correct" number of actions to perform in a single bulk request. Experiment with different settings to find the optimal size for your particular workload. Note that Elasticsearch limits the maximum size of a HTTP request to 100mb by default so clients must ensure that no request exceeds this size. It is not possible to index a single document that exceeds the size limit, so you must pre-process any such documents into smaller pieces before sending them to Elasticsearch. For instance, split documents into pages or chapters before indexing them, or store raw binary data in a system outside Elasticsearch and replace the raw data with a link to the external system in the documents that you send to Elasticsearch. **Client suppport for bulk requests** Some of the officially supported clients provide helpers to assist with bulk requests and reindexing: * Go: Check out `esutil.BulkIndexer` * Perl: Check out `Search::Elasticsearch::Client::5_0::Bulk` and `Search::Elasticsearch::Client::5_0::Scroll` * Python: Check out `elasticsearch.helpers.*` * JavaScript: Check out `client.helpers.*` * .NET: Check out `BulkAllObservable` * PHP: Check out bulk indexing. **Submitting bulk requests with cURL** If you're providing text file input to `curl`, you must use the `--data-binary` flag instead of plain `-d`. The latter doesn't preserve newlines. For example: ``` $ cat requests { "index" : { "_index" : "test", "_id" : "1" } } { "field1" : "value1" } $ curl -s -H "Content-Type: application/x-ndjson" -XPOST localhost:9200/_bulk --data-binary "@requests"; echo {"took":7, "errors": false, "items":[{"index":{"_index":"test","_id":"1","_version":1,"result":"created","forced_refresh":false}}]} ``` **Optimistic concurrency control** Each `index` and `delete` action within a bulk API call may include the `if_seq_no` and `if_primary_term` parameters in their respective action and meta data lines. The `if_seq_no` and `if_primary_term` parameters control how operations are run, based on the last modification to existing documents. See Optimistic concurrency control for more details. **Versioning** Each bulk item can include the version value using the `version` field. It automatically follows the behavior of the index or delete operation based on the `_version` mapping. It also support the `version_type`. **Routing** Each bulk item can include the routing value using the `routing` field. It automatically follows the behavior of the index or delete operation based on the `_routing` mapping. NOTE: Data streams do not support custom routing unless they were created with the `allow_custom_routing` setting enabled in the template. **Wait for active shards** When making bulk calls, you can set the `wait_for_active_shards` parameter to require a minimum number of shard copies to be active before starting to process the bulk request. **Refresh** Control when the changes made by this request are visible to search. NOTE: Only the shards that receive the bulk request will be affected by refresh. Imagine a `_bulk?refresh=wait_for` request with three documents in it that happen to be routed to different shards in an index with five shards. The request will only wait for those three shards to refresh. The other two shards that make up the index do not participate in the `_bulk` request at all. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-bulk.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-bulk | Elasticsearch API documentation} */ export default async function BulkApi (this: That, params: T.BulkRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function BulkApi (this: That, params: T.BulkRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/cat.ts b/src/api/api/cat.ts index e4dc21b04..bc397b310 100644 --- a/src/api/api/cat.ts +++ b/src/api/api/cat.ts @@ -45,7 +45,7 @@ export default class Cat { /** * Get aliases. Get the cluster's index aliases, including filter and routing information. This API does not return data stream aliases. IMPORTANT: CAT APIs are only intended for human consumption using the command line or the Kibana console. They are not intended for use by applications. For application consumption, use the aliases API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-alias.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-aliases | Elasticsearch API documentation} */ async aliases (this: That, params?: T.CatAliasesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async aliases (this: That, params?: T.CatAliasesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -95,7 +95,7 @@ export default class Cat { /** * Get shard allocation information. Get a snapshot of the number of shards allocated to each data node and their disk space. IMPORTANT: CAT APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-allocation.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-allocation | Elasticsearch API documentation} */ async allocation (this: That, params?: T.CatAllocationRequest, options?: TransportRequestOptionsWithOutMeta): Promise async allocation (this: That, params?: T.CatAllocationRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -145,7 +145,7 @@ export default class Cat { /** * Get component templates. Get information about component templates in a cluster. Component templates are building blocks for constructing index templates that specify index mappings, settings, and aliases. IMPORTANT: CAT APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the get component template API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-component-templates.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-component-templates | Elasticsearch API documentation} */ async componentTemplates (this: That, params?: T.CatComponentTemplatesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async componentTemplates (this: That, params?: T.CatComponentTemplatesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -195,7 +195,7 @@ export default class Cat { /** * Get a document count. Get quick access to a document count for a data stream, an index, or an entire cluster. The document count only includes live documents, not deleted documents which have not yet been removed by the merge process. IMPORTANT: CAT APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the count API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-count.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-count | Elasticsearch API documentation} */ async count (this: That, params?: T.CatCountRequest, options?: TransportRequestOptionsWithOutMeta): Promise async count (this: That, params?: T.CatCountRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -245,7 +245,7 @@ export default class Cat { /** * Get field data cache information. Get the amount of heap memory currently used by the field data cache on every data node in the cluster. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the nodes stats API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-fielddata.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-fielddata | Elasticsearch API documentation} */ async fielddata (this: That, params?: T.CatFielddataRequest, options?: TransportRequestOptionsWithOutMeta): Promise async fielddata (this: That, params?: T.CatFielddataRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -295,7 +295,7 @@ export default class Cat { /** * Get the cluster health status. IMPORTANT: CAT APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the cluster health API. This API is often used to check malfunctioning clusters. To help you track cluster health alongside log files and alerting systems, the API returns timestamps in two formats: `HH:MM:SS`, which is human-readable but includes no date information; `Unix epoch time`, which is machine-sortable and includes date information. The latter format is useful for cluster recoveries that take multiple days. You can use the cat health API to verify cluster health across multiple nodes. You also can use the API to track the recovery of a large cluster over a longer period of time. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-health.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-health | Elasticsearch API documentation} */ async health (this: That, params?: T.CatHealthRequest, options?: TransportRequestOptionsWithOutMeta): Promise async health (this: That, params?: T.CatHealthRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -335,7 +335,7 @@ export default class Cat { /** * Get CAT help. Get help for the CAT APIs. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-cat | Elasticsearch API documentation} */ async help (this: That, params?: T.CatHelpRequest, options?: TransportRequestOptionsWithOutMeta): Promise async help (this: That, params?: T.CatHelpRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -375,7 +375,7 @@ export default class Cat { /** * Get index information. Get high-level information about indices in a cluster, including backing indices for data streams. Use this request to get the following information for each index in a cluster: - shard count - document count - deleted document count - primary store size - total store size of all shards, including shard replicas These metrics are retrieved directly from Lucene, which Elasticsearch uses internally to power indexing and search. As a result, all document counts include hidden nested documents. To get an accurate count of Elasticsearch documents, use the cat count or count APIs. CAT APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use an index endpoint. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-indices.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-indices | Elasticsearch API documentation} */ async indices (this: That, params?: T.CatIndicesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async indices (this: That, params?: T.CatIndicesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -425,7 +425,7 @@ export default class Cat { /** * Get master node information. Get information about the master node, including the ID, bound IP address, and name. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the nodes info API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-master.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-master | Elasticsearch API documentation} */ async master (this: That, params?: T.CatMasterRequest, options?: TransportRequestOptionsWithOutMeta): Promise async master (this: That, params?: T.CatMasterRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -465,7 +465,7 @@ export default class Cat { /** * Get data frame analytics jobs. Get configuration and usage information about data frame analytics jobs. IMPORTANT: CAT APIs are only intended for human consumption using the Kibana console or command line. They are not intended for use by applications. For application consumption, use the get data frame analytics jobs statistics API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-dfanalytics.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-ml-data-frame-analytics | Elasticsearch API documentation} */ async mlDataFrameAnalytics (this: That, params?: T.CatMlDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async mlDataFrameAnalytics (this: That, params?: T.CatMlDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -515,7 +515,7 @@ export default class Cat { /** * Get datafeeds. Get configuration and usage information about datafeeds. This API returns a maximum of 10,000 datafeeds. If the Elasticsearch security features are enabled, you must have `monitor_ml`, `monitor`, `manage_ml`, or `manage` cluster privileges to use this API. IMPORTANT: CAT APIs are only intended for human consumption using the Kibana console or command line. They are not intended for use by applications. For application consumption, use the get datafeed statistics API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-datafeeds.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-ml-datafeeds | Elasticsearch API documentation} */ async mlDatafeeds (this: That, params?: T.CatMlDatafeedsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async mlDatafeeds (this: That, params?: T.CatMlDatafeedsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -565,7 +565,7 @@ export default class Cat { /** * Get anomaly detection jobs. Get configuration and usage information for anomaly detection jobs. This API returns a maximum of 10,000 jobs. If the Elasticsearch security features are enabled, you must have `monitor_ml`, `monitor`, `manage_ml`, or `manage` cluster privileges to use this API. IMPORTANT: CAT APIs are only intended for human consumption using the Kibana console or command line. They are not intended for use by applications. For application consumption, use the get anomaly detection job statistics API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-anomaly-detectors.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-ml-jobs | Elasticsearch API documentation} */ async mlJobs (this: That, params?: T.CatMlJobsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async mlJobs (this: That, params?: T.CatMlJobsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -615,7 +615,7 @@ export default class Cat { /** * Get trained models. Get configuration and usage information about inference trained models. IMPORTANT: CAT APIs are only intended for human consumption using the Kibana console or command line. They are not intended for use by applications. For application consumption, use the get trained models statistics API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-trained-model.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-ml-trained-models | Elasticsearch API documentation} */ async mlTrainedModels (this: That, params?: T.CatMlTrainedModelsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async mlTrainedModels (this: That, params?: T.CatMlTrainedModelsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -665,7 +665,7 @@ export default class Cat { /** * Get node attribute information. Get information about custom node attributes. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the nodes info API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-nodeattrs.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-nodeattrs | Elasticsearch API documentation} */ async nodeattrs (this: That, params?: T.CatNodeattrsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async nodeattrs (this: That, params?: T.CatNodeattrsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -705,7 +705,7 @@ export default class Cat { /** * Get node information. Get information about the nodes in a cluster. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the nodes info API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-nodes.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-nodes | Elasticsearch API documentation} */ async nodes (this: That, params?: T.CatNodesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async nodes (this: That, params?: T.CatNodesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -745,7 +745,7 @@ export default class Cat { /** * Get pending task information. Get information about cluster-level changes that have not yet taken effect. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the pending cluster tasks API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-pending-tasks.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-pending-tasks | Elasticsearch API documentation} */ async pendingTasks (this: That, params?: T.CatPendingTasksRequest, options?: TransportRequestOptionsWithOutMeta): Promise async pendingTasks (this: That, params?: T.CatPendingTasksRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -785,7 +785,7 @@ export default class Cat { /** * Get plugin information. Get a list of plugins running on each node of a cluster. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the nodes info API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-plugins.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-plugins | Elasticsearch API documentation} */ async plugins (this: That, params?: T.CatPluginsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async plugins (this: That, params?: T.CatPluginsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -825,7 +825,7 @@ export default class Cat { /** * Get shard recovery information. Get information about ongoing and completed shard recoveries. Shard recovery is the process of initializing a shard copy, such as restoring a primary shard from a snapshot or syncing a replica shard from a primary shard. When a shard recovery completes, the recovered shard is available for search and indexing. For data streams, the API returns information about the stream’s backing indices. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the index recovery API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-recovery.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-recovery | Elasticsearch API documentation} */ async recovery (this: That, params?: T.CatRecoveryRequest, options?: TransportRequestOptionsWithOutMeta): Promise async recovery (this: That, params?: T.CatRecoveryRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -875,7 +875,7 @@ export default class Cat { /** * Get snapshot repository information. Get a list of snapshot repositories for a cluster. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the get snapshot repository API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-repositories.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-repositories | Elasticsearch API documentation} */ async repositories (this: That, params?: T.CatRepositoriesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async repositories (this: That, params?: T.CatRepositoriesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -915,7 +915,7 @@ export default class Cat { /** * Get segment information. Get low-level information about the Lucene segments in index shards. For data streams, the API returns information about the backing indices. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the index segments API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-segments.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-segments | Elasticsearch API documentation} */ async segments (this: That, params?: T.CatSegmentsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async segments (this: That, params?: T.CatSegmentsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -965,7 +965,7 @@ export default class Cat { /** * Get shard information. Get information about the shards in a cluster. For data streams, the API returns information about the backing indices. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-shards.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-shards | Elasticsearch API documentation} */ async shards (this: That, params?: T.CatShardsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async shards (this: That, params?: T.CatShardsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1015,7 +1015,7 @@ export default class Cat { /** * Get snapshot information. Get information about the snapshots stored in one or more repositories. A snapshot is a backup of an index or running Elasticsearch cluster. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the get snapshot API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-snapshots.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-snapshots | Elasticsearch API documentation} */ async snapshots (this: That, params?: T.CatSnapshotsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async snapshots (this: That, params?: T.CatSnapshotsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1065,7 +1065,7 @@ export default class Cat { /** * Get task information. Get information about tasks currently running in the cluster. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the task management API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/tasks.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-tasks | Elasticsearch API documentation} */ async tasks (this: That, params?: T.CatTasksRequest, options?: TransportRequestOptionsWithOutMeta): Promise async tasks (this: That, params?: T.CatTasksRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1105,7 +1105,7 @@ export default class Cat { /** * Get index template information. Get information about the index templates in a cluster. You can use index templates to apply index settings and field mappings to new indices at creation. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the get index template API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-templates.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-templates | Elasticsearch API documentation} */ async templates (this: That, params?: T.CatTemplatesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async templates (this: That, params?: T.CatTemplatesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1155,7 +1155,7 @@ export default class Cat { /** * Get thread pool statistics. Get thread pool statistics for each node in a cluster. Returned information includes all built-in thread pools and custom thread pools. IMPORTANT: cat APIs are only intended for human consumption using the command line or Kibana console. They are not intended for use by applications. For application consumption, use the nodes info API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-thread-pool.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-thread-pool | Elasticsearch API documentation} */ async threadPool (this: That, params?: T.CatThreadPoolRequest, options?: TransportRequestOptionsWithOutMeta): Promise async threadPool (this: That, params?: T.CatThreadPoolRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1205,7 +1205,7 @@ export default class Cat { /** * Get transform information. Get configuration and usage information about transforms. CAT APIs are only intended for human consumption using the Kibana console or command line. They are not intended for use by applications. For application consumption, use the get transform statistics API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cat-transforms.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cat-transforms | Elasticsearch API documentation} */ async transforms (this: That, params?: T.CatTransformsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async transforms (this: That, params?: T.CatTransformsRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/ccr.ts b/src/api/api/ccr.ts index 3631d2dcb..29455527c 100644 --- a/src/api/api/ccr.ts +++ b/src/api/api/ccr.ts @@ -45,7 +45,7 @@ export default class Ccr { /** * Delete auto-follow patterns. Delete a collection of cross-cluster replication auto-follow patterns. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-delete-auto-follow-pattern.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-delete-auto-follow-pattern | Elasticsearch API documentation} */ async deleteAutoFollowPattern (this: That, params: T.CcrDeleteAutoFollowPatternRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteAutoFollowPattern (this: That, params: T.CcrDeleteAutoFollowPatternRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class Ccr { /** * Create a follower. Create a cross-cluster replication follower index that follows a specific leader index. When the API returns, the follower index exists and cross-cluster replication starts replicating operations from the leader index to the follower index. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-put-follow.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-follow | Elasticsearch API documentation} */ async follow (this: That, params: T.CcrFollowRequest, options?: TransportRequestOptionsWithOutMeta): Promise async follow (this: That, params: T.CcrFollowRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -134,7 +134,7 @@ export default class Ccr { /** * Get follower information. Get information about all cross-cluster replication follower indices. For example, the results include follower index names, leader index names, replication options, and whether the follower indices are active or paused. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-get-follow-info.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-follow-info | Elasticsearch API documentation} */ async followInfo (this: That, params: T.CcrFollowInfoRequest, options?: TransportRequestOptionsWithOutMeta): Promise async followInfo (this: That, params: T.CcrFollowInfoRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -176,7 +176,7 @@ export default class Ccr { /** * Get follower stats. Get cross-cluster replication follower stats. The API returns shard-level stats about the "following tasks" associated with each shard for the specified indices. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-get-follow-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-follow-stats | Elasticsearch API documentation} */ async followStats (this: That, params: T.CcrFollowStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async followStats (this: That, params: T.CcrFollowStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -218,7 +218,7 @@ export default class Ccr { /** * Forget a follower. Remove the cross-cluster replication follower retention leases from the leader. A following index takes out retention leases on its leader index. These leases are used to increase the likelihood that the shards of the leader index retain the history of operations that the shards of the following index need to run replication. When a follower index is converted to a regular index by the unfollow API (either by directly calling the API or by index lifecycle management tasks), these leases are removed. However, removal of the leases can fail, for example when the remote cluster containing the leader index is unavailable. While the leases will eventually expire on their own, their extended existence can cause the leader index to hold more history than necessary and prevent index lifecycle management from performing some operations on the leader index. This API exists to enable manually removing the leases when the unfollow API is unable to do so. NOTE: This API does not stop replication by a following index. If you use this API with a follower index that is still actively following, the following index will add back retention leases on the leader. The only purpose of this API is to handle the case of failure to remove the following retention leases after the unfollow API is invoked. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-post-forget-follower.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-forget-follower | Elasticsearch API documentation} */ async forgetFollower (this: That, params: T.CcrForgetFollowerRequest, options?: TransportRequestOptionsWithOutMeta): Promise async forgetFollower (this: That, params: T.CcrForgetFollowerRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -265,7 +265,7 @@ export default class Ccr { /** * Get auto-follow patterns. Get cross-cluster replication auto-follow patterns. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-get-auto-follow-pattern.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-get-auto-follow-pattern-1 | Elasticsearch API documentation} */ async getAutoFollowPattern (this: That, params?: T.CcrGetAutoFollowPatternRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getAutoFollowPattern (this: That, params?: T.CcrGetAutoFollowPatternRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -315,7 +315,7 @@ export default class Ccr { /** * Pause an auto-follow pattern. Pause a cross-cluster replication auto-follow pattern. When the API returns, the auto-follow pattern is inactive. New indices that are created on the remote cluster and match the auto-follow patterns are ignored. You can resume auto-following with the resume auto-follow pattern API. When it resumes, the auto-follow pattern is active again and automatically configures follower indices for newly created indices on the remote cluster that match its patterns. Remote indices that were created while the pattern was paused will also be followed, unless they have been deleted or closed in the interim. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-pause-auto-follow-pattern.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-pause-auto-follow-pattern | Elasticsearch API documentation} */ async pauseAutoFollowPattern (this: That, params: T.CcrPauseAutoFollowPatternRequest, options?: TransportRequestOptionsWithOutMeta): Promise async pauseAutoFollowPattern (this: That, params: T.CcrPauseAutoFollowPatternRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -357,7 +357,7 @@ export default class Ccr { /** * Pause a follower. Pause a cross-cluster replication follower index. The follower index will not fetch any additional operations from the leader index. You can resume following with the resume follower API. You can pause and resume a follower index to change the configuration of the following task. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-post-pause-follow.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-pause-follow | Elasticsearch API documentation} */ async pauseFollow (this: That, params: T.CcrPauseFollowRequest, options?: TransportRequestOptionsWithOutMeta): Promise async pauseFollow (this: That, params: T.CcrPauseFollowRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -399,7 +399,7 @@ export default class Ccr { /** * Create or update auto-follow patterns. Create a collection of cross-cluster replication auto-follow patterns for a remote cluster. Newly created indices on the remote cluster that match any of the patterns are automatically configured as follower indices. Indices on the remote cluster that were created before the auto-follow pattern was created will not be auto-followed even if they match the pattern. This API can also be used to update auto-follow patterns. NOTE: Follower indices that were configured automatically before updating an auto-follow pattern will remain unchanged even if they do not match against the new patterns. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-put-auto-follow-pattern.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-put-auto-follow-pattern | Elasticsearch API documentation} */ async putAutoFollowPattern (this: That, params: T.CcrPutAutoFollowPatternRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putAutoFollowPattern (this: That, params: T.CcrPutAutoFollowPatternRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -446,7 +446,7 @@ export default class Ccr { /** * Resume an auto-follow pattern. Resume a cross-cluster replication auto-follow pattern that was paused. The auto-follow pattern will resume configuring following indices for newly created indices that match its patterns on the remote cluster. Remote indices created while the pattern was paused will also be followed unless they have been deleted or closed in the interim. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-resume-auto-follow-pattern.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-resume-auto-follow-pattern | Elasticsearch API documentation} */ async resumeAutoFollowPattern (this: That, params: T.CcrResumeAutoFollowPatternRequest, options?: TransportRequestOptionsWithOutMeta): Promise async resumeAutoFollowPattern (this: That, params: T.CcrResumeAutoFollowPatternRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -488,7 +488,7 @@ export default class Ccr { /** * Resume a follower. Resume a cross-cluster replication follower index that was paused. The follower index could have been paused with the pause follower API. Alternatively it could be paused due to replication that cannot be retried due to failures during following tasks. When this API returns, the follower index will resume fetching operations from the leader index. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-post-resume-follow.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-resume-follow | Elasticsearch API documentation} */ async resumeFollow (this: That, params: T.CcrResumeFollowRequest, options?: TransportRequestOptionsWithOutMeta): Promise async resumeFollow (this: That, params: T.CcrResumeFollowRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -535,7 +535,7 @@ export default class Ccr { /** * Get cross-cluster replication stats. This API returns stats about auto-following and the same shard-level stats as the get follower stats API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-get-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-stats | Elasticsearch API documentation} */ async stats (this: That, params?: T.CcrStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stats (this: That, params?: T.CcrStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -574,8 +574,8 @@ export default class Ccr { } /** - * Unfollow an index. Convert a cross-cluster replication follower index to a regular index. The API stops the following task associated with a follower index and removes index metadata and settings associated with cross-cluster replication. The follower index must be paused and closed before you call the unfollow API. NOTE: Currently cross-cluster replication does not support converting an existing regular index to a follower index. Converting a follower index to a regular index is an irreversible operation. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ccr-post-unfollow.html | Elasticsearch API documentation} + * Unfollow an index. Convert a cross-cluster replication follower index to a regular index. The API stops the following task associated with a follower index and removes index metadata and settings associated with cross-cluster replication. The follower index must be paused and closed before you call the unfollow API. > info > Currently cross-cluster replication does not support converting an existing regular index to a follower index. Converting a follower index to a regular index is an irreversible operation. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ccr-unfollow | Elasticsearch API documentation} */ async unfollow (this: That, params: T.CcrUnfollowRequest, options?: TransportRequestOptionsWithOutMeta): Promise async unfollow (this: That, params: T.CcrUnfollowRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/clear_scroll.ts b/src/api/api/clear_scroll.ts index 5fab83bb9..7b7258503 100644 --- a/src/api/api/clear_scroll.ts +++ b/src/api/api/clear_scroll.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Clear a scrolling search. Clear the search context and results for a scrolling search. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/clear-scroll-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-clear-scroll | Elasticsearch API documentation} */ export default async function ClearScrollApi (this: That, params?: T.ClearScrollRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function ClearScrollApi (this: That, params?: T.ClearScrollRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/close_point_in_time.ts b/src/api/api/close_point_in_time.ts index 52334debe..26d5b0e26 100644 --- a/src/api/api/close_point_in_time.ts +++ b/src/api/api/close_point_in_time.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Close a point in time. A point in time must be opened explicitly before being used in search requests. The `keep_alive` parameter tells Elasticsearch how long it should persist. A point in time is automatically closed when the `keep_alive` period has elapsed. However, keeping points in time has a cost; close them as soon as they are no longer required for search requests. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/point-in-time-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-open-point-in-time | Elasticsearch API documentation} */ export default async function ClosePointInTimeApi (this: That, params: T.ClosePointInTimeRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function ClosePointInTimeApi (this: That, params: T.ClosePointInTimeRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/cluster.ts b/src/api/api/cluster.ts index 9da8711f1..730c942d2 100644 --- a/src/api/api/cluster.ts +++ b/src/api/api/cluster.ts @@ -45,7 +45,7 @@ export default class Cluster { /** * Explain the shard allocations. Get explanations for shard allocations in the cluster. For unassigned shards, it provides an explanation for why the shard is unassigned. For assigned shards, it provides an explanation for why the shard is remaining on its current node and has not moved or rebalanced to another node. This API can be very useful when attempting to diagnose why a shard is unassigned or why a shard continues to remain on its current node when you might expect otherwise. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-allocation-explain.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-allocation-explain | Elasticsearch API documentation} */ async allocationExplain (this: That, params?: T.ClusterAllocationExplainRequest, options?: TransportRequestOptionsWithOutMeta): Promise async allocationExplain (this: That, params?: T.ClusterAllocationExplainRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -90,7 +90,7 @@ export default class Cluster { /** * Delete component templates. Component templates are building blocks for constructing index templates that specify index mappings, settings, and aliases. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-component-template.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-put-component-template | Elasticsearch API documentation} */ async deleteComponentTemplate (this: That, params: T.ClusterDeleteComponentTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteComponentTemplate (this: That, params: T.ClusterDeleteComponentTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -132,7 +132,7 @@ export default class Cluster { /** * Clear cluster voting config exclusions. Remove master-eligible nodes from the voting configuration exclusion list. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/voting-config-exclusions.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-post-voting-config-exclusions | Elasticsearch API documentation} */ async deleteVotingConfigExclusions (this: That, params?: T.ClusterDeleteVotingConfigExclusionsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteVotingConfigExclusions (this: That, params?: T.ClusterDeleteVotingConfigExclusionsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -172,7 +172,7 @@ export default class Cluster { /** * Check component templates. Returns information about whether a particular component template exists. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-component-template.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-put-component-template | Elasticsearch API documentation} */ async existsComponentTemplate (this: That, params: T.ClusterExistsComponentTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async existsComponentTemplate (this: That, params: T.ClusterExistsComponentTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -214,7 +214,7 @@ export default class Cluster { /** * Get component templates. Get information about component templates. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-component-template.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-put-component-template | Elasticsearch API documentation} */ async getComponentTemplate (this: That, params?: T.ClusterGetComponentTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getComponentTemplate (this: That, params?: T.ClusterGetComponentTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -264,7 +264,7 @@ export default class Cluster { /** * Get cluster-wide settings. By default, it returns only settings that have been explicitly defined. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-get-settings.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-get-settings | Elasticsearch API documentation} */ async getSettings (this: That, params?: T.ClusterGetSettingsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getSettings (this: That, params?: T.ClusterGetSettingsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -304,7 +304,7 @@ export default class Cluster { /** * Get the cluster health status. You can also use the API to get the health status of only specified data streams and indices. For data streams, the API retrieves the health status of the stream’s backing indices. The cluster health status is: green, yellow or red. On the shard level, a red status indicates that the specific shard is not allocated in the cluster. Yellow means that the primary shard is allocated but replicas are not. Green means that all shards are allocated. The index level status is controlled by the worst shard status. One of the main benefits of the API is the ability to wait until the cluster reaches a certain high watermark health level. The cluster status is controlled by the worst index status. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-health.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-health | Elasticsearch API documentation} */ async health (this: That, params?: T.ClusterHealthRequest, options?: TransportRequestOptionsWithOutMeta): Promise async health (this: That, params?: T.ClusterHealthRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -354,7 +354,7 @@ export default class Cluster { /** * Get cluster info. Returns basic information about the cluster. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-info.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-info | Elasticsearch API documentation} */ async info (this: That, params: T.ClusterInfoRequest, options?: TransportRequestOptionsWithOutMeta): Promise async info (this: That, params: T.ClusterInfoRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -396,7 +396,7 @@ export default class Cluster { /** * Get the pending cluster tasks. Get information about cluster-level changes (such as create index, update mapping, allocate or fail shard) that have not yet taken effect. NOTE: This API returns a list of any pending updates to the cluster state. These are distinct from the tasks reported by the task management API which include periodic tasks and tasks initiated by the user, such as node stats, search queries, or create index requests. However, if a user-initiated task such as a create index command causes a cluster state update, the activity of this task might be reported by both task api and pending cluster tasks API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-pending.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-pending-tasks | Elasticsearch API documentation} */ async pendingTasks (this: That, params?: T.ClusterPendingTasksRequest, options?: TransportRequestOptionsWithOutMeta): Promise async pendingTasks (this: That, params?: T.ClusterPendingTasksRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -436,7 +436,7 @@ export default class Cluster { /** * Update voting configuration exclusions. Update the cluster voting config exclusions by node IDs or node names. By default, if there are more than three master-eligible nodes in the cluster and you remove fewer than half of the master-eligible nodes in the cluster at once, the voting configuration automatically shrinks. If you want to shrink the voting configuration to contain fewer than three nodes or to remove half or more of the master-eligible nodes in the cluster at once, use this API to remove departing nodes from the voting configuration manually. The API adds an entry for each specified node to the cluster’s voting configuration exclusions list. It then waits until the cluster has reconfigured its voting configuration to exclude the specified nodes. Clusters should have no voting configuration exclusions in normal operation. Once the excluded nodes have stopped, clear the voting configuration exclusions with `DELETE /_cluster/voting_config_exclusions`. This API waits for the nodes to be fully removed from the cluster before it returns. If your cluster has voting configuration exclusions for nodes that you no longer intend to remove, use `DELETE /_cluster/voting_config_exclusions?wait_for_removal=false` to clear the voting configuration exclusions without waiting for the nodes to leave the cluster. A response to `POST /_cluster/voting_config_exclusions` with an HTTP status code of 200 OK guarantees that the node has been removed from the voting configuration and will not be reinstated until the voting configuration exclusions are cleared by calling `DELETE /_cluster/voting_config_exclusions`. If the call to `POST /_cluster/voting_config_exclusions` fails or returns a response with an HTTP status code other than 200 OK then the node may not have been removed from the voting configuration. In that case, you may safely retry the call. NOTE: Voting exclusions are required only when you remove at least half of the master-eligible nodes from a cluster in a short time period. They are not required when removing master-ineligible nodes or when removing fewer than half of the master-eligible nodes. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/voting-config-exclusions.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-post-voting-config-exclusions | Elasticsearch API documentation} */ async postVotingConfigExclusions (this: That, params?: T.ClusterPostVotingConfigExclusionsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async postVotingConfigExclusions (this: That, params?: T.ClusterPostVotingConfigExclusionsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -476,7 +476,7 @@ export default class Cluster { /** * Create or update a component template. Component templates are building blocks for constructing index templates that specify index mappings, settings, and aliases. An index template can be composed of multiple component templates. To use a component template, specify it in an index template’s `composed_of` list. Component templates are only applied to new data streams and indices as part of a matching index template. Settings and mappings specified directly in the index template or the create index request override any settings or mappings specified in a component template. Component templates are only used during index creation. For data streams, this includes data stream creation and the creation of a stream’s backing indices. Changes to component templates do not affect existing indices, including a stream’s backing indices. You can use C-style `/* *\/` block comments in component templates. You can include comments anywhere in the request body except before the opening curly bracket. **Applying component templates** You cannot directly apply a component template to a data stream or index. To be applied, a component template must be included in an index template's `composed_of` list. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-component-template.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-put-component-template | Elasticsearch API documentation} */ async putComponentTemplate (this: That, params: T.ClusterPutComponentTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putComponentTemplate (this: That, params: T.ClusterPutComponentTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -523,7 +523,7 @@ export default class Cluster { /** * Update the cluster settings. Configure and update dynamic settings on a running cluster. You can also configure dynamic settings locally on an unstarted or shut down node in `elasticsearch.yml`. Updates made with this API can be persistent, which apply across cluster restarts, or transient, which reset after a cluster restart. You can also reset transient or persistent settings by assigning them a null value. If you configure the same setting using multiple methods, Elasticsearch applies the settings in following order of precedence: 1) Transient setting; 2) Persistent setting; 3) `elasticsearch.yml` setting; 4) Default setting value. For example, you can apply a transient setting to override a persistent setting or `elasticsearch.yml` setting. However, a change to an `elasticsearch.yml` setting will not override a defined transient or persistent setting. TIP: In Elastic Cloud, use the user settings feature to configure all cluster settings. This method automatically rejects unsafe settings that could break your cluster. If you run Elasticsearch on your own hardware, use this API to configure dynamic cluster settings. Only use `elasticsearch.yml` for static cluster settings and node settings. The API doesn’t require a restart and ensures a setting’s value is the same on all nodes. WARNING: Transient cluster settings are no longer recommended. Use persistent cluster settings instead. If a cluster becomes unstable, transient settings can clear unexpectedly, resulting in a potentially undesired cluster configuration. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-update-settings.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-put-settings | Elasticsearch API documentation} */ async putSettings (this: That, params?: T.ClusterPutSettingsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putSettings (this: That, params?: T.ClusterPutSettingsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -567,8 +567,8 @@ export default class Cluster { } /** - * Get remote cluster information. Get all of the configured remote cluster information. This API returns connection and endpoint information keyed by the configured remote cluster alias. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-remote-info.html | Elasticsearch API documentation} + * Get remote cluster information. Get information about configured remote clusters. The API returns connection and endpoint information keyed by the configured remote cluster alias. > info > This API returns information that reflects current state on the local cluster. > The `connected` field does not necessarily reflect whether a remote cluster is down or unavailable, only whether there is currently an open connection to it. > Elasticsearch does not spontaneously try to reconnect to a disconnected remote cluster. > To trigger a reconnection, attempt a cross-cluster search, ES|QL cross-cluster search, or try the [resolve cluster endpoint](https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-resolve-cluster). + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-remote-info | Elasticsearch API documentation} */ async remoteInfo (this: That, params?: T.ClusterRemoteInfoRequest, options?: TransportRequestOptionsWithOutMeta): Promise async remoteInfo (this: That, params?: T.ClusterRemoteInfoRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -608,7 +608,7 @@ export default class Cluster { /** * Reroute the cluster. Manually change the allocation of individual shards in the cluster. For example, a shard can be moved from one node to another explicitly, an allocation can be canceled, and an unassigned shard can be explicitly allocated to a specific node. It is important to note that after processing any reroute commands Elasticsearch will perform rebalancing as normal (respecting the values of settings such as `cluster.routing.rebalance.enable`) in order to remain in a balanced state. For example, if the requested allocation includes moving a shard from node1 to node2 then this may cause a shard to be moved from node2 back to node1 to even things out. The cluster can be set to disable allocations using the `cluster.routing.allocation.enable` setting. If allocations are disabled then the only allocations that will be performed are explicit ones given using the reroute command, and consequent allocations due to rebalancing. The cluster will attempt to allocate a shard a maximum of `index.allocation.max_retries` times in a row (defaults to `5`), before giving up and leaving the shard unallocated. This scenario can be caused by structural problems such as having an analyzer which refers to a stopwords file which doesn’t exist on all nodes. Once the problem has been corrected, allocation can be manually retried by calling the reroute API with the `?retry_failed` URI query parameter, which will attempt a single retry round for these shards. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-reroute.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-reroute | Elasticsearch API documentation} */ async reroute (this: That, params?: T.ClusterRerouteRequest, options?: TransportRequestOptionsWithOutMeta): Promise async reroute (this: That, params?: T.ClusterRerouteRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -653,7 +653,7 @@ export default class Cluster { /** * Get the cluster state. Get comprehensive information about the state of the cluster. The cluster state is an internal data structure which keeps track of a variety of information needed by every node, including the identity and attributes of the other nodes in the cluster; cluster-wide settings; index metadata, including the mapping and settings for each index; the location and status of every shard copy in the cluster. The elected master node ensures that every node in the cluster has a copy of the same cluster state. This API lets you retrieve a representation of this internal state for debugging or diagnostic purposes. You may need to consult the Elasticsearch source code to determine the precise meaning of the response. By default the API will route requests to the elected master node since this node is the authoritative source of cluster states. You can also retrieve the cluster state held on the node handling the API request by adding the `?local=true` query parameter. Elasticsearch may need to expend significant effort to compute a response to this API in larger clusters, and the response may comprise a very large quantity of data. If you use this API repeatedly, your cluster may become unstable. WARNING: The response is a representation of an internal data structure. Its format is not subject to the same compatibility guarantees as other more stable APIs and may change from version to version. Do not query this API using external monitoring tools. Instead, obtain the information you require using other more stable cluster APIs. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-state.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-state | Elasticsearch API documentation} */ async state (this: That, params?: T.ClusterStateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async state (this: That, params?: T.ClusterStateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -707,7 +707,7 @@ export default class Cluster { /** * Get cluster statistics. Get basic index metrics (shard numbers, store size, memory usage) and information about the current nodes that form the cluster (number, roles, os, jvm versions, memory usage, cpu and installed plugins). - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-stats | Elasticsearch API documentation} */ async stats (this: That, params?: T.ClusterStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stats (this: That, params?: T.ClusterStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/connector.ts b/src/api/api/connector.ts index a181384b2..141aa8002 100644 --- a/src/api/api/connector.ts +++ b/src/api/api/connector.ts @@ -45,7 +45,7 @@ export default class Connector { /** * Check in a connector. Update the `last_seen` field in the connector and set it to the current timestamp. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/check-in-connector-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-check-in | Elasticsearch API documentation} */ async checkIn (this: That, params: T.ConnectorCheckInRequest, options?: TransportRequestOptionsWithOutMeta): Promise async checkIn (this: That, params: T.ConnectorCheckInRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class Connector { /** * Delete a connector. Removes a connector and associated sync jobs. This is a destructive action that is not recoverable. NOTE: This action doesn’t delete any API keys, ingest pipelines, or data indices associated with the connector. These need to be removed manually. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-connector-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-delete | Elasticsearch API documentation} */ async delete (this: That, params: T.ConnectorDeleteRequest, options?: TransportRequestOptionsWithOutMeta): Promise async delete (this: That, params: T.ConnectorDeleteRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -129,7 +129,7 @@ export default class Connector { /** * Get a connector. Get the details about a connector. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-connector-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-get | Elasticsearch API documentation} */ async get (this: That, params: T.ConnectorGetRequest, options?: TransportRequestOptionsWithOutMeta): Promise async get (this: That, params: T.ConnectorGetRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -171,7 +171,7 @@ export default class Connector { /** * Update the connector last sync stats. Update the fields related to the last sync of a connector. This action is used for analytics and monitoring. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-connector-last-sync-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-last-sync | Elasticsearch API documentation} */ async lastSync (this: That, params: T.ConnectorLastSyncRequest, options?: TransportRequestOptionsWithOutMeta): Promise async lastSync (this: That, params: T.ConnectorLastSyncRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -218,7 +218,7 @@ export default class Connector { /** * Get all connectors. Get information about all connectors. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/list-connector-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-list | Elasticsearch API documentation} */ async list (this: That, params?: T.ConnectorListRequest, options?: TransportRequestOptionsWithOutMeta): Promise async list (this: That, params?: T.ConnectorListRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -258,7 +258,7 @@ export default class Connector { /** * Create a connector. Connectors are Elasticsearch integrations that bring content from third-party data sources, which can be deployed on Elastic Cloud or hosted on your own infrastructure. Elastic managed connectors (Native connectors) are a managed service on Elastic Cloud. Self-managed connectors (Connector clients) are self-managed on your infrastructure. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/create-connector-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-put | Elasticsearch API documentation} */ async post (this: That, params?: T.ConnectorPostRequest, options?: TransportRequestOptionsWithOutMeta): Promise async post (this: That, params?: T.ConnectorPostRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -303,7 +303,7 @@ export default class Connector { /** * Create or update a connector. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/create-connector-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-put | Elasticsearch API documentation} */ async put (this: That, params?: T.ConnectorPutRequest, options?: TransportRequestOptionsWithOutMeta): Promise async put (this: That, params?: T.ConnectorPutRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -519,7 +519,7 @@ export default class Connector { /** * Cancel a connector sync job. Cancel a connector sync job, which sets the status to cancelling and updates `cancellation_requested_at` to the current time. The connector service is then responsible for setting the status of connector sync jobs to cancelled. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cancel-connector-sync-job-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-cancel | Elasticsearch API documentation} */ async syncJobCancel (this: That, params: T.ConnectorSyncJobCancelRequest, options?: TransportRequestOptionsWithOutMeta): Promise async syncJobCancel (this: That, params: T.ConnectorSyncJobCancelRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -561,7 +561,7 @@ export default class Connector { /** * Check in a connector sync job. Check in a connector sync job and set the `last_seen` field to the current time before updating it in the internal index. To sync data using self-managed connectors, you need to deploy the Elastic connector service on your own infrastructure. This service runs automatically on Elastic Cloud for Elastic managed connectors. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/check-in-connector-sync-job-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-check-in | Elasticsearch API documentation} */ async syncJobCheckIn (this: That, params: T.ConnectorSyncJobCheckInRequest, options?: TransportRequestOptionsWithOutMeta): Promise async syncJobCheckIn (this: That, params: T.ConnectorSyncJobCheckInRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -603,7 +603,7 @@ export default class Connector { /** * Claim a connector sync job. This action updates the job status to `in_progress` and sets the `last_seen` and `started_at` timestamps to the current time. Additionally, it can set the `sync_cursor` property for the sync job. This API is not intended for direct connector management by users. It supports the implementation of services that utilize the connector protocol to communicate with Elasticsearch. To sync data using self-managed connectors, you need to deploy the Elastic connector service on your own infrastructure. This service runs automatically on Elastic Cloud for Elastic managed connectors. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/claim-connector-sync-job-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-claim | Elasticsearch API documentation} */ async syncJobClaim (this: That, params: T.ConnectorSyncJobClaimRequest, options?: TransportRequestOptionsWithOutMeta): Promise async syncJobClaim (this: That, params: T.ConnectorSyncJobClaimRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -650,7 +650,7 @@ export default class Connector { /** * Delete a connector sync job. Remove a connector sync job and its associated data. This is a destructive action that is not recoverable. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-connector-sync-job-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-delete | Elasticsearch API documentation} */ async syncJobDelete (this: That, params: T.ConnectorSyncJobDeleteRequest, options?: TransportRequestOptionsWithOutMeta): Promise async syncJobDelete (this: That, params: T.ConnectorSyncJobDeleteRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -692,7 +692,7 @@ export default class Connector { /** * Set a connector sync job error. Set the `error` field for a connector sync job and set its `status` to `error`. To sync data using self-managed connectors, you need to deploy the Elastic connector service on your own infrastructure. This service runs automatically on Elastic Cloud for Elastic managed connectors. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/set-connector-sync-job-error-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-error | Elasticsearch API documentation} */ async syncJobError (this: That, params: T.ConnectorSyncJobErrorRequest, options?: TransportRequestOptionsWithOutMeta): Promise async syncJobError (this: That, params: T.ConnectorSyncJobErrorRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -739,7 +739,7 @@ export default class Connector { /** * Get a connector sync job. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-connector-sync-job-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-get | Elasticsearch API documentation} */ async syncJobGet (this: That, params: T.ConnectorSyncJobGetRequest, options?: TransportRequestOptionsWithOutMeta): Promise async syncJobGet (this: That, params: T.ConnectorSyncJobGetRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -781,7 +781,7 @@ export default class Connector { /** * Get all connector sync jobs. Get information about all stored connector sync jobs listed by their creation date in ascending order. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/list-connector-sync-jobs-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-list | Elasticsearch API documentation} */ async syncJobList (this: That, params?: T.ConnectorSyncJobListRequest, options?: TransportRequestOptionsWithOutMeta): Promise async syncJobList (this: That, params?: T.ConnectorSyncJobListRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -821,7 +821,7 @@ export default class Connector { /** * Create a connector sync job. Create a connector sync job document in the internal index and initialize its counters and timestamps with default values. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/create-connector-sync-job-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-post | Elasticsearch API documentation} */ async syncJobPost (this: That, params: T.ConnectorSyncJobPostRequest, options?: TransportRequestOptionsWithOutMeta): Promise async syncJobPost (this: That, params: T.ConnectorSyncJobPostRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -865,7 +865,7 @@ export default class Connector { /** * Set the connector sync job stats. Stats include: `deleted_document_count`, `indexed_document_count`, `indexed_document_volume`, and `total_document_count`. You can also update `last_seen`. This API is mainly used by the connector service for updating sync job information. To sync data using self-managed connectors, you need to deploy the Elastic connector service on your own infrastructure. This service runs automatically on Elastic Cloud for Elastic managed connectors. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/set-connector-sync-job-stats-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-sync-job-update-stats | Elasticsearch API documentation} */ async syncJobUpdateStats (this: That, params: T.ConnectorSyncJobUpdateStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async syncJobUpdateStats (this: That, params: T.ConnectorSyncJobUpdateStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -912,7 +912,7 @@ export default class Connector { /** * Activate the connector draft filter. Activates the valid draft filtering for a connector. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-connector-filtering-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-filtering | Elasticsearch API documentation} */ async updateActiveFiltering (this: That, params: T.ConnectorUpdateActiveFilteringRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateActiveFiltering (this: That, params: T.ConnectorUpdateActiveFilteringRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -954,7 +954,7 @@ export default class Connector { /** * Update the connector API key ID. Update the `api_key_id` and `api_key_secret_id` fields of a connector. You can specify the ID of the API key used for authorization and the ID of the connector secret where the API key is stored. The connector secret ID is required only for Elastic managed (native) connectors. Self-managed connectors (connector clients) do not use this field. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-connector-api-key-id-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-api-key-id | Elasticsearch API documentation} */ async updateApiKeyId (this: That, params: T.ConnectorUpdateApiKeyIdRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateApiKeyId (this: That, params: T.ConnectorUpdateApiKeyIdRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1001,7 +1001,7 @@ export default class Connector { /** * Update the connector configuration. Update the configuration field in the connector document. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-connector-configuration-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-configuration | Elasticsearch API documentation} */ async updateConfiguration (this: That, params: T.ConnectorUpdateConfigurationRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateConfiguration (this: That, params: T.ConnectorUpdateConfigurationRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1048,7 +1048,7 @@ export default class Connector { /** * Update the connector error field. Set the error field for the connector. If the error provided in the request body is non-null, the connector’s status is updated to error. Otherwise, if the error is reset to null, the connector status is updated to connected. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-connector-error-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-error | Elasticsearch API documentation} */ async updateError (this: That, params: T.ConnectorUpdateErrorRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateError (this: That, params: T.ConnectorUpdateErrorRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1095,7 +1095,7 @@ export default class Connector { /** * Update the connector features. Update the connector features in the connector document. This API can be used to control the following aspects of a connector: * document-level security * incremental syncs * advanced sync rules * basic sync rules Normally, the running connector service automatically manages these features. However, you can use this API to override the default behavior. To sync data using self-managed connectors, you need to deploy the Elastic connector service on your own infrastructure. This service runs automatically on Elastic Cloud for Elastic managed connectors. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-connector-features-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-features | Elasticsearch API documentation} */ async updateFeatures (this: That, params: T.ConnectorUpdateFeaturesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateFeatures (this: That, params: T.ConnectorUpdateFeaturesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1142,7 +1142,7 @@ export default class Connector { /** * Update the connector filtering. Update the draft filtering configuration of a connector and marks the draft validation state as edited. The filtering draft is activated once validated by the running Elastic connector service. The filtering property is used to configure sync rules (both basic and advanced) for a connector. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-connector-filtering-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-filtering | Elasticsearch API documentation} */ async updateFiltering (this: That, params: T.ConnectorUpdateFilteringRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateFiltering (this: That, params: T.ConnectorUpdateFilteringRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1236,7 +1236,7 @@ export default class Connector { /** * Update the connector index name. Update the `index_name` field of a connector, specifying the index where the data ingested by the connector is stored. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-connector-index-name-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-index-name | Elasticsearch API documentation} */ async updateIndexName (this: That, params: T.ConnectorUpdateIndexNameRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateIndexName (this: That, params: T.ConnectorUpdateIndexNameRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1283,7 +1283,7 @@ export default class Connector { /** * Update the connector name and description. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-connector-name-description-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-name | Elasticsearch API documentation} */ async updateName (this: That, params: T.ConnectorUpdateNameRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateName (this: That, params: T.ConnectorUpdateNameRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1377,7 +1377,7 @@ export default class Connector { /** * Update the connector pipeline. When you create a new connector, the configuration of an ingest pipeline is populated with default settings. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-connector-pipeline-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-pipeline | Elasticsearch API documentation} */ async updatePipeline (this: That, params: T.ConnectorUpdatePipelineRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updatePipeline (this: That, params: T.ConnectorUpdatePipelineRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1424,7 +1424,7 @@ export default class Connector { /** * Update the connector scheduling. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-connector-scheduling-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-scheduling | Elasticsearch API documentation} */ async updateScheduling (this: That, params: T.ConnectorUpdateSchedulingRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateScheduling (this: That, params: T.ConnectorUpdateSchedulingRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1471,7 +1471,7 @@ export default class Connector { /** * Update the connector service type. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-connector-service-type-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-service-type | Elasticsearch API documentation} */ async updateServiceType (this: That, params: T.ConnectorUpdateServiceTypeRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateServiceType (this: That, params: T.ConnectorUpdateServiceTypeRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1518,7 +1518,7 @@ export default class Connector { /** * Update the connector status. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-connector-status-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-connector-update-status | Elasticsearch API documentation} */ async updateStatus (this: That, params: T.ConnectorUpdateStatusRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateStatus (this: That, params: T.ConnectorUpdateStatusRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/count.ts b/src/api/api/count.ts index 9370a8928..6e060b369 100644 --- a/src/api/api/count.ts +++ b/src/api/api/count.ts @@ -38,8 +38,8 @@ import * as T from '../types' interface That { transport: Transport } /** - * Count search results. Get the number of documents matching a query. The query can either be provided using a simple query string as a parameter or using the Query DSL defined within the request body. The latter must be nested in a `query` key, which is the same as the search API. The count API supports multi-target syntax. You can run a single count API search across multiple data streams and indices. The operation is broadcast across all shards. For each shard ID group, a replica is chosen and the search is run against it. This means that replicas increase the scalability of the count. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-count.html | Elasticsearch API documentation} + * Count search results. Get the number of documents matching a query. The query can be provided either by using a simple query string as a parameter, or by defining Query DSL within the request body. The query is optional. When no query is provided, the API uses `match_all` to count all the documents. The count API supports multi-target syntax. You can run a single count API search across multiple data streams and indices. The operation is broadcast across all shards. For each shard ID group, a replica is chosen and the search is run against it. This means that replicas increase the scalability of the count. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-count | Elasticsearch API documentation} */ export default async function CountApi (this: That, params?: T.CountRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function CountApi (this: That, params?: T.CountRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/create.ts b/src/api/api/create.ts index 6d46dec88..c8c663fa3 100644 --- a/src/api/api/create.ts +++ b/src/api/api/create.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Create a new document in the index. You can index a new JSON document with the `//_doc/` or `//_create/<_id>` APIs Using `_create` guarantees that the document is indexed only if it does not already exist. It returns a 409 response when a document with a same ID already exists in the index. To update an existing document, you must use the `//_doc/` API. If the Elasticsearch security features are enabled, you must have the following index privileges for the target data stream, index, or index alias: * To add a document using the `PUT //_create/<_id>` or `POST //_create/<_id>` request formats, you must have the `create_doc`, `create`, `index`, or `write` index privilege. * To automatically create a data stream or index with this API request, you must have the `auto_configure`, `create_index`, or `manage` index privilege. Automatic data stream creation requires a matching index template with data stream enabled. **Automatically create data streams and indices** If the request's target doesn't exist and matches an index template with a `data_stream` definition, the index operation automatically creates the data stream. If the target doesn't exist and doesn't match a data stream template, the operation automatically creates the index and applies any matching index templates. NOTE: Elasticsearch includes several built-in index templates. To avoid naming collisions with these templates, refer to index pattern documentation. If no mapping exists, the index operation creates a dynamic mapping. By default, new fields and objects are automatically added to the mapping if needed. Automatic index creation is controlled by the `action.auto_create_index` setting. If it is `true`, any index can be created automatically. You can modify this setting to explicitly allow or block automatic creation of indices that match specified patterns or set it to `false` to turn off automatic index creation entirely. Specify a comma-separated list of patterns you want to allow or prefix each pattern with `+` or `-` to indicate whether it should be allowed or blocked. When a list is specified, the default behaviour is to disallow. NOTE: The `action.auto_create_index` setting affects the automatic creation of indices only. It does not affect the creation of data streams. **Routing** By default, shard placement — or routing — is controlled by using a hash of the document's ID value. For more explicit control, the value fed into the hash function used by the router can be directly specified on a per-operation basis using the `routing` parameter. When setting up explicit mapping, you can also use the `_routing` field to direct the index operation to extract the routing value from the document itself. This does come at the (very minimal) cost of an additional document parsing pass. If the `_routing` mapping is defined and set to be required, the index operation will fail if no routing value is provided or extracted. NOTE: Data streams do not support custom routing unless they were created with the `allow_custom_routing` setting enabled in the template. **Distributed** The index operation is directed to the primary shard based on its route and performed on the actual node containing this shard. After the primary shard completes the operation, if needed, the update is distributed to applicable replicas. **Active shards** To improve the resiliency of writes to the system, indexing operations can be configured to wait for a certain number of active shard copies before proceeding with the operation. If the requisite number of active shard copies are not available, then the write operation must wait and retry, until either the requisite shard copies have started or a timeout occurs. By default, write operations only wait for the primary shards to be active before proceeding (that is to say `wait_for_active_shards` is `1`). This default can be overridden in the index settings dynamically by setting `index.write.wait_for_active_shards`. To alter this behavior per operation, use the `wait_for_active_shards request` parameter. Valid values are all or any positive integer up to the total number of configured copies per shard in the index (which is `number_of_replicas`+1). Specifying a negative value or a number greater than the number of shard copies will throw an error. For example, suppose you have a cluster of three nodes, A, B, and C and you create an index index with the number of replicas set to 3 (resulting in 4 shard copies, one more copy than there are nodes). If you attempt an indexing operation, by default the operation will only ensure the primary copy of each shard is available before proceeding. This means that even if B and C went down and A hosted the primary shard copies, the indexing operation would still proceed with only one copy of the data. If `wait_for_active_shards` is set on the request to `3` (and all three nodes are up), the indexing operation will require 3 active shard copies before proceeding. This requirement should be met because there are 3 active nodes in the cluster, each one holding a copy of the shard. However, if you set `wait_for_active_shards` to `all` (or to `4`, which is the same in this situation), the indexing operation will not proceed as you do not have all 4 copies of each shard active in the index. The operation will timeout unless a new node is brought up in the cluster to host the fourth copy of the shard. It is important to note that this setting greatly reduces the chances of the write operation not writing to the requisite number of shard copies, but it does not completely eliminate the possibility, because this check occurs before the write operation starts. After the write operation is underway, it is still possible for replication to fail on any number of shard copies but still succeed on the primary. The `_shards` section of the API response reveals the number of shard copies on which replication succeeded and failed. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-index_.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-create | Elasticsearch API documentation} */ export default async function CreateApi (this: That, params: T.CreateRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function CreateApi (this: That, params: T.CreateRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/dangling_indices.ts b/src/api/api/dangling_indices.ts index 00a5e88ac..e8dc5399d 100644 --- a/src/api/api/dangling_indices.ts +++ b/src/api/api/dangling_indices.ts @@ -45,7 +45,7 @@ export default class DanglingIndices { /** * Delete a dangling index. If Elasticsearch encounters index data that is absent from the current cluster state, those indices are considered to be dangling. For example, this can happen if you delete more than `cluster.indices.tombstones.size` indices while an Elasticsearch node is offline. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/dangling-index-delete.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-dangling-indices-delete-dangling-index | Elasticsearch API documentation} */ async deleteDanglingIndex (this: That, params: T.DanglingIndicesDeleteDanglingIndexRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteDanglingIndex (this: That, params: T.DanglingIndicesDeleteDanglingIndexRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class DanglingIndices { /** * Import a dangling index. If Elasticsearch encounters index data that is absent from the current cluster state, those indices are considered to be dangling. For example, this can happen if you delete more than `cluster.indices.tombstones.size` indices while an Elasticsearch node is offline. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/dangling-index-import.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-dangling-indices-import-dangling-index | Elasticsearch API documentation} */ async importDanglingIndex (this: That, params: T.DanglingIndicesImportDanglingIndexRequest, options?: TransportRequestOptionsWithOutMeta): Promise async importDanglingIndex (this: That, params: T.DanglingIndicesImportDanglingIndexRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -129,7 +129,7 @@ export default class DanglingIndices { /** * Get the dangling indices. If Elasticsearch encounters index data that is absent from the current cluster state, those indices are considered to be dangling. For example, this can happen if you delete more than `cluster.indices.tombstones.size` indices while an Elasticsearch node is offline. Use this API to list dangling indices, which you can then import or delete. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/dangling-indices-list.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-dangling-indices-list-dangling-indices | Elasticsearch API documentation} */ async listDanglingIndices (this: That, params?: T.DanglingIndicesListDanglingIndicesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async listDanglingIndices (this: That, params?: T.DanglingIndicesListDanglingIndicesRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/delete.ts b/src/api/api/delete.ts index ced9363fb..63b4cf22b 100644 --- a/src/api/api/delete.ts +++ b/src/api/api/delete.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Delete a document. Remove a JSON document from the specified index. NOTE: You cannot send deletion requests directly to a data stream. To delete a document in a data stream, you must target the backing index containing the document. **Optimistic concurrency control** Delete operations can be made conditional and only be performed if the last modification to the document was assigned the sequence number and primary term specified by the `if_seq_no` and `if_primary_term` parameters. If a mismatch is detected, the operation will result in a `VersionConflictException` and a status code of `409`. **Versioning** Each document indexed is versioned. When deleting a document, the version can be specified to make sure the relevant document you are trying to delete is actually being deleted and it has not changed in the meantime. Every write operation run on a document, deletes included, causes its version to be incremented. The version number of a deleted document remains available for a short time after deletion to allow for control of concurrent operations. The length of time for which a deleted document's version remains available is determined by the `index.gc_deletes` index setting. **Routing** If routing is used during indexing, the routing value also needs to be specified to delete a document. If the `_routing` mapping is set to `required` and no routing value is specified, the delete API throws a `RoutingMissingException` and rejects the request. For example: ``` DELETE /my-index-000001/_doc/1?routing=shard-1 ``` This request deletes the document with ID 1, but it is routed based on the user. The document is not deleted if the correct routing is not specified. **Distributed** The delete operation gets hashed into a specific shard ID. It then gets redirected into the primary shard within that ID group and replicated (if needed) to shard replicas within that ID group. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-delete.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-delete | Elasticsearch API documentation} */ export default async function DeleteApi (this: That, params: T.DeleteRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function DeleteApi (this: That, params: T.DeleteRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/delete_by_query.ts b/src/api/api/delete_by_query.ts index e2ce7ab74..f99e09670 100644 --- a/src/api/api/delete_by_query.ts +++ b/src/api/api/delete_by_query.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Delete documents. Deletes documents that match the specified query. If the Elasticsearch security features are enabled, you must have the following index privileges for the target data stream, index, or alias: * `read` * `delete` or `write` You can specify the query criteria in the request URI or the request body using the same syntax as the search API. When you submit a delete by query request, Elasticsearch gets a snapshot of the data stream or index when it begins processing the request and deletes matching documents using internal versioning. If a document changes between the time that the snapshot is taken and the delete operation is processed, it results in a version conflict and the delete operation fails. NOTE: Documents with a version equal to 0 cannot be deleted using delete by query because internal versioning does not support 0 as a valid version number. While processing a delete by query request, Elasticsearch performs multiple search requests sequentially to find all of the matching documents to delete. A bulk delete request is performed for each batch of matching documents. If a search or bulk request is rejected, the requests are retried up to 10 times, with exponential back off. If the maximum retry limit is reached, processing halts and all failed requests are returned in the response. Any delete requests that completed successfully still stick, they are not rolled back. You can opt to count version conflicts instead of halting and returning by setting `conflicts` to `proceed`. Note that if you opt to count version conflicts the operation could attempt to delete more documents from the source than `max_docs` until it has successfully deleted `max_docs documents`, or it has gone through every document in the source query. **Throttling delete requests** To control the rate at which delete by query issues batches of delete operations, you can set `requests_per_second` to any positive decimal number. This pads each batch with a wait time to throttle the rate. Set `requests_per_second` to `-1` to disable throttling. Throttling uses a wait time between batches so that the internal scroll requests can be given a timeout that takes the request padding into account. The padding time is the difference between the batch size divided by the `requests_per_second` and the time spent writing. By default the batch size is `1000`, so if `requests_per_second` is set to `500`: ``` target_time = 1000 / 500 per second = 2 seconds wait_time = target_time - write_time = 2 seconds - .5 seconds = 1.5 seconds ``` Since the batch is issued as a single `_bulk` request, large batch sizes cause Elasticsearch to create many requests and wait before starting the next set. This is "bursty" instead of "smooth". **Slicing** Delete by query supports sliced scroll to parallelize the delete process. This can improve efficiency and provide a convenient way to break the request down into smaller parts. Setting `slices` to `auto` lets Elasticsearch choose the number of slices to use. This setting will use one slice per shard, up to a certain limit. If there are multiple source data streams or indices, it will choose the number of slices based on the index or backing index with the smallest number of shards. Adding slices to the delete by query operation creates sub-requests which means it has some quirks: * You can see these requests in the tasks APIs. These sub-requests are "child" tasks of the task for the request with slices. * Fetching the status of the task for the request with slices only contains the status of completed slices. * These sub-requests are individually addressable for things like cancellation and rethrottling. * Rethrottling the request with `slices` will rethrottle the unfinished sub-request proportionally. * Canceling the request with `slices` will cancel each sub-request. * Due to the nature of `slices` each sub-request won't get a perfectly even portion of the documents. All documents will be addressed, but some slices may be larger than others. Expect larger slices to have a more even distribution. * Parameters like `requests_per_second` and `max_docs` on a request with `slices` are distributed proportionally to each sub-request. Combine that with the earlier point about distribution being uneven and you should conclude that using `max_docs` with `slices` might not result in exactly `max_docs` documents being deleted. * Each sub-request gets a slightly different snapshot of the source data stream or index though these are all taken at approximately the same time. If you're slicing manually or otherwise tuning automatic slicing, keep in mind that: * Query performance is most efficient when the number of slices is equal to the number of shards in the index or backing index. If that number is large (for example, 500), choose a lower number as too many `slices` hurts performance. Setting `slices` higher than the number of shards generally does not improve efficiency and adds overhead. * Delete performance scales linearly across available resources with the number of slices. Whether query or delete performance dominates the runtime depends on the documents being reindexed and cluster resources. **Cancel a delete by query operation** Any delete by query can be canceled using the task cancel API. For example: ``` POST _tasks/r1A2WoRbTwKZ516z6NEs5A:36619/_cancel ``` The task ID can be found by using the get tasks API. Cancellation should happen quickly but might take a few seconds. The get task status API will continue to list the delete by query task until this task checks that it has been cancelled and terminates itself. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-delete-by-query.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-delete-by-query | Elasticsearch API documentation} */ export default async function DeleteByQueryApi (this: That, params: T.DeleteByQueryRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function DeleteByQueryApi (this: That, params: T.DeleteByQueryRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/delete_by_query_rethrottle.ts b/src/api/api/delete_by_query_rethrottle.ts index 57d9bacda..4da430635 100644 --- a/src/api/api/delete_by_query_rethrottle.ts +++ b/src/api/api/delete_by_query_rethrottle.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Throttle a delete by query operation. Change the number of requests per second for a particular delete by query operation. Rethrottling that speeds up the query takes effect immediately but rethrotting that slows down the query takes effect after completing the current batch to prevent scroll timeouts. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-delete-by-query.html#docs-delete-by-query-rethrottle | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-delete-by-query-rethrottle | Elasticsearch API documentation} */ export default async function DeleteByQueryRethrottleApi (this: That, params: T.DeleteByQueryRethrottleRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function DeleteByQueryRethrottleApi (this: That, params: T.DeleteByQueryRethrottleRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/delete_script.ts b/src/api/api/delete_script.ts index e07b5c09b..e6519dffd 100644 --- a/src/api/api/delete_script.ts +++ b/src/api/api/delete_script.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Delete a script or search template. Deletes a stored script or search template. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-delete-script | Elasticsearch API documentation} */ export default async function DeleteScriptApi (this: That, params: T.DeleteScriptRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function DeleteScriptApi (this: That, params: T.DeleteScriptRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/enrich.ts b/src/api/api/enrich.ts index 2539819a6..ea301cac5 100644 --- a/src/api/api/enrich.ts +++ b/src/api/api/enrich.ts @@ -45,7 +45,7 @@ export default class Enrich { /** * Delete an enrich policy. Deletes an existing enrich policy and its enrich index. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-enrich-policy-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-enrich-delete-policy | Elasticsearch API documentation} */ async deletePolicy (this: That, params: T.EnrichDeletePolicyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deletePolicy (this: That, params: T.EnrichDeletePolicyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class Enrich { /** * Run an enrich policy. Create the enrich index for an existing enrich policy. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/execute-enrich-policy-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-enrich-execute-policy | Elasticsearch API documentation} */ async executePolicy (this: That, params: T.EnrichExecutePolicyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async executePolicy (this: That, params: T.EnrichExecutePolicyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -129,7 +129,7 @@ export default class Enrich { /** * Get an enrich policy. Returns information about an enrich policy. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-enrich-policy-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-enrich-get-policy | Elasticsearch API documentation} */ async getPolicy (this: That, params?: T.EnrichGetPolicyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getPolicy (this: That, params?: T.EnrichGetPolicyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -179,7 +179,7 @@ export default class Enrich { /** * Create an enrich policy. Creates an enrich policy. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-enrich-policy-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-enrich-put-policy | Elasticsearch API documentation} */ async putPolicy (this: That, params: T.EnrichPutPolicyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putPolicy (this: That, params: T.EnrichPutPolicyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -226,7 +226,7 @@ export default class Enrich { /** * Get enrich stats. Returns enrich coordinator statistics and information about enrich policies that are currently executing. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/enrich-stats-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-enrich-stats | Elasticsearch API documentation} */ async stats (this: That, params?: T.EnrichStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stats (this: That, params?: T.EnrichStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/eql.ts b/src/api/api/eql.ts index 551257c86..9f490aca9 100644 --- a/src/api/api/eql.ts +++ b/src/api/api/eql.ts @@ -45,7 +45,7 @@ export default class Eql { /** * Delete an async EQL search. Delete an async EQL search or a stored synchronous EQL search. The API also deletes results for the search. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/eql-search-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-eql-delete | Elasticsearch API documentation} */ async delete (this: That, params: T.EqlDeleteRequest, options?: TransportRequestOptionsWithOutMeta): Promise async delete (this: That, params: T.EqlDeleteRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class Eql { /** * Get async EQL search results. Get the current status and available results for an async EQL search or a stored synchronous EQL search. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-async-eql-search-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-eql-get | Elasticsearch API documentation} */ async get (this: That, params: T.EqlGetRequest, options?: TransportRequestOptionsWithOutMeta): Promise> async get (this: That, params: T.EqlGetRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> @@ -129,7 +129,7 @@ export default class Eql { /** * Get the async EQL status. Get the current status for an async EQL search or a stored synchronous EQL search without returning results. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-async-eql-status-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-eql-get-status | Elasticsearch API documentation} */ async getStatus (this: That, params: T.EqlGetStatusRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getStatus (this: That, params: T.EqlGetStatusRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -171,7 +171,7 @@ export default class Eql { /** * Get EQL search results. Returns search results for an Event Query Language (EQL) query. EQL assumes each document in a data stream or index corresponds to an event. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/eql-search-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-eql-search | Elasticsearch API documentation} */ async search (this: That, params: T.EqlSearchRequest, options?: TransportRequestOptionsWithOutMeta): Promise> async search (this: That, params: T.EqlSearchRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/esql.ts b/src/api/api/esql.ts index 2aede7e26..a507e0952 100644 --- a/src/api/api/esql.ts +++ b/src/api/api/esql.ts @@ -45,7 +45,7 @@ export default class Esql { /** * Run an async ES|QL query. Asynchronously run an ES|QL (Elasticsearch query language) query, monitor its progress, and retrieve results when they become available. The API accepts the same parameters and request body as the synchronous query API, along with additional async related properties. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/esql-async-query-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-esql-async-query | Elasticsearch API documentation} */ async asyncQuery (this: That, params: T.EsqlAsyncQueryRequest, options?: TransportRequestOptionsWithOutMeta): Promise async asyncQuery (this: That, params: T.EsqlAsyncQueryRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -89,7 +89,7 @@ export default class Esql { /** * Delete an async ES|QL query. If the query is still running, it is cancelled. Otherwise, the stored results are deleted. If the Elasticsearch security features are enabled, only the following users can use this API to delete a query: * The authenticated user that submitted the original query request * Users with the `cancel_task` cluster privilege - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/esql-async-query-delete-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-esql-async-query-delete | Elasticsearch API documentation} */ async asyncQueryDelete (this: That, params: T.EsqlAsyncQueryDeleteRequest, options?: TransportRequestOptionsWithOutMeta): Promise async asyncQueryDelete (this: That, params: T.EsqlAsyncQueryDeleteRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -131,7 +131,7 @@ export default class Esql { /** * Get async ES|QL query results. Get the current status and available results or stored results for an ES|QL asynchronous query. If the Elasticsearch security features are enabled, only the user who first submitted the ES|QL query can retrieve the results using this API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/esql-async-query-get-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-esql-async-query-get | Elasticsearch API documentation} */ async asyncQueryGet (this: That, params: T.EsqlAsyncQueryGetRequest, options?: TransportRequestOptionsWithOutMeta): Promise async asyncQueryGet (this: That, params: T.EsqlAsyncQueryGetRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -171,6 +171,48 @@ export default class Esql { return await this.transport.request({ path, method, querystring, body, meta }, options) } + /** + * Stop async ES|QL query. This API interrupts the query execution and returns the results so far. If the Elasticsearch security features are enabled, only the user who first submitted the ES|QL query can stop it. + * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/esql-async-query-stop-api.html | Elasticsearch API documentation} + */ + async asyncQueryStop (this: That, params: T.EsqlAsyncQueryStopRequest, options?: TransportRequestOptionsWithOutMeta): Promise + async asyncQueryStop (this: That, params: T.EsqlAsyncQueryStopRequest, options?: TransportRequestOptionsWithMeta): Promise> + async asyncQueryStop (this: That, params: T.EsqlAsyncQueryStopRequest, options?: TransportRequestOptions): Promise + async asyncQueryStop (this: That, params: T.EsqlAsyncQueryStopRequest, options?: TransportRequestOptions): Promise { + const acceptedPath: string[] = ['id'] + const userQuery = params?.querystring + const querystring: Record = userQuery != null ? { ...userQuery } : {} + + let body: Record | string | undefined + const userBody = params?.body + if (userBody != null) { + if (typeof userBody === 'string') { + body = userBody + } else { + body = { ...userBody } + } + } + + for (const key in params) { + if (acceptedPath.includes(key)) { + continue + } else if (key !== 'body' && key !== 'querystring') { + // @ts-expect-error + querystring[key] = params[key] + } + } + + const method = 'POST' + const path = `/_query/async/${encodeURIComponent(params.id.toString())}/stop` + const meta: TransportRequestMetadata = { + name: 'esql.async_query_stop', + pathParts: { + id: params.id + } + } + return await this.transport.request({ path, method, querystring, body, meta }, options) + } + /** * Run an ES|QL query. Get search results for an ES|QL (Elasticsearch query language) query. * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/esql-rest.html | Elasticsearch API documentation} diff --git a/src/api/api/exists.ts b/src/api/api/exists.ts index e0d66762e..0c5f99bde 100644 --- a/src/api/api/exists.ts +++ b/src/api/api/exists.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Check a document. Verify that a document exists. For example, check to see if a document with the `_id` 0 exists: ``` HEAD my-index-000001/_doc/0 ``` If the document exists, the API returns a status code of `200 - OK`. If the document doesn’t exist, the API returns `404 - Not Found`. **Versioning support** You can use the `version` parameter to check the document only if its current version is equal to the specified one. Internally, Elasticsearch has marked the old document as deleted and added an entirely new document. The old version of the document doesn't disappear immediately, although you won't be able to access it. Elasticsearch cleans up deleted documents in the background as you continue to index more data. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-get | Elasticsearch API documentation} */ export default async function ExistsApi (this: That, params: T.ExistsRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function ExistsApi (this: That, params: T.ExistsRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/exists_source.ts b/src/api/api/exists_source.ts index a57b4b804..750302a6f 100644 --- a/src/api/api/exists_source.ts +++ b/src/api/api/exists_source.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Check for a document source. Check whether a document source exists in an index. For example: ``` HEAD my-index-000001/_source/1 ``` A document's source is not available if it is disabled in the mapping. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-get | Elasticsearch API documentation} */ export default async function ExistsSourceApi (this: That, params: T.ExistsSourceRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function ExistsSourceApi (this: That, params: T.ExistsSourceRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/explain.ts b/src/api/api/explain.ts index c93ab5275..16150530b 100644 --- a/src/api/api/explain.ts +++ b/src/api/api/explain.ts @@ -38,8 +38,8 @@ import * as T from '../types' interface That { transport: Transport } /** - * Explain a document match result. Returns information about why a specific document matches, or doesn’t match, a query. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-explain.html | Elasticsearch API documentation} + * Explain a document match result. Get information about why a specific document matches, or doesn't match, a query. It computes a score explanation for a query and a specific document. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-explain | Elasticsearch API documentation} */ export default async function ExplainApi (this: That, params: T.ExplainRequest, options?: TransportRequestOptionsWithOutMeta): Promise> export default async function ExplainApi (this: That, params: T.ExplainRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/features.ts b/src/api/api/features.ts index 7e90c2808..670d84cda 100644 --- a/src/api/api/features.ts +++ b/src/api/api/features.ts @@ -45,7 +45,7 @@ export default class Features { /** * Get the features. Get a list of features that can be included in snapshots using the `feature_states` field when creating a snapshot. You can use this API to determine which feature states to include when taking a snapshot. By default, all feature states are included in a snapshot if that snapshot includes the global state, or none if it does not. A feature state includes one or more system indices necessary for a given feature to function. In order to ensure data integrity, all system indices that comprise a feature state are snapshotted and restored together. The features listed by this API are a combination of built-in features and features defined by plugins. In order for a feature state to be listed in this API and recognized as a valid feature state by the create snapshot API, the plugin that defines that feature must be installed on the master node. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-features-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-features-get-features | Elasticsearch API documentation} */ async getFeatures (this: That, params?: T.FeaturesGetFeaturesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getFeatures (this: That, params?: T.FeaturesGetFeaturesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -85,7 +85,7 @@ export default class Features { /** * Reset the features. Clear all of the state information stored in system indices by Elasticsearch features, including the security and machine learning indices. WARNING: Intended for development and testing use only. Do not reset features on a production cluster. Return a cluster to the same state as a new installation by resetting the feature state for all Elasticsearch features. This deletes all state information stored in system indices. The response code is HTTP 200 if the state is successfully reset for all features. It is HTTP 500 if the reset operation failed for any feature. Note that select features might provide a way to reset particular system indices. Using this API resets all features, both those that are built-in and implemented as plugins. To list the features that will be affected, use the get features API. IMPORTANT: The features installed on the node you submit this request to are the features that will be reset. Run on the master node if you have any doubts about which plugins are installed on individual nodes. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-snapshots.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-features-reset-features | Elasticsearch API documentation} */ async resetFeatures (this: That, params?: T.FeaturesResetFeaturesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async resetFeatures (this: That, params?: T.FeaturesResetFeaturesRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/field_caps.ts b/src/api/api/field_caps.ts index 6f04e7f32..de9d61a0e 100644 --- a/src/api/api/field_caps.ts +++ b/src/api/api/field_caps.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Get the field capabilities. Get information about the capabilities of fields among multiple indices. For data streams, the API returns field capabilities among the stream’s backing indices. It returns runtime fields like any other field. For example, a runtime field with a type of keyword is returned the same as any other field that belongs to the `keyword` family. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-field-caps.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-field-caps | Elasticsearch API documentation} */ export default async function FieldCapsApi (this: That, params?: T.FieldCapsRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function FieldCapsApi (this: That, params?: T.FieldCapsRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/fleet.ts b/src/api/api/fleet.ts index 8f4d75d31..042fcbfd1 100644 --- a/src/api/api/fleet.ts +++ b/src/api/api/fleet.ts @@ -127,7 +127,7 @@ export default class Fleet { /** * Get global checkpoints. Get the current global checkpoints for an index. This API is designed for internal use by the Fleet server project. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-global-checkpoints.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-fleet | Elasticsearch API documentation} */ async globalCheckpoints (this: That, params: T.FleetGlobalCheckpointsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async globalCheckpoints (this: That, params: T.FleetGlobalCheckpointsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -169,6 +169,7 @@ export default class Fleet { /** * Run multiple Fleet searches. Run several Fleet searches with a single API request. The API follows the same structure as the multi search API. However, similar to the Fleet search API, it supports the `wait_for_checkpoints` parameter. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-fleet-msearch | Elasticsearch API documentation} */ async msearch (this: That, params: T.FleetMsearchRequest, options?: TransportRequestOptionsWithOutMeta): Promise> async msearch (this: That, params: T.FleetMsearchRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> @@ -250,6 +251,7 @@ export default class Fleet { /** * Run a Fleet search. The purpose of the Fleet search API is to provide an API where the search will be run only after the provided checkpoint has been processed and is visible for searches inside of Elasticsearch. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-fleet-search | Elasticsearch API documentation} */ async search (this: That, params: T.FleetSearchRequest, options?: TransportRequestOptionsWithOutMeta): Promise> async search (this: That, params: T.FleetSearchRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/get.ts b/src/api/api/get.ts index 55d638696..3cb82914a 100644 --- a/src/api/api/get.ts +++ b/src/api/api/get.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Get a document by its ID. Get a document and its source or stored fields from an index. By default, this API is realtime and is not affected by the refresh rate of the index (when data will become visible for search). In the case where stored fields are requested with the `stored_fields` parameter and the document has been updated but is not yet refreshed, the API will have to parse and analyze the source to extract the stored fields. To turn off realtime behavior, set the `realtime` parameter to false. **Source filtering** By default, the API returns the contents of the `_source` field unless you have used the `stored_fields` parameter or the `_source` field is turned off. You can turn off `_source` retrieval by using the `_source` parameter: ``` GET my-index-000001/_doc/0?_source=false ``` If you only need one or two fields from the `_source`, use the `_source_includes` or `_source_excludes` parameters to include or filter out particular fields. This can be helpful with large documents where partial retrieval can save on network overhead Both parameters take a comma separated list of fields or wildcard expressions. For example: ``` GET my-index-000001/_doc/0?_source_includes=*.id&_source_excludes=entities ``` If you only want to specify includes, you can use a shorter notation: ``` GET my-index-000001/_doc/0?_source=*.id ``` **Routing** If routing is used during indexing, the routing value also needs to be specified to retrieve a document. For example: ``` GET my-index-000001/_doc/2?routing=user1 ``` This request gets the document with ID 2, but it is routed based on the user. The document is not fetched if the correct routing is not specified. **Distributed** The GET operation is hashed into a specific shard ID. It is then redirected to one of the replicas within that shard ID and returns the result. The replicas are the primary shard and its replicas within that shard ID group. This means that the more replicas you have, the better your GET scaling will be. **Versioning support** You can use the `version` parameter to retrieve the document only if its current version is equal to the specified one. Internally, Elasticsearch has marked the old document as deleted and added an entirely new document. The old version of the document doesn't disappear immediately, although you won't be able to access it. Elasticsearch cleans up deleted documents in the background as you continue to index more data. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-get | Elasticsearch API documentation} */ export default async function GetApi (this: That, params: T.GetRequest, options?: TransportRequestOptionsWithOutMeta): Promise> export default async function GetApi (this: That, params: T.GetRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/get_script.ts b/src/api/api/get_script.ts index a3947bdb6..d079ba650 100644 --- a/src/api/api/get_script.ts +++ b/src/api/api/get_script.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Get a script or search template. Retrieves a stored script or search template. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-get-script | Elasticsearch API documentation} */ export default async function GetScriptApi (this: That, params: T.GetScriptRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function GetScriptApi (this: That, params: T.GetScriptRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/get_script_context.ts b/src/api/api/get_script_context.ts index 2f73053f3..b263ed089 100644 --- a/src/api/api/get_script_context.ts +++ b/src/api/api/get_script_context.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Get script contexts. Get a list of supported script contexts and their methods. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/painless/master/painless-contexts.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-get-script-context | Elasticsearch API documentation} */ export default async function GetScriptContextApi (this: That, params?: T.GetScriptContextRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function GetScriptContextApi (this: That, params?: T.GetScriptContextRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/get_script_languages.ts b/src/api/api/get_script_languages.ts index d5b706d9b..7b52735c4 100644 --- a/src/api/api/get_script_languages.ts +++ b/src/api/api/get_script_languages.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Get script languages. Get a list of available script types, languages, and contexts. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-get-script-languages | Elasticsearch API documentation} */ export default async function GetScriptLanguagesApi (this: That, params?: T.GetScriptLanguagesRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function GetScriptLanguagesApi (this: That, params?: T.GetScriptLanguagesRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/get_source.ts b/src/api/api/get_source.ts index f72c08cfc..a4eef8c97 100644 --- a/src/api/api/get_source.ts +++ b/src/api/api/get_source.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Get a document's source. Get the source of a document. For example: ``` GET my-index-000001/_source/1 ``` You can use the source filtering parameters to control which parts of the `_source` are returned: ``` GET my-index-000001/_source/1/?_source_includes=*.id&_source_excludes=entities ``` - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-get.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-get | Elasticsearch API documentation} */ export default async function GetSourceApi (this: That, params: T.GetSourceRequest, options?: TransportRequestOptionsWithOutMeta): Promise> export default async function GetSourceApi (this: That, params: T.GetSourceRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/graph.ts b/src/api/api/graph.ts index fc1a19fe6..33534fe4a 100644 --- a/src/api/api/graph.ts +++ b/src/api/api/graph.ts @@ -45,7 +45,7 @@ export default class Graph { /** * Explore graph analytics. Extract and summarize information about the documents and terms in an Elasticsearch data stream or index. The easiest way to understand the behavior of this API is to use the Graph UI to explore connections. An initial request to the `_explore` API contains a seed query that identifies the documents of interest and specifies the fields that define the vertices and connections you want to include in the graph. Subsequent requests enable you to spider out from one more vertices of interest. You can exclude vertices that have already been returned. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/graph-explore-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-graph | Elasticsearch API documentation} */ async explore (this: That, params: T.GraphExploreRequest, options?: TransportRequestOptionsWithOutMeta): Promise async explore (this: That, params: T.GraphExploreRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/health_report.ts b/src/api/api/health_report.ts index 1e271ecc0..51a48a265 100644 --- a/src/api/api/health_report.ts +++ b/src/api/api/health_report.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Get the cluster health. Get a report with the health status of an Elasticsearch cluster. The report contains a list of indicators that compose Elasticsearch functionality. Each indicator has a health status of: green, unknown, yellow or red. The indicator will provide an explanation and metadata describing the reason for its current health status. The cluster’s status is controlled by the worst indicator status. In the event that an indicator’s status is non-green, a list of impacts may be present in the indicator result which detail the functionalities that are negatively affected by the health issue. Each impact carries with it a severity level, an area of the system that is affected, and a simple description of the impact on the system. Some health indicators can determine the root cause of a health problem and prescribe a set of steps that can be performed in order to improve the health of the system. The root cause and remediation steps are encapsulated in a diagnosis. A diagnosis contains a cause detailing a root cause analysis, an action containing a brief description of the steps to take to fix the problem, the list of affected resources (if applicable), and a detailed step-by-step troubleshooting guide to fix the diagnosed problem. NOTE: The health indicators perform root cause analysis of non-green health statuses. This can be computationally expensive when called frequently. When setting up automated polling of the API for health status, set verbose to false to disable the more expensive analysis logic. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/health-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-health-report | Elasticsearch API documentation} */ export default async function HealthReportApi (this: That, params?: T.HealthReportRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function HealthReportApi (this: That, params?: T.HealthReportRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/ilm.ts b/src/api/api/ilm.ts index 506120df2..1c097071c 100644 --- a/src/api/api/ilm.ts +++ b/src/api/api/ilm.ts @@ -45,7 +45,7 @@ export default class Ilm { /** * Delete a lifecycle policy. You cannot delete policies that are currently in use. If the policy is being used to manage any indices, the request fails and returns an error. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ilm-delete-lifecycle.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-delete-lifecycle | Elasticsearch API documentation} */ async deleteLifecycle (this: That, params: T.IlmDeleteLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteLifecycle (this: That, params: T.IlmDeleteLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class Ilm { /** * Explain the lifecycle state. Get the current lifecycle status for one or more indices. For data streams, the API retrieves the current lifecycle status for the stream's backing indices. The response indicates when the index entered each lifecycle state, provides the definition of the running phase, and information about any failures. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ilm-explain-lifecycle.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-explain-lifecycle | Elasticsearch API documentation} */ async explainLifecycle (this: That, params: T.IlmExplainLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async explainLifecycle (this: That, params: T.IlmExplainLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -129,7 +129,7 @@ export default class Ilm { /** * Get lifecycle policies. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ilm-get-lifecycle.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-get-lifecycle | Elasticsearch API documentation} */ async getLifecycle (this: That, params?: T.IlmGetLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getLifecycle (this: That, params?: T.IlmGetLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -179,7 +179,7 @@ export default class Ilm { /** * Get the ILM status. Get the current index lifecycle management status. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ilm-get-status.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-get-status | Elasticsearch API documentation} */ async getStatus (this: That, params?: T.IlmGetStatusRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getStatus (this: That, params?: T.IlmGetStatusRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -219,7 +219,7 @@ export default class Ilm { /** * Migrate to data tiers routing. Switch the indices, ILM policies, and legacy, composable, and component templates from using custom node attributes and attribute-based allocation filters to using data tiers. Optionally, delete one legacy index template. Using node roles enables ILM to automatically move the indices between data tiers. Migrating away from custom node attributes routing can be manually performed. This API provides an automated way of performing three out of the four manual steps listed in the migration guide: 1. Stop setting the custom hot attribute on new indices. 1. Remove custom allocation settings from existing ILM policies. 1. Replace custom allocation settings from existing indices with the corresponding tier preference. ILM must be stopped before performing the migration. Use the stop ILM and get ILM status APIs to wait until the reported operation mode is `STOPPED`. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ilm-migrate-to-data-tiers.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-migrate-to-data-tiers | Elasticsearch API documentation} */ async migrateToDataTiers (this: That, params?: T.IlmMigrateToDataTiersRequest, options?: TransportRequestOptionsWithOutMeta): Promise async migrateToDataTiers (this: That, params?: T.IlmMigrateToDataTiersRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -264,7 +264,7 @@ export default class Ilm { /** * Move to a lifecycle step. Manually move an index into a specific step in the lifecycle policy and run that step. WARNING: This operation can result in the loss of data. Manually moving an index into a specific step runs that step even if it has already been performed. This is a potentially destructive action and this should be considered an expert level API. You must specify both the current step and the step to be executed in the body of the request. The request will fail if the current step does not match the step currently running for the index This is to prevent the index from being moved from an unexpected step into the next step. When specifying the target (`next_step`) to which the index will be moved, either the name or both the action and name fields are optional. If only the phase is specified, the index will move to the first step of the first action in the target phase. If the phase and action are specified, the index will move to the first step of the specified action in the specified phase. Only actions specified in the ILM policy are considered valid. An index cannot move to a step that is not part of its policy. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ilm-move-to-step.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-move-to-step | Elasticsearch API documentation} */ async moveToStep (this: That, params: T.IlmMoveToStepRequest, options?: TransportRequestOptionsWithOutMeta): Promise async moveToStep (this: That, params: T.IlmMoveToStepRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -311,7 +311,7 @@ export default class Ilm { /** * Create or update a lifecycle policy. If the specified policy exists, it is replaced and the policy version is incremented. NOTE: Only the latest version of the policy is stored, you cannot revert to previous versions. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ilm-put-lifecycle.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-put-lifecycle | Elasticsearch API documentation} */ async putLifecycle (this: That, params: T.IlmPutLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putLifecycle (this: That, params: T.IlmPutLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -358,7 +358,7 @@ export default class Ilm { /** * Remove policies from an index. Remove the assigned lifecycle policies from an index or a data stream's backing indices. It also stops managing the indices. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ilm-remove-policy.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-remove-policy | Elasticsearch API documentation} */ async removePolicy (this: That, params: T.IlmRemovePolicyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async removePolicy (this: That, params: T.IlmRemovePolicyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -400,7 +400,7 @@ export default class Ilm { /** * Retry a policy. Retry running the lifecycle policy for an index that is in the ERROR step. The API sets the policy back to the step where the error occurred and runs the step. Use the explain lifecycle state API to determine whether an index is in the ERROR step. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ilm-retry-policy.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-retry | Elasticsearch API documentation} */ async retry (this: That, params: T.IlmRetryRequest, options?: TransportRequestOptionsWithOutMeta): Promise async retry (this: That, params: T.IlmRetryRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -442,7 +442,7 @@ export default class Ilm { /** * Start the ILM plugin. Start the index lifecycle management plugin if it is currently stopped. ILM is started automatically when the cluster is formed. Restarting ILM is necessary only when it has been stopped using the stop ILM API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ilm-start.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-start | Elasticsearch API documentation} */ async start (this: That, params?: T.IlmStartRequest, options?: TransportRequestOptionsWithOutMeta): Promise async start (this: That, params?: T.IlmStartRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -482,7 +482,7 @@ export default class Ilm { /** * Stop the ILM plugin. Halt all lifecycle management operations and stop the index lifecycle management plugin. This is useful when you are performing maintenance on the cluster and need to prevent ILM from performing any actions on your indices. The API returns as soon as the stop request has been acknowledged, but the plugin might continue to run until in-progress operations complete and the plugin can be safely stopped. Use the get ILM status API to check whether ILM is running. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ilm-stop.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ilm-stop | Elasticsearch API documentation} */ async stop (this: That, params?: T.IlmStopRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stop (this: That, params?: T.IlmStopRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/index.ts b/src/api/api/index.ts index 13455eca0..bcd3842eb 100644 --- a/src/api/api/index.ts +++ b/src/api/api/index.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Create or update a document in an index. Add a JSON document to the specified data stream or index and make it searchable. If the target is an index and the document already exists, the request updates the document and increments its version. NOTE: You cannot use this API to send update requests for existing documents in a data stream. If the Elasticsearch security features are enabled, you must have the following index privileges for the target data stream, index, or index alias: * To add or overwrite a document using the `PUT //_doc/<_id>` request format, you must have the `create`, `index`, or `write` index privilege. * To add a document using the `POST //_doc/` request format, you must have the `create_doc`, `create`, `index`, or `write` index privilege. * To automatically create a data stream or index with this API request, you must have the `auto_configure`, `create_index`, or `manage` index privilege. Automatic data stream creation requires a matching index template with data stream enabled. NOTE: Replica shards might not all be started when an indexing operation returns successfully. By default, only the primary is required. Set `wait_for_active_shards` to change this default behavior. **Automatically create data streams and indices** If the request's target doesn't exist and matches an index template with a `data_stream` definition, the index operation automatically creates the data stream. If the target doesn't exist and doesn't match a data stream template, the operation automatically creates the index and applies any matching index templates. NOTE: Elasticsearch includes several built-in index templates. To avoid naming collisions with these templates, refer to index pattern documentation. If no mapping exists, the index operation creates a dynamic mapping. By default, new fields and objects are automatically added to the mapping if needed. Automatic index creation is controlled by the `action.auto_create_index` setting. If it is `true`, any index can be created automatically. You can modify this setting to explicitly allow or block automatic creation of indices that match specified patterns or set it to `false` to turn off automatic index creation entirely. Specify a comma-separated list of patterns you want to allow or prefix each pattern with `+` or `-` to indicate whether it should be allowed or blocked. When a list is specified, the default behaviour is to disallow. NOTE: The `action.auto_create_index` setting affects the automatic creation of indices only. It does not affect the creation of data streams. **Optimistic concurrency control** Index operations can be made conditional and only be performed if the last modification to the document was assigned the sequence number and primary term specified by the `if_seq_no` and `if_primary_term` parameters. If a mismatch is detected, the operation will result in a `VersionConflictException` and a status code of `409`. **Routing** By default, shard placement — or routing — is controlled by using a hash of the document's ID value. For more explicit control, the value fed into the hash function used by the router can be directly specified on a per-operation basis using the `routing` parameter. When setting up explicit mapping, you can also use the `_routing` field to direct the index operation to extract the routing value from the document itself. This does come at the (very minimal) cost of an additional document parsing pass. If the `_routing` mapping is defined and set to be required, the index operation will fail if no routing value is provided or extracted. NOTE: Data streams do not support custom routing unless they were created with the `allow_custom_routing` setting enabled in the template. **Distributed** The index operation is directed to the primary shard based on its route and performed on the actual node containing this shard. After the primary shard completes the operation, if needed, the update is distributed to applicable replicas. **Active shards** To improve the resiliency of writes to the system, indexing operations can be configured to wait for a certain number of active shard copies before proceeding with the operation. If the requisite number of active shard copies are not available, then the write operation must wait and retry, until either the requisite shard copies have started or a timeout occurs. By default, write operations only wait for the primary shards to be active before proceeding (that is to say `wait_for_active_shards` is `1`). This default can be overridden in the index settings dynamically by setting `index.write.wait_for_active_shards`. To alter this behavior per operation, use the `wait_for_active_shards request` parameter. Valid values are all or any positive integer up to the total number of configured copies per shard in the index (which is `number_of_replicas`+1). Specifying a negative value or a number greater than the number of shard copies will throw an error. For example, suppose you have a cluster of three nodes, A, B, and C and you create an index index with the number of replicas set to 3 (resulting in 4 shard copies, one more copy than there are nodes). If you attempt an indexing operation, by default the operation will only ensure the primary copy of each shard is available before proceeding. This means that even if B and C went down and A hosted the primary shard copies, the indexing operation would still proceed with only one copy of the data. If `wait_for_active_shards` is set on the request to `3` (and all three nodes are up), the indexing operation will require 3 active shard copies before proceeding. This requirement should be met because there are 3 active nodes in the cluster, each one holding a copy of the shard. However, if you set `wait_for_active_shards` to `all` (or to `4`, which is the same in this situation), the indexing operation will not proceed as you do not have all 4 copies of each shard active in the index. The operation will timeout unless a new node is brought up in the cluster to host the fourth copy of the shard. It is important to note that this setting greatly reduces the chances of the write operation not writing to the requisite number of shard copies, but it does not completely eliminate the possibility, because this check occurs before the write operation starts. After the write operation is underway, it is still possible for replication to fail on any number of shard copies but still succeed on the primary. The `_shards` section of the API response reveals the number of shard copies on which replication succeeded and failed. **No operation (noop) updates** When updating a document by using this API, a new version of the document is always created even if the document hasn't changed. If this isn't acceptable use the `_update` API with `detect_noop` set to `true`. The `detect_noop` option isn't available on this API because it doesn’t fetch the old source and isn't able to compare it against the new source. There isn't a definitive rule for when noop updates aren't acceptable. It's a combination of lots of factors like how frequently your data source sends updates that are actually noops and how many queries per second Elasticsearch runs on the shard receiving the updates. **Versioning** Each indexed document is given a version number. By default, internal versioning is used that starts at 1 and increments with each update, deletes included. Optionally, the version number can be set to an external value (for example, if maintained in a database). To enable this functionality, `version_type` should be set to `external`. The value provided must be a numeric, long value greater than or equal to 0, and less than around `9.2e+18`. NOTE: Versioning is completely real time, and is not affected by the near real time aspects of search operations. If no version is provided, the operation runs without any version checks. When using the external version type, the system checks to see if the version number passed to the index request is greater than the version of the currently stored document. If true, the document will be indexed and the new version number used. If the value provided is less than or equal to the stored document's version number, a version conflict will occur and the index operation will fail. For example: ``` PUT my-index-000001/_doc/1?version=2&version_type=external { "user": { "id": "elkbee" } } In this example, the operation will succeed since the supplied version of 2 is higher than the current document version of 1. If the document was already updated and its version was set to 2 or higher, the indexing command will fail and result in a conflict (409 HTTP status code). A nice side effect is that there is no need to maintain strict ordering of async indexing operations run as a result of changes to a source database, as long as version numbers from the source database are used. Even the simple case of updating the Elasticsearch index using data from a database is simplified if external versioning is used, as only the latest version will be used if the index operations arrive out of order. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-index_.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-create | Elasticsearch API documentation} */ export default async function IndexApi (this: That, params: T.IndexRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function IndexApi (this: That, params: T.IndexRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/indices.ts b/src/api/api/indices.ts index 9fb65257a..c39e5f3a2 100644 --- a/src/api/api/indices.ts +++ b/src/api/api/indices.ts @@ -44,8 +44,8 @@ export default class Indices { } /** - * Add an index block. Limits the operations allowed on an index by blocking specific operation types. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/index-modules-blocks.html | Elasticsearch API documentation} + * Add an index block. Add an index block to an index. Index blocks limit the operations allowed on an index by blocking specific operation types. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-add-block | Elasticsearch API documentation} */ async addBlock (this: That, params: T.IndicesAddBlockRequest, options?: TransportRequestOptionsWithOutMeta): Promise async addBlock (this: That, params: T.IndicesAddBlockRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -88,7 +88,7 @@ export default class Indices { /** * Get tokens from text analysis. The analyze API performs analysis on a text string and returns the resulting tokens. Generating excessive amount of tokens may cause a node to run out of memory. The `index.analyze.max_token_count` setting enables you to limit the number of tokens that can be produced. If more than this limit of tokens gets generated, an error occurs. The `_analyze` endpoint without a specified index will always use `10000` as its limit. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-analyze.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-analyze | Elasticsearch API documentation} */ async analyze (this: That, params?: T.IndicesAnalyzeRequest, options?: TransportRequestOptionsWithOutMeta): Promise async analyze (this: That, params?: T.IndicesAnalyzeRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -185,7 +185,7 @@ export default class Indices { /** * Clear the cache. Clear the cache of one or more indices. For data streams, the API clears the caches of the stream's backing indices. By default, the clear cache API clears all caches. To clear only specific caches, use the `fielddata`, `query`, or `request` parameters. To clear the cache only of specific fields, use the `fields` parameter. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-clearcache.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-clear-cache | Elasticsearch API documentation} */ async clearCache (this: That, params?: T.IndicesClearCacheRequest, options?: TransportRequestOptionsWithOutMeta): Promise async clearCache (this: That, params?: T.IndicesClearCacheRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -235,7 +235,7 @@ export default class Indices { /** * Clone an index. Clone an existing index into a new index. Each original primary shard is cloned into a new primary shard in the new index. IMPORTANT: Elasticsearch does not apply index templates to the resulting index. The API also does not copy index metadata from the original index. Index metadata includes aliases, index lifecycle management phase definitions, and cross-cluster replication (CCR) follower information. For example, if you clone a CCR follower index, the resulting clone will not be a follower index. The clone API copies most index settings from the source index to the resulting index, with the exception of `index.number_of_replicas` and `index.auto_expand_replicas`. To set the number of replicas in the resulting index, configure these settings in the clone request. Cloning works as follows: * First, it creates a new target index with the same definition as the source index. * Then it hard-links segments from the source index into the target index. If the file system does not support hard-linking, all segments are copied into the new index, which is a much more time consuming process. * Finally, it recovers the target index as though it were a closed index which had just been re-opened. IMPORTANT: Indices can only be cloned if they meet the following requirements: * The index must be marked as read-only and have a cluster health status of green. * The target index must not exist. * The source index must have the same number of primary shards as the target index. * The node handling the clone process must have sufficient free disk space to accommodate a second copy of the existing index. The current write index on a data stream cannot be cloned. In order to clone the current write index, the data stream must first be rolled over so that a new write index is created and then the previous write index can be cloned. NOTE: Mappings cannot be specified in the `_clone` request. The mappings of the source index will be used for the target index. **Monitor the cloning process** The cloning process can be monitored with the cat recovery API or the cluster health API can be used to wait until all primary shards have been allocated by setting the `wait_for_status` parameter to `yellow`. The `_clone` API returns as soon as the target index has been added to the cluster state, before any shards have been allocated. At this point, all shards are in the state unassigned. If, for any reason, the target index can't be allocated, its primary shard will remain unassigned until it can be allocated on that node. Once the primary shard is allocated, it moves to state initializing, and the clone process begins. When the clone operation completes, the shard will become active. At that point, Elasticsearch will try to allocate any replicas and may decide to relocate the primary shard to another node. **Wait for active shards** Because the clone operation creates a new index to clone the shards to, the wait for active shards setting on index creation applies to the clone index action as well. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-clone-index.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-clone | Elasticsearch API documentation} */ async clone (this: That, params: T.IndicesCloneRequest, options?: TransportRequestOptionsWithOutMeta): Promise async clone (this: That, params: T.IndicesCloneRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -283,7 +283,7 @@ export default class Indices { /** * Close an index. A closed index is blocked for read or write operations and does not allow all operations that opened indices allow. It is not possible to index documents or to search for documents in a closed index. Closed indices do not have to maintain internal data structures for indexing or searching documents, which results in a smaller overhead on the cluster. When opening or closing an index, the master node is responsible for restarting the index shards to reflect the new state of the index. The shards will then go through the normal recovery process. The data of opened and closed indices is automatically replicated by the cluster to ensure that enough shard copies are safely kept around at all times. You can open and close multiple indices. An error is thrown if the request explicitly refers to a missing index. This behaviour can be turned off using the `ignore_unavailable=true` parameter. By default, you must explicitly name the indices you are opening or closing. To open or close indices with `_all`, `*`, or other wildcard expressions, change the` action.destructive_requires_name` setting to `false`. This setting can also be changed with the cluster update settings API. Closed indices consume a significant amount of disk-space which can cause problems in managed environments. Closing indices can be turned off with the cluster settings API by setting `cluster.indices.close.enable` to `false`. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-close.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-close | Elasticsearch API documentation} */ async close (this: That, params: T.IndicesCloseRequest, options?: TransportRequestOptionsWithOutMeta): Promise async close (this: That, params: T.IndicesCloseRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -325,7 +325,7 @@ export default class Indices { /** * Create an index. You can use the create index API to add a new index to an Elasticsearch cluster. When creating an index, you can specify the following: * Settings for the index. * Mappings for fields in the index. * Index aliases **Wait for active shards** By default, index creation will only return a response to the client when the primary copies of each shard have been started, or the request times out. The index creation response will indicate what happened. For example, `acknowledged` indicates whether the index was successfully created in the cluster, `while shards_acknowledged` indicates whether the requisite number of shard copies were started for each shard in the index before timing out. Note that it is still possible for either `acknowledged` or `shards_acknowledged` to be `false`, but for the index creation to be successful. These values simply indicate whether the operation completed before the timeout. If `acknowledged` is false, the request timed out before the cluster state was updated with the newly created index, but it probably will be created sometime soon. If `shards_acknowledged` is false, then the request timed out before the requisite number of shards were started (by default just the primaries), even if the cluster state was successfully updated to reflect the newly created index (that is to say, `acknowledged` is `true`). You can change the default of only waiting for the primary shards to start through the index setting `index.write.wait_for_active_shards`. Note that changing this setting will also affect the `wait_for_active_shards` value on all subsequent write operations. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-create-index.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-create | Elasticsearch API documentation} */ async create (this: That, params: T.IndicesCreateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async create (this: That, params: T.IndicesCreateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -371,8 +371,8 @@ export default class Indices { } /** - * Create a data stream. Creates a data stream. You must have a matching index template with data stream enabled. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams.html | Elasticsearch API documentation} + * Create a data stream. You must have a matching index template with data stream enabled. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-create-data-stream | Elasticsearch API documentation} */ async createDataStream (this: That, params: T.IndicesCreateDataStreamRequest, options?: TransportRequestOptionsWithOutMeta): Promise async createDataStream (this: That, params: T.IndicesCreateDataStreamRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -451,8 +451,8 @@ export default class Indices { } /** - * Get data stream stats. Retrieves statistics for one or more data streams. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams.html | Elasticsearch API documentation} + * Get data stream stats. Get statistics for one or more data streams. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-data-streams-stats-1 | Elasticsearch API documentation} */ async dataStreamsStats (this: That, params?: T.IndicesDataStreamsStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async dataStreamsStats (this: That, params?: T.IndicesDataStreamsStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -502,7 +502,7 @@ export default class Indices { /** * Delete indices. Deleting an index deletes its documents, shards, and metadata. It does not delete related Kibana components, such as data views, visualizations, or dashboards. You cannot delete the current write index of a data stream. To delete the index, you must roll over the data stream so a new write index is created. You can then use the delete index API to delete the previous write index. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-delete-index.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-delete | Elasticsearch API documentation} */ async delete (this: That, params: T.IndicesDeleteRequest, options?: TransportRequestOptionsWithOutMeta): Promise async delete (this: That, params: T.IndicesDeleteRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -544,7 +544,7 @@ export default class Indices { /** * Delete an alias. Removes a data stream or index from an alias. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-delete-alias.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-delete-alias | Elasticsearch API documentation} */ async deleteAlias (this: That, params: T.IndicesDeleteAliasRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteAlias (this: That, params: T.IndicesDeleteAliasRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -594,7 +594,7 @@ export default class Indices { /** * Delete data stream lifecycles. Removes the data stream lifecycle from a data stream, rendering it not managed by the data stream lifecycle. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams-delete-lifecycle.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-delete-data-lifecycle | Elasticsearch API documentation} */ async deleteDataLifecycle (this: That, params: T.IndicesDeleteDataLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteDataLifecycle (this: That, params: T.IndicesDeleteDataLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -636,7 +636,7 @@ export default class Indices { /** * Delete data streams. Deletes one or more data streams and their backing indices. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-delete-data-stream | Elasticsearch API documentation} */ async deleteDataStream (this: That, params: T.IndicesDeleteDataStreamRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteDataStream (this: That, params: T.IndicesDeleteDataStreamRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -678,7 +678,7 @@ export default class Indices { /** * Delete an index template. The provided may contain multiple template names separated by a comma. If multiple template names are specified then there is no wildcard support and the provided names should match completely with existing templates. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-delete-template.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-delete-index-template | Elasticsearch API documentation} */ async deleteIndexTemplate (this: That, params: T.IndicesDeleteIndexTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteIndexTemplate (this: That, params: T.IndicesDeleteIndexTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -720,7 +720,7 @@ export default class Indices { /** * Delete a legacy index template. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-delete-template-v1.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-delete-template | Elasticsearch API documentation} */ async deleteTemplate (this: That, params: T.IndicesDeleteTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteTemplate (this: That, params: T.IndicesDeleteTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -762,7 +762,7 @@ export default class Indices { /** * Analyze the index disk usage. Analyze the disk usage of each field of an index or data stream. This API might not support indices created in previous Elasticsearch versions. The result of a small index can be inaccurate as some parts of an index might not be analyzed by the API. NOTE: The total size of fields of the analyzed shards of the index in the response is usually smaller than the index `store_size` value because some small metadata files are ignored and some parts of data files might not be scanned by the API. Since stored fields are stored together in a compressed format, the sizes of stored fields are also estimates and can be inaccurate. The stored size of the `_id` field is likely underestimated while the `_source` field is overestimated. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-disk-usage.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-disk-usage | Elasticsearch API documentation} */ async diskUsage (this: That, params: T.IndicesDiskUsageRequest, options?: TransportRequestOptionsWithOutMeta): Promise async diskUsage (this: That, params: T.IndicesDiskUsageRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -804,7 +804,7 @@ export default class Indices { /** * Downsample an index. Aggregate a time series (TSDS) index and store pre-computed statistical summaries (`min`, `max`, `sum`, `value_count` and `avg`) for each metric field grouped by a configured time interval. For example, a TSDS index that contains metrics sampled every 10 seconds can be downsampled to an hourly index. All documents within an hour interval are summarized and stored as a single document in the downsample index. NOTE: Only indices in a time series data stream are supported. Neither field nor document level security can be defined on the source index. The source index must be read only (`index.blocks.write: true`). - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-downsample-data-stream.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-downsample | Elasticsearch API documentation} */ async downsample (this: That, params: T.IndicesDownsampleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async downsample (this: That, params: T.IndicesDownsampleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -842,7 +842,7 @@ export default class Indices { /** * Check indices. Check if one or more indices, index aliases, or data streams exist. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-exists.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-exists | Elasticsearch API documentation} */ async exists (this: That, params: T.IndicesExistsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async exists (this: That, params: T.IndicesExistsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -883,8 +883,8 @@ export default class Indices { } /** - * Check aliases. Checks if one or more data stream or index aliases exist. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-aliases.html | Elasticsearch API documentation} + * Check aliases. Check if one or more data stream or index aliases exist. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-exists-alias | Elasticsearch API documentation} */ async existsAlias (this: That, params: T.IndicesExistsAliasRequest, options?: TransportRequestOptionsWithOutMeta): Promise async existsAlias (this: That, params: T.IndicesExistsAliasRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -934,7 +934,7 @@ export default class Indices { /** * Check index templates. Check whether index templates exist. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/index-templates.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-exists-index-template | Elasticsearch API documentation} */ async existsIndexTemplate (this: That, params: T.IndicesExistsIndexTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async existsIndexTemplate (this: That, params: T.IndicesExistsIndexTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -976,7 +976,7 @@ export default class Indices { /** * Check existence of index templates. Get information about whether index templates exist. Index templates define settings, mappings, and aliases that can be applied automatically to new indices. IMPORTANT: This documentation is about legacy index templates, which are deprecated and will be replaced by the composable templates introduced in Elasticsearch 7.8. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-template-exists-v1.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-exists-template | Elasticsearch API documentation} */ async existsTemplate (this: That, params: T.IndicesExistsTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async existsTemplate (this: That, params: T.IndicesExistsTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1018,7 +1018,7 @@ export default class Indices { /** * Get the status for a data stream lifecycle. Get information about an index or data stream's current data stream lifecycle status, such as time since index creation, time since rollover, the lifecycle configuration managing the index, or any errors encountered during lifecycle execution. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams-explain-lifecycle.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-explain-data-lifecycle | Elasticsearch API documentation} */ async explainDataLifecycle (this: That, params: T.IndicesExplainDataLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async explainDataLifecycle (this: That, params: T.IndicesExplainDataLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1060,7 +1060,7 @@ export default class Indices { /** * Get field usage stats. Get field usage information for each shard and field of an index. Field usage statistics are automatically captured when queries are running on a cluster. A shard-level search request that accesses a given field, even if multiple times during that request, is counted as a single use. The response body reports the per-shard usage count of the data structures that back the fields in the index. A given request will increment each count by a maximum value of 1, even if the request accesses the same field multiple times. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/field-usage-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-field-usage-stats | Elasticsearch API documentation} */ async fieldUsageStats (this: That, params: T.IndicesFieldUsageStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async fieldUsageStats (this: That, params: T.IndicesFieldUsageStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1102,7 +1102,7 @@ export default class Indices { /** * Flush data streams or indices. Flushing a data stream or index is the process of making sure that any data that is currently only stored in the transaction log is also permanently stored in the Lucene index. When restarting, Elasticsearch replays any unflushed operations from the transaction log into the Lucene index to bring it back into the state that it was in before the restart. Elasticsearch automatically triggers flushes as needed, using heuristics that trade off the size of the unflushed transaction log against the cost of performing each flush. After each operation has been flushed it is permanently stored in the Lucene index. This may mean that there is no need to maintain an additional copy of it in the transaction log. The transaction log is made up of multiple files, called generations, and Elasticsearch will delete any generation files when they are no longer needed, freeing up disk space. It is also possible to trigger a flush on one or more indices using the flush API, although it is rare for users to need to call this API directly. If you call the flush API after indexing some documents then a successful response indicates that Elasticsearch has flushed all the documents that were indexed before the flush API was called. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-flush.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-flush | Elasticsearch API documentation} */ async flush (this: That, params?: T.IndicesFlushRequest, options?: TransportRequestOptionsWithOutMeta): Promise async flush (this: That, params?: T.IndicesFlushRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1152,7 +1152,7 @@ export default class Indices { /** * Force a merge. Perform the force merge operation on the shards of one or more indices. For data streams, the API forces a merge on the shards of the stream's backing indices. Merging reduces the number of segments in each shard by merging some of them together and also frees up the space used by deleted documents. Merging normally happens automatically, but sometimes it is useful to trigger a merge manually. WARNING: We recommend force merging only a read-only index (meaning the index is no longer receiving writes). When documents are updated or deleted, the old version is not immediately removed but instead soft-deleted and marked with a "tombstone". These soft-deleted documents are automatically cleaned up during regular segment merges. But force merge can cause very large (greater than 5 GB) segments to be produced, which are not eligible for regular merges. So the number of soft-deleted documents can then grow rapidly, resulting in higher disk usage and worse search performance. If you regularly force merge an index receiving writes, this can also make snapshots more expensive, since the new documents can't be backed up incrementally. **Blocks during a force merge** Calls to this API block until the merge is complete (unless request contains `wait_for_completion=false`). If the client connection is lost before completion then the force merge process will continue in the background. Any new requests to force merge the same indices will also block until the ongoing force merge is complete. **Running force merge asynchronously** If the request contains `wait_for_completion=false`, Elasticsearch performs some preflight checks, launches the request, and returns a task you can use to get the status of the task. However, you can not cancel this task as the force merge task is not cancelable. Elasticsearch creates a record of this task as a document at `_tasks/`. When you are done with a task, you should delete the task document so Elasticsearch can reclaim the space. **Force merging multiple indices** You can force merge multiple indices with a single request by targeting: * One or more data streams that contain multiple backing indices * Multiple indices * One or more aliases * All data streams and indices in a cluster Each targeted shard is force-merged separately using the force_merge threadpool. By default each node only has a single `force_merge` thread which means that the shards on that node are force-merged one at a time. If you expand the `force_merge` threadpool on a node then it will force merge its shards in parallel Force merge makes the storage for the shard being merged temporarily increase, as it may require free space up to triple its size in case `max_num_segments parameter` is set to `1`, to rewrite all segments into a new one. **Data streams and time-based indices** Force-merging is useful for managing a data stream's older backing indices and other time-based indices, particularly after a rollover. In these cases, each index only receives indexing traffic for a certain period of time. Once an index receive no more writes, its shards can be force-merged to a single segment. This can be a good idea because single-segment shards can sometimes use simpler and more efficient data structures to perform searches. For example: ``` POST /.ds-my-data-stream-2099.03.07-000001/_forcemerge?max_num_segments=1 ``` - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-forcemerge.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-forcemerge | Elasticsearch API documentation} */ async forcemerge (this: That, params?: T.IndicesForcemergeRequest, options?: TransportRequestOptionsWithOutMeta): Promise async forcemerge (this: That, params?: T.IndicesForcemergeRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1202,7 +1202,7 @@ export default class Indices { /** * Get index information. Get information about one or more indices. For data streams, the API returns information about the stream’s backing indices. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-get-index.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get | Elasticsearch API documentation} */ async get (this: That, params: T.IndicesGetRequest, options?: TransportRequestOptionsWithOutMeta): Promise async get (this: That, params: T.IndicesGetRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1244,7 +1244,7 @@ export default class Indices { /** * Get aliases. Retrieves information for one or more data stream or index aliases. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-get-alias.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-alias | Elasticsearch API documentation} */ async getAlias (this: That, params?: T.IndicesGetAliasRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getAlias (this: That, params?: T.IndicesGetAliasRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1300,8 +1300,8 @@ export default class Indices { } /** - * Get data stream lifecycles. Retrieves the data stream lifecycle configuration of one or more data streams. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams-get-lifecycle.html | Elasticsearch API documentation} + * Get data stream lifecycles. Get the data stream lifecycle configuration of one or more data streams. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-data-lifecycle | Elasticsearch API documentation} */ async getDataLifecycle (this: That, params: T.IndicesGetDataLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getDataLifecycle (this: That, params: T.IndicesGetDataLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1343,7 +1343,7 @@ export default class Indices { /** * Get data stream lifecycle stats. Get statistics about the data streams that are managed by a data stream lifecycle. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams-get-lifecycle-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-data-lifecycle-stats | Elasticsearch API documentation} */ async getDataLifecycleStats (this: That, params?: T.IndicesGetDataLifecycleStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getDataLifecycleStats (this: That, params?: T.IndicesGetDataLifecycleStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1382,8 +1382,8 @@ export default class Indices { } /** - * Get data streams. Retrieves information about one or more data streams. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/data-streams.html | Elasticsearch API documentation} + * Get data streams. Get information about one or more data streams. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-data-stream | Elasticsearch API documentation} */ async getDataStream (this: That, params?: T.IndicesGetDataStreamRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getDataStream (this: That, params?: T.IndicesGetDataStreamRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1433,7 +1433,7 @@ export default class Indices { /** * Get mapping definitions. Retrieves mapping definitions for one or more fields. For data streams, the API retrieves field mappings for the stream’s backing indices. This API is useful if you don't need a complete mapping or if an index mapping contains a large number of fields. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-get-field-mapping.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-mapping | Elasticsearch API documentation} */ async getFieldMapping (this: That, params: T.IndicesGetFieldMappingRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getFieldMapping (this: That, params: T.IndicesGetFieldMappingRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1483,7 +1483,7 @@ export default class Indices { /** * Get index templates. Get information about one or more index templates. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-get-template.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-index-template | Elasticsearch API documentation} */ async getIndexTemplate (this: That, params?: T.IndicesGetIndexTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getIndexTemplate (this: That, params?: T.IndicesGetIndexTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1533,7 +1533,7 @@ export default class Indices { /** * Get mapping definitions. For data streams, the API retrieves mappings for the stream’s backing indices. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-get-mapping.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-mapping | Elasticsearch API documentation} */ async getMapping (this: That, params?: T.IndicesGetMappingRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getMapping (this: That, params?: T.IndicesGetMappingRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1625,7 +1625,7 @@ export default class Indices { /** * Get index settings. Get setting information for one or more indices. For data streams, it returns setting information for the stream's backing indices. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-get-settings.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-settings | Elasticsearch API documentation} */ async getSettings (this: That, params?: T.IndicesGetSettingsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getSettings (this: That, params?: T.IndicesGetSettingsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1682,7 +1682,7 @@ export default class Indices { /** * Get index templates. Get information about one or more index templates. IMPORTANT: This documentation is about legacy index templates, which are deprecated and will be replaced by the composable templates introduced in Elasticsearch 7.8. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-get-template-v1.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-get-template | Elasticsearch API documentation} */ async getTemplate (this: That, params?: T.IndicesGetTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getTemplate (this: That, params?: T.IndicesGetTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1852,7 +1852,7 @@ export default class Indices { /** * Open a closed index. For data streams, the API opens any closed backing indices. A closed index is blocked for read/write operations and does not allow all operations that opened indices allow. It is not possible to index documents or to search for documents in a closed index. This allows closed indices to not have to maintain internal data structures for indexing or searching documents, resulting in a smaller overhead on the cluster. When opening or closing an index, the master is responsible for restarting the index shards to reflect the new state of the index. The shards will then go through the normal recovery process. The data of opened or closed indices is automatically replicated by the cluster to ensure that enough shard copies are safely kept around at all times. You can open and close multiple indices. An error is thrown if the request explicitly refers to a missing index. This behavior can be turned off by using the `ignore_unavailable=true` parameter. By default, you must explicitly name the indices you are opening or closing. To open or close indices with `_all`, `*`, or other wildcard expressions, change the `action.destructive_requires_name` setting to `false`. This setting can also be changed with the cluster update settings API. Closed indices consume a significant amount of disk-space which can cause problems in managed environments. Closing indices can be turned off with the cluster settings API by setting `cluster.indices.close.enable` to `false`. Because opening or closing an index allocates its shards, the `wait_for_active_shards` setting on index creation applies to the `_open` and `_close` index actions as well. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-open-close.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-open | Elasticsearch API documentation} */ async open (this: That, params: T.IndicesOpenRequest, options?: TransportRequestOptionsWithOutMeta): Promise async open (this: That, params: T.IndicesOpenRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2075,7 +2075,7 @@ export default class Indices { /** * Update field mappings. Add new fields to an existing data stream or index. You can also use this API to change the search settings of existing fields and add new properties to existing object fields. For data streams, these changes are applied to all backing indices by default. **Add multi-fields to an existing field** Multi-fields let you index the same field in different ways. You can use this API to update the fields mapping parameter and enable multi-fields for an existing field. WARNING: If an index (or data stream) contains documents when you add a multi-field, those documents will not have values for the new multi-field. You can populate the new multi-field with the update by query API. **Change supported mapping parameters for an existing field** The documentation for each mapping parameter indicates whether you can update it for an existing field using this API. For example, you can use the update mapping API to update the `ignore_above` parameter. **Change the mapping of an existing field** Except for supported mapping parameters, you can't change the mapping or field type of an existing field. Changing an existing field could invalidate data that's already indexed. If you need to change the mapping of a field in a data stream's backing indices, refer to documentation about modifying data streams. If you need to change the mapping of a field in other indices, create a new index with the correct mapping and reindex your data into that index. **Rename a field** Renaming a field would invalidate data already indexed under the old field name. Instead, add an alias field to create an alternate field name. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-put-mapping.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-put-mapping | Elasticsearch API documentation} */ async putMapping (this: That, params: T.IndicesPutMappingRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putMapping (this: That, params: T.IndicesPutMappingRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2122,7 +2122,7 @@ export default class Indices { /** * Update index settings. Changes dynamic index settings in real time. For data streams, index setting changes are applied to all backing indices by default. To revert a setting to the default value, use a null value. The list of per-index settings that can be updated dynamically on live indices can be found in index module documentation. To preserve existing settings from being updated, set the `preserve_existing` parameter to `true`. NOTE: You can only define new analyzers on closed indices. To add an analyzer, you must close the index, define the analyzer, and reopen the index. You cannot close the write index of a data stream. To update the analyzer for a data stream's write index and future backing indices, update the analyzer in the index template used by the stream. Then roll over the data stream to apply the new analyzer to the stream's write index and future backing indices. This affects searches and any new data added to the stream after the rollover. However, it does not affect the data stream's backing indices or their existing data. To change the analyzer for existing backing indices, you must create a new data stream and reindex your data into it. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-update-settings.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-put-settings | Elasticsearch API documentation} */ async putSettings (this: That, params: T.IndicesPutSettingsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putSettings (this: That, params: T.IndicesPutSettingsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2166,7 +2166,7 @@ export default class Indices { /** * Create or update an index template. Index templates define settings, mappings, and aliases that can be applied automatically to new indices. Elasticsearch applies templates to new indices based on an index pattern that matches the index name. IMPORTANT: This documentation is about legacy index templates, which are deprecated and will be replaced by the composable templates introduced in Elasticsearch 7.8. Composable templates always take precedence over legacy templates. If no composable template matches a new index, matching legacy templates are applied according to their order. Index templates are only applied during index creation. Changes to index templates do not affect existing indices. Settings and mappings specified in create index API requests override any settings or mappings specified in an index template. You can use C-style `/* *\/` block comments in index templates. You can include comments anywhere in the request body, except before the opening curly bracket. **Indices matching multiple templates** Multiple index templates can potentially match an index, in this case, both the settings and mappings are merged into the final configuration of the index. The order of the merging can be controlled using the order parameter, with lower order being applied first, and higher orders overriding them. NOTE: Multiple matching templates with the same order value will result in a non-deterministic merging order. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-templates-v1.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-put-template | Elasticsearch API documentation} */ async putTemplate (this: That, params: T.IndicesPutTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putTemplate (this: That, params: T.IndicesPutTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2213,7 +2213,7 @@ export default class Indices { /** * Get index recovery information. Get information about ongoing and completed shard recoveries for one or more indices. For data streams, the API returns information for the stream's backing indices. All recoveries, whether ongoing or complete, are kept in the cluster state and may be reported on at any time. Shard recovery is the process of initializing a shard copy, such as restoring a primary shard from a snapshot or creating a replica shard from a primary shard. When a shard recovery completes, the recovered shard is available for search and indexing. Recovery automatically occurs during the following processes: * When creating an index for the first time. * When a node rejoins the cluster and starts up any missing primary shard copies using the data that it holds in its data path. * Creation of new replica shard copies from the primary. * Relocation of a shard copy to a different node in the same cluster. * A snapshot restore operation. * A clone, shrink, or split operation. You can determine the cause of a shard recovery using the recovery or cat recovery APIs. The index recovery API reports information about completed recoveries only for shard copies that currently exist in the cluster. It only reports the last recovery for each shard copy and does not report historical information about earlier recoveries, nor does it report information about the recoveries of shard copies that no longer exist. This means that if a shard copy completes a recovery and then Elasticsearch relocates it onto a different node then the information about the original recovery will not be shown in the recovery API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-recovery.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-recovery | Elasticsearch API documentation} */ async recovery (this: That, params?: T.IndicesRecoveryRequest, options?: TransportRequestOptionsWithOutMeta): Promise async recovery (this: That, params?: T.IndicesRecoveryRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2263,7 +2263,7 @@ export default class Indices { /** * Refresh an index. A refresh makes recent operations performed on one or more indices available for search. For data streams, the API runs the refresh operation on the stream’s backing indices. By default, Elasticsearch periodically refreshes indices every second, but only on indices that have received one search request or more in the last 30 seconds. You can change this default interval with the `index.refresh_interval` setting. Refresh requests are synchronous and do not return a response until the refresh operation completes. Refreshes are resource-intensive. To ensure good cluster performance, it's recommended to wait for Elasticsearch's periodic refresh rather than performing an explicit refresh when possible. If your application workflow indexes documents and then runs a search to retrieve the indexed document, it's recommended to use the index API's `refresh=wait_for` query parameter option. This option ensures the indexing operation waits for a periodic refresh before running the search. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-refresh.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-refresh | Elasticsearch API documentation} */ async refresh (this: That, params?: T.IndicesRefreshRequest, options?: TransportRequestOptionsWithOutMeta): Promise async refresh (this: That, params?: T.IndicesRefreshRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2313,7 +2313,7 @@ export default class Indices { /** * Reload search analyzers. Reload an index's search analyzers and their resources. For data streams, the API reloads search analyzers and resources for the stream's backing indices. IMPORTANT: After reloading the search analyzers you should clear the request cache to make sure it doesn't contain responses derived from the previous versions of the analyzer. You can use the reload search analyzers API to pick up changes to synonym files used in the `synonym_graph` or `synonym` token filter of a search analyzer. To be eligible, the token filter must have an `updateable` flag of `true` and only be used in search analyzers. NOTE: This API does not perform a reload for each shard of an index. Instead, it performs a reload for each node containing index shards. As a result, the total shard count returned by the API can differ from the number of index shards. Because reloading affects every node with an index shard, it is important to update the synonym file on every data node in the cluster--including nodes that don't contain a shard replica--before using this API. This ensures the synonym file is updated everywhere in the cluster in case shards are relocated in the future. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-reload-analyzers.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-reload-search-analyzers | Elasticsearch API documentation} */ async reloadSearchAnalyzers (this: That, params: T.IndicesReloadSearchAnalyzersRequest, options?: TransportRequestOptionsWithOutMeta): Promise async reloadSearchAnalyzers (this: That, params: T.IndicesReloadSearchAnalyzersRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2354,13 +2354,13 @@ export default class Indices { } /** - * Resolve the cluster. Resolve the specified index expressions to return information about each cluster, including the local cluster, if included. Multiple patterns and remote clusters are supported. This endpoint is useful before doing a cross-cluster search in order to determine which remote clusters should be included in a search. You use the same index expression with this endpoint as you would for cross-cluster search. Index and cluster exclusions are also supported with this endpoint. For each cluster in the index expression, information is returned about: * Whether the querying ("local") cluster is currently connected to each remote cluster in the index expression scope. * Whether each remote cluster is configured with `skip_unavailable` as `true` or `false`. * Whether there are any indices, aliases, or data streams on that cluster that match the index expression. * Whether the search is likely to have errors returned when you do the cross-cluster search (including any authorization errors if you do not have permission to query the index). * Cluster version information, including the Elasticsearch server version. For example, `GET /_resolve/cluster/my-index-*,cluster*:my-index-*` returns information about the local cluster and all remotely configured clusters that start with the alias `cluster*`. Each cluster returns information about whether it has any indices, aliases or data streams that match `my-index-*`. **Advantages of using this endpoint before a cross-cluster search** You may want to exclude a cluster or index from a search when: * A remote cluster is not currently connected and is configured with `skip_unavailable=false`. Running a cross-cluster search under those conditions will cause the entire search to fail. * A cluster has no matching indices, aliases or data streams for the index expression (or your user does not have permissions to search them). For example, suppose your index expression is `logs*,remote1:logs*` and the remote1 cluster has no indices, aliases or data streams that match `logs*`. In that case, that cluster will return no results from that cluster if you include it in a cross-cluster search. * The index expression (combined with any query parameters you specify) will likely cause an exception to be thrown when you do the search. In these cases, the "error" field in the `_resolve/cluster` response will be present. (This is also where security/permission errors will be shown.) * A remote cluster is an older version that does not support the feature you want to use in your search. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-resolve-cluster-api.html | Elasticsearch API documentation} + * Resolve the cluster. Resolve the specified index expressions to return information about each cluster, including the local "querying" cluster, if included. If no index expression is provided, the API will return information about all the remote clusters that are configured on the querying cluster. This endpoint is useful before doing a cross-cluster search in order to determine which remote clusters should be included in a search. You use the same index expression with this endpoint as you would for cross-cluster search. Index and cluster exclusions are also supported with this endpoint. For each cluster in the index expression, information is returned about: * Whether the querying ("local") cluster is currently connected to each remote cluster specified in the index expression. Note that this endpoint actively attempts to contact the remote clusters, unlike the `remote/info` endpoint. * Whether each remote cluster is configured with `skip_unavailable` as `true` or `false`. * Whether there are any indices, aliases, or data streams on that cluster that match the index expression. * Whether the search is likely to have errors returned when you do the cross-cluster search (including any authorization errors if you do not have permission to query the index). * Cluster version information, including the Elasticsearch server version. For example, `GET /_resolve/cluster/my-index-*,cluster*:my-index-*` returns information about the local cluster and all remotely configured clusters that start with the alias `cluster*`. Each cluster returns information about whether it has any indices, aliases or data streams that match `my-index-*`. ## Note on backwards compatibility The ability to query without an index expression was added in version 8.18, so when querying remote clusters older than that, the local cluster will send the index expression `dummy*` to those remote clusters. Thus, if an errors occur, you may see a reference to that index expression even though you didn't request it. If it causes a problem, you can instead include an index expression like `*:*` to bypass the issue. ## Advantages of using this endpoint before a cross-cluster search You may want to exclude a cluster or index from a search when: * A remote cluster is not currently connected and is configured with `skip_unavailable=false`. Running a cross-cluster search under those conditions will cause the entire search to fail. * A cluster has no matching indices, aliases or data streams for the index expression (or your user does not have permissions to search them). For example, suppose your index expression is `logs*,remote1:logs*` and the remote1 cluster has no indices, aliases or data streams that match `logs*`. In that case, that cluster will return no results from that cluster if you include it in a cross-cluster search. * The index expression (combined with any query parameters you specify) will likely cause an exception to be thrown when you do the search. In these cases, the "error" field in the `_resolve/cluster` response will be present. (This is also where security/permission errors will be shown.) * A remote cluster is an older version that does not support the feature you want to use in your search. ## Test availability of remote clusters The `remote/info` endpoint is commonly used to test whether the "local" cluster (the cluster being queried) is connected to its remote clusters, but it does not necessarily reflect whether the remote cluster is available or not. The remote cluster may be available, while the local cluster is not currently connected to it. You can use the `_resolve/cluster` API to attempt to reconnect to remote clusters. For example with `GET _resolve/cluster` or `GET _resolve/cluster/*:*`. The `connected` field in the response will indicate whether it was successful. If a connection was (re-)established, this will also cause the `remote/info` endpoint to now indicate a connected status. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-resolve-cluster | Elasticsearch API documentation} */ - async resolveCluster (this: That, params: T.IndicesResolveClusterRequest, options?: TransportRequestOptionsWithOutMeta): Promise - async resolveCluster (this: That, params: T.IndicesResolveClusterRequest, options?: TransportRequestOptionsWithMeta): Promise> - async resolveCluster (this: That, params: T.IndicesResolveClusterRequest, options?: TransportRequestOptions): Promise - async resolveCluster (this: That, params: T.IndicesResolveClusterRequest, options?: TransportRequestOptions): Promise { + async resolveCluster (this: That, params?: T.IndicesResolveClusterRequest, options?: TransportRequestOptionsWithOutMeta): Promise + async resolveCluster (this: That, params?: T.IndicesResolveClusterRequest, options?: TransportRequestOptionsWithMeta): Promise> + async resolveCluster (this: That, params?: T.IndicesResolveClusterRequest, options?: TransportRequestOptions): Promise + async resolveCluster (this: That, params?: T.IndicesResolveClusterRequest, options?: TransportRequestOptions): Promise { const acceptedPath: string[] = ['name'] const userQuery = params?.querystring const querystring: Record = userQuery != null ? { ...userQuery } : {} @@ -2375,6 +2375,7 @@ export default class Indices { } } + params = params ?? {} for (const key in params) { if (acceptedPath.includes(key)) { continue @@ -2384,8 +2385,15 @@ export default class Indices { } } - const method = 'GET' - const path = `/_resolve/cluster/${encodeURIComponent(params.name.toString())}` + let method = '' + let path = '' + if (params.name != null) { + method = 'GET' + path = `/_resolve/cluster/${encodeURIComponent(params.name.toString())}` + } else { + method = 'GET' + path = '/_resolve/cluster' + } const meta: TransportRequestMetadata = { name: 'indices.resolve_cluster', pathParts: { @@ -2397,7 +2405,7 @@ export default class Indices { /** * Resolve indices. Resolve the names and/or index patterns for indices, aliases, and data streams. Multiple patterns and remote clusters are supported. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-resolve-index-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-resolve-index | Elasticsearch API documentation} */ async resolveIndex (this: That, params: T.IndicesResolveIndexRequest, options?: TransportRequestOptionsWithOutMeta): Promise async resolveIndex (this: That, params: T.IndicesResolveIndexRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2439,7 +2447,7 @@ export default class Indices { /** * Roll over to a new index. TIP: It is recommended to use the index lifecycle rollover action to automate rollovers. The rollover API creates a new index for a data stream or index alias. The API behavior depends on the rollover target. **Roll over a data stream** If you roll over a data stream, the API creates a new write index for the stream. The stream's previous write index becomes a regular backing index. A rollover also increments the data stream's generation. **Roll over an index alias with a write index** TIP: Prior to Elasticsearch 7.9, you'd typically use an index alias with a write index to manage time series data. Data streams replace this functionality, require less maintenance, and automatically integrate with data tiers. If an index alias points to multiple indices, one of the indices must be a write index. The rollover API creates a new write index for the alias with `is_write_index` set to `true`. The API also `sets is_write_index` to `false` for the previous write index. **Roll over an index alias with one index** If you roll over an index alias that points to only one index, the API creates a new index for the alias and removes the original index from the alias. NOTE: A rollover creates a new index and is subject to the `wait_for_active_shards` setting. **Increment index names for an alias** When you roll over an index alias, you can specify a name for the new index. If you don't specify a name and the current index ends with `-` and a number, such as `my-index-000001` or `my-index-3`, the new index name increments that number. For example, if you roll over an alias with a current index of `my-index-000001`, the rollover creates a new index named `my-index-000002`. This number is always six characters and zero-padded, regardless of the previous index's name. If you use an index alias for time series data, you can use date math in the index name to track the rollover date. For example, you can create an alias that points to an index named ``. If you create the index on May 6, 2099, the index's name is `my-index-2099.05.06-000001`. If you roll over the alias on May 7, 2099, the new index's name is `my-index-2099.05.07-000002`. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-rollover-index.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-rollover | Elasticsearch API documentation} */ async rollover (this: That, params: T.IndicesRolloverRequest, options?: TransportRequestOptionsWithOutMeta): Promise async rollover (this: That, params: T.IndicesRolloverRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2494,7 +2502,7 @@ export default class Indices { /** * Get index segments. Get low-level information about the Lucene segments in index shards. For data streams, the API returns information about the stream's backing indices. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-segments.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-segments | Elasticsearch API documentation} */ async segments (this: That, params?: T.IndicesSegmentsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async segments (this: That, params?: T.IndicesSegmentsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2544,7 +2552,7 @@ export default class Indices { /** * Get index shard stores. Get store information about replica shards in one or more indices. For data streams, the API retrieves store information for the stream's backing indices. The index shard stores API returns the following information: * The node on which each replica shard exists. * The allocation ID for each replica shard. * A unique ID for each replica shard. * Any errors encountered while opening the shard index or from an earlier failure. By default, the API returns store information only for primary shards that are unassigned or have one or more unassigned replica shards. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-shards-stores.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-shard-stores | Elasticsearch API documentation} */ async shardStores (this: That, params?: T.IndicesShardStoresRequest, options?: TransportRequestOptionsWithOutMeta): Promise async shardStores (this: That, params?: T.IndicesShardStoresRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2594,7 +2602,7 @@ export default class Indices { /** * Shrink an index. Shrink an index into a new index with fewer primary shards. Before you can shrink an index: * The index must be read-only. * A copy of every shard in the index must reside on the same node. * The index must have a green health status. To make shard allocation easier, we recommend you also remove the index's replica shards. You can later re-add replica shards as part of the shrink operation. The requested number of primary shards in the target index must be a factor of the number of shards in the source index. For example an index with 8 primary shards can be shrunk into 4, 2 or 1 primary shards or an index with 15 primary shards can be shrunk into 5, 3 or 1. If the number of shards in the index is a prime number it can only be shrunk into a single primary shard Before shrinking, a (primary or replica) copy of every shard in the index must be present on the same node. The current write index on a data stream cannot be shrunk. In order to shrink the current write index, the data stream must first be rolled over so that a new write index is created and then the previous write index can be shrunk. A shrink operation: * Creates a new target index with the same definition as the source index, but with a smaller number of primary shards. * Hard-links segments from the source index into the target index. If the file system does not support hard-linking, then all segments are copied into the new index, which is a much more time consuming process. Also if using multiple data paths, shards on different data paths require a full copy of segment files if they are not on the same disk since hardlinks do not work across disks. * Recovers the target index as though it were a closed index which had just been re-opened. Recovers shards to the `.routing.allocation.initial_recovery._id` index setting. IMPORTANT: Indices can only be shrunk if they satisfy the following requirements: * The target index must not exist. * The source index must have more primary shards than the target index. * The number of primary shards in the target index must be a factor of the number of primary shards in the source index. The source index must have more primary shards than the target index. * The index must not contain more than 2,147,483,519 documents in total across all shards that will be shrunk into a single shard on the target index as this is the maximum number of docs that can fit into a single shard. * The node handling the shrink process must have sufficient free disk space to accommodate a second copy of the existing index. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-shrink-index.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-shrink | Elasticsearch API documentation} */ async shrink (this: That, params: T.IndicesShrinkRequest, options?: TransportRequestOptionsWithOutMeta): Promise async shrink (this: That, params: T.IndicesShrinkRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2642,7 +2650,7 @@ export default class Indices { /** * Simulate an index. Get the index configuration that would be applied to the specified index from an existing index template. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-simulate-index.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-simulate-index-template | Elasticsearch API documentation} */ async simulateIndexTemplate (this: That, params: T.IndicesSimulateIndexTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async simulateIndexTemplate (this: That, params: T.IndicesSimulateIndexTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2684,7 +2692,7 @@ export default class Indices { /** * Simulate an index template. Get the index configuration that would be applied by a particular index template. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-simulate-template.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-simulate-template | Elasticsearch API documentation} */ async simulateTemplate (this: That, params?: T.IndicesSimulateTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async simulateTemplate (this: That, params?: T.IndicesSimulateTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2739,7 +2747,7 @@ export default class Indices { /** * Split an index. Split an index into a new index with more primary shards. * Before you can split an index: * The index must be read-only. * The cluster health status must be green. You can do make an index read-only with the following request using the add index block API: ``` PUT /my_source_index/_block/write ``` The current write index on a data stream cannot be split. In order to split the current write index, the data stream must first be rolled over so that a new write index is created and then the previous write index can be split. The number of times the index can be split (and the number of shards that each original shard can be split into) is determined by the `index.number_of_routing_shards` setting. The number of routing shards specifies the hashing space that is used internally to distribute documents across shards with consistent hashing. For instance, a 5 shard index with `number_of_routing_shards` set to 30 (5 x 2 x 3) could be split by a factor of 2 or 3. A split operation: * Creates a new target index with the same definition as the source index, but with a larger number of primary shards. * Hard-links segments from the source index into the target index. If the file system doesn't support hard-linking, all segments are copied into the new index, which is a much more time consuming process. * Hashes all documents again, after low level files are created, to delete documents that belong to a different shard. * Recovers the target index as though it were a closed index which had just been re-opened. IMPORTANT: Indices can only be split if they satisfy the following requirements: * The target index must not exist. * The source index must have fewer primary shards than the target index. * The number of primary shards in the target index must be a multiple of the number of primary shards in the source index. * The node handling the split process must have sufficient free disk space to accommodate a second copy of the existing index. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-split-index.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-split | Elasticsearch API documentation} */ async split (this: That, params: T.IndicesSplitRequest, options?: TransportRequestOptionsWithOutMeta): Promise async split (this: That, params: T.IndicesSplitRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2787,7 +2795,7 @@ export default class Indices { /** * Get index statistics. For data streams, the API retrieves statistics for the stream's backing indices. By default, the returned statistics are index-level with `primaries` and `total` aggregations. `primaries` are the values for only the primary shards. `total` are the accumulated values for both primary and replica shards. To get shard-level statistics, set the `level` parameter to `shards`. NOTE: When moving to another node, the shard-level statistics for a shard are cleared. Although the shard is no longer part of the node, that node retains any node-level statistics to which the shard contributed. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-indices-stats | Elasticsearch API documentation} */ async stats (this: That, params?: T.IndicesStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stats (this: That, params?: T.IndicesStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/inference.ts b/src/api/api/inference.ts index 6bdede5f1..b7c9fb55a 100644 --- a/src/api/api/inference.ts +++ b/src/api/api/inference.ts @@ -45,7 +45,7 @@ export default class Inference { /** * Delete an inference endpoint - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-inference-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-inference-delete | Elasticsearch API documentation} */ async delete (this: That, params: T.InferenceDeleteRequest, options?: TransportRequestOptionsWithOutMeta): Promise async delete (this: That, params: T.InferenceDeleteRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -95,7 +95,7 @@ export default class Inference { /** * Get an inference endpoint - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-inference-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-inference-get | Elasticsearch API documentation} */ async get (this: That, params?: T.InferenceGetRequest, options?: TransportRequestOptionsWithOutMeta): Promise async get (this: That, params?: T.InferenceGetRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -148,8 +148,8 @@ export default class Inference { } /** - * Perform inference on the service - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/post-inference-api.html | Elasticsearch API documentation} + * Perform inference on the service. This API enables you to use machine learning models to perform specific tasks on data that you provide as an input. It returns a response with the results of the tasks. The inference endpoint you use can perform one specific task that has been defined when the endpoint was created with the create inference API. > info > The inference APIs enable you to use certain services, such as built-in machine learning models (ELSER, E5), models uploaded through Eland, Cohere, OpenAI, Azure, Google AI Studio, Google Vertex AI, Anthropic, Watsonx.ai, or Hugging Face. For built-in models and models uploaded through Eland, the inference APIs offer an alternative way to use and manage trained models. However, if you do not plan to use the inference APIs to use these models or if you want to use non-NLP models, use the machine learning trained model APIs. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-inference-inference | Elasticsearch API documentation} */ async inference (this: That, params: T.InferenceInferenceRequest, options?: TransportRequestOptionsWithOutMeta): Promise async inference (this: That, params: T.InferenceInferenceRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -204,7 +204,7 @@ export default class Inference { /** * Create an inference endpoint. When you create an inference endpoint, the associated machine learning model is automatically deployed if it is not already running. After creating the endpoint, wait for the model deployment to complete before using it. To verify the deployment status, use the get trained model statistics API. Look for `"state": "fully_allocated"` in the response and ensure that the `"allocation_count"` matches the `"target_allocation_count"`. Avoid creating multiple endpoints for the same model unless required, as each endpoint consumes significant resources. IMPORTANT: The inference APIs enable you to use certain services, such as built-in machine learning models (ELSER, E5), models uploaded through Eland, Cohere, OpenAI, Mistral, Azure OpenAI, Google AI Studio, Google Vertex AI, Anthropic, Watsonx.ai, or Hugging Face. For built-in models and models uploaded through Eland, the inference APIs offer an alternative way to use and manage trained models. However, if you do not plan to use the inference APIs to use these models or if you want to use non-NLP models, use the machine learning trained model APIs. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-inference-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-inference-put | Elasticsearch API documentation} */ async put (this: That, params: T.InferencePutRequest, options?: TransportRequestOptionsWithOutMeta): Promise async put (this: That, params: T.InferencePutRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -249,7 +249,7 @@ export default class Inference { /** * Perform streaming inference. Get real-time responses for completion tasks by delivering answers incrementally, reducing response times during computation. This API works only with the completion task type. IMPORTANT: The inference APIs enable you to use certain services, such as built-in machine learning models (ELSER, E5), models uploaded through Eland, Cohere, OpenAI, Azure, Google AI Studio, Google Vertex AI, Anthropic, Watsonx.ai, or Hugging Face. For built-in models and models uploaded through Eland, the inference APIs offer an alternative way to use and manage trained models. However, if you do not plan to use the inference APIs to use these models or if you want to use non-NLP models, use the machine learning trained model APIs. This API requires the `monitor_inference` cluster privilege (the built-in `inference_admin` and `inference_user` roles grant this privilege). You must use a client that supports streaming. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/stream-inference-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-inference-stream-inference | Elasticsearch API documentation} */ async streamInference (this: That, params: T.InferenceStreamInferenceRequest, options?: TransportRequestOptionsWithOutMeta): Promise async streamInference (this: That, params: T.InferenceStreamInferenceRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -359,7 +359,7 @@ export default class Inference { /** * Update an inference endpoint. Modify `task_settings`, secrets (within `service_settings`), or `num_allocations` for an inference endpoint, depending on the specific endpoint service and `task_type`. IMPORTANT: The inference APIs enable you to use certain services, such as built-in machine learning models (ELSER, E5), models uploaded through Eland, Cohere, OpenAI, Azure, Google AI Studio, Google Vertex AI, Anthropic, Watsonx.ai, or Hugging Face. For built-in models and models uploaded through Eland, the inference APIs offer an alternative way to use and manage trained models. However, if you do not plan to use the inference APIs to use these models or if you want to use non-NLP models, use the machine learning trained model APIs. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-inference-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-inference-update | Elasticsearch API documentation} */ async update (this: That, params: T.InferenceUpdateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async update (this: That, params: T.InferenceUpdateRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/info.ts b/src/api/api/info.ts index 0c1bf083d..1681fe6f3 100644 --- a/src/api/api/info.ts +++ b/src/api/api/info.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Get cluster info. Get basic build, version, and cluster information. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/rest-api-root.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-info | Elasticsearch API documentation} */ export default async function InfoApi (this: That, params?: T.InfoRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function InfoApi (this: That, params?: T.InfoRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/ingest.ts b/src/api/api/ingest.ts index f691fb5b5..51ad39aff 100644 --- a/src/api/api/ingest.ts +++ b/src/api/api/ingest.ts @@ -45,7 +45,7 @@ export default class Ingest { /** * Delete GeoIP database configurations. Delete one or more IP geolocation database configurations. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-geoip-database-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-delete-geoip-database | Elasticsearch API documentation} */ async deleteGeoipDatabase (this: That, params: T.IngestDeleteGeoipDatabaseRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteGeoipDatabase (this: That, params: T.IngestDeleteGeoipDatabaseRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class Ingest { /** * Delete IP geolocation database configurations. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-ip-location-database-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-delete-ip-location-database | Elasticsearch API documentation} */ async deleteIpLocationDatabase (this: That, params: T.IngestDeleteIpLocationDatabaseRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteIpLocationDatabase (this: That, params: T.IngestDeleteIpLocationDatabaseRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -129,7 +129,7 @@ export default class Ingest { /** * Delete pipelines. Delete one or more ingest pipelines. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-pipeline-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-delete-pipeline | Elasticsearch API documentation} */ async deletePipeline (this: That, params: T.IngestDeletePipelineRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deletePipeline (this: That, params: T.IngestDeletePipelineRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -211,7 +211,7 @@ export default class Ingest { /** * Get GeoIP database configurations. Get information about one or more IP geolocation database configurations. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-geoip-database-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-get-geoip-database | Elasticsearch API documentation} */ async getGeoipDatabase (this: That, params?: T.IngestGetGeoipDatabaseRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getGeoipDatabase (this: That, params?: T.IngestGetGeoipDatabaseRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -261,7 +261,7 @@ export default class Ingest { /** * Get IP geolocation database configurations. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-ip-location-database-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-get-ip-location-database | Elasticsearch API documentation} */ async getIpLocationDatabase (this: That, params?: T.IngestGetIpLocationDatabaseRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getIpLocationDatabase (this: That, params?: T.IngestGetIpLocationDatabaseRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -311,7 +311,7 @@ export default class Ingest { /** * Get pipelines. Get information about one or more ingest pipelines. This API returns a local reference of the pipeline. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-pipeline-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-get-pipeline | Elasticsearch API documentation} */ async getPipeline (this: That, params?: T.IngestGetPipelineRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getPipeline (this: That, params?: T.IngestGetPipelineRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -401,7 +401,7 @@ export default class Ingest { /** * Create or update a GeoIP database configuration. Refer to the create or update IP geolocation database configuration API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-geoip-database-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-put-geoip-database | Elasticsearch API documentation} */ async putGeoipDatabase (this: That, params: T.IngestPutGeoipDatabaseRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putGeoipDatabase (this: That, params: T.IngestPutGeoipDatabaseRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -448,7 +448,7 @@ export default class Ingest { /** * Create or update an IP geolocation database configuration. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-ip-location-database-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-put-ip-location-database | Elasticsearch API documentation} */ async putIpLocationDatabase (this: That, params: T.IngestPutIpLocationDatabaseRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putIpLocationDatabase (this: That, params: T.IngestPutIpLocationDatabaseRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -532,7 +532,7 @@ export default class Ingest { /** * Simulate a pipeline. Run an ingest pipeline against a set of provided documents. You can either specify an existing pipeline to use with the provided documents or supply a pipeline definition in the body of the request. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/simulate-pipeline-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ingest-simulate | Elasticsearch API documentation} */ async simulate (this: That, params: T.IngestSimulateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async simulate (this: That, params: T.IngestSimulateRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/knn_search.ts b/src/api/api/knn_search.ts index e23a2d87a..d1a319461 100644 --- a/src/api/api/knn_search.ts +++ b/src/api/api/knn_search.ts @@ -38,8 +38,8 @@ import * as T from '../types' interface That { transport: Transport } /** - * Run a knn search. NOTE: The kNN search API has been replaced by the `knn` option in the search API. Perform a k-nearest neighbor (kNN) search on a dense_vector field and return the matching documents. Given a query vector, the API finds the k closest vectors and returns those documents as search hits. Elasticsearch uses the HNSW algorithm to support efficient kNN search. Like most kNN algorithms, HNSW is an approximate method that sacrifices result accuracy for improved search speed. This means the results returned are not always the true k closest neighbors. The kNN search API supports restricting the search using a filter. The search will return the top k documents that also match the filter query. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-search.html | Elasticsearch API documentation} + * Run a knn search. NOTE: The kNN search API has been replaced by the `knn` option in the search API. Perform a k-nearest neighbor (kNN) search on a dense_vector field and return the matching documents. Given a query vector, the API finds the k closest vectors and returns those documents as search hits. Elasticsearch uses the HNSW algorithm to support efficient kNN search. Like most kNN algorithms, HNSW is an approximate method that sacrifices result accuracy for improved search speed. This means the results returned are not always the true k closest neighbors. The kNN search API supports restricting the search using a filter. The search will return the top k documents that also match the filter query. A kNN search response has the exact same structure as a search API response. However, certain sections have a meaning specific to kNN search: * The document `_score` is determined by the similarity between the query and document vector. * The `hits.total` object contains the total number of nearest neighbor candidates considered, which is `num_candidates * num_shards`. The `hits.total.relation` will always be `eq`, indicating an exact value. + * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/knn-search-api.html | Elasticsearch API documentation} */ export default async function KnnSearchApi (this: That, params: T.KnnSearchRequest, options?: TransportRequestOptionsWithOutMeta): Promise> export default async function KnnSearchApi (this: That, params: T.KnnSearchRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/license.ts b/src/api/api/license.ts index 852661841..b80733dd9 100644 --- a/src/api/api/license.ts +++ b/src/api/api/license.ts @@ -45,7 +45,7 @@ export default class License { /** * Delete the license. When the license expires, your subscription level reverts to Basic. If the operator privileges feature is enabled, only operator users can use this API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-license.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-delete | Elasticsearch API documentation} */ async delete (this: That, params?: T.LicenseDeleteRequest, options?: TransportRequestOptionsWithOutMeta): Promise async delete (this: That, params?: T.LicenseDeleteRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -84,8 +84,8 @@ export default class License { } /** - * Get license information. Get information about your Elastic license including its type, its status, when it was issued, and when it expires. NOTE: If the master node is generating a new cluster state, the get license API may return a `404 Not Found` response. If you receive an unexpected 404 response after cluster startup, wait a short period and retry the request. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-license.html | Elasticsearch API documentation} + * Get license information. Get information about your Elastic license including its type, its status, when it was issued, and when it expires. >info > If the master node is generating a new cluster state, the get license API may return a `404 Not Found` response. > If you receive an unexpected 404 response after cluster startup, wait a short period and retry the request. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-get | Elasticsearch API documentation} */ async get (this: That, params?: T.LicenseGetRequest, options?: TransportRequestOptionsWithOutMeta): Promise async get (this: That, params?: T.LicenseGetRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -125,7 +125,7 @@ export default class License { /** * Get the basic license status. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-basic-status.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-get-basic-status | Elasticsearch API documentation} */ async getBasicStatus (this: That, params?: T.LicenseGetBasicStatusRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getBasicStatus (this: That, params?: T.LicenseGetBasicStatusRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -165,7 +165,7 @@ export default class License { /** * Get the trial status. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-trial-status.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-get-trial-status | Elasticsearch API documentation} */ async getTrialStatus (this: That, params?: T.LicenseGetTrialStatusRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getTrialStatus (this: That, params?: T.LicenseGetTrialStatusRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -205,7 +205,7 @@ export default class License { /** * Update the license. You can update your license at runtime without shutting down your nodes. License updates take effect immediately. If the license you are installing does not support all of the features that were available with your previous license, however, you are notified in the response. You must then re-submit the API request with the acknowledge parameter set to true. NOTE: If Elasticsearch security features are enabled and you are installing a gold or higher license, you must enable TLS on the transport networking layer before you install the license. If the operator privileges feature is enabled, only operator users can use this API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-license.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-post | Elasticsearch API documentation} */ async post (this: That, params?: T.LicensePostRequest, options?: TransportRequestOptionsWithOutMeta): Promise async post (this: That, params?: T.LicensePostRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -250,7 +250,7 @@ export default class License { /** * Start a basic license. Start an indefinite basic license, which gives access to all the basic features. NOTE: In order to start a basic license, you must not currently have a basic license. If the basic license does not support all of the features that are available with your current license, however, you are notified in the response. You must then re-submit the API request with the `acknowledge` parameter set to `true`. To check the status of your basic license, use the get basic license API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/start-basic.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-post-start-basic | Elasticsearch API documentation} */ async postStartBasic (this: That, params?: T.LicensePostStartBasicRequest, options?: TransportRequestOptionsWithOutMeta): Promise async postStartBasic (this: That, params?: T.LicensePostStartBasicRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -290,7 +290,7 @@ export default class License { /** * Start a trial. Start a 30-day trial, which gives access to all subscription features. NOTE: You are allowed to start a trial only if your cluster has not already activated a trial for the current major product version. For example, if you have already activated a trial for v8.0, you cannot start a new trial until v9.0. You can, however, request an extended trial at https://www.elastic.co/trialextension. To check the status of your trial, use the get trial status API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/start-trial.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-post-start-trial | Elasticsearch API documentation} */ async postStartTrial (this: That, params?: T.LicensePostStartTrialRequest, options?: TransportRequestOptionsWithOutMeta): Promise async postStartTrial (this: That, params?: T.LicensePostStartTrialRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/logstash.ts b/src/api/api/logstash.ts index 559b10011..df33e03ac 100644 --- a/src/api/api/logstash.ts +++ b/src/api/api/logstash.ts @@ -45,7 +45,7 @@ export default class Logstash { /** * Delete a Logstash pipeline. Delete a pipeline that is used for Logstash Central Management. If the request succeeds, you receive an empty response with an appropriate status code. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/logstash-api-delete-pipeline.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-logstash-delete-pipeline | Elasticsearch API documentation} */ async deletePipeline (this: That, params: T.LogstashDeletePipelineRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deletePipeline (this: That, params: T.LogstashDeletePipelineRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class Logstash { /** * Get Logstash pipelines. Get pipelines that are used for Logstash Central Management. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/logstash-api-get-pipeline.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-logstash-get-pipeline | Elasticsearch API documentation} */ async getPipeline (this: That, params?: T.LogstashGetPipelineRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getPipeline (this: That, params?: T.LogstashGetPipelineRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -137,7 +137,7 @@ export default class Logstash { /** * Create or update a Logstash pipeline. Create a pipeline that is used for Logstash Central Management. If the specified pipeline exists, it is replaced. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/logstash-api-put-pipeline.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-logstash-put-pipeline | Elasticsearch API documentation} */ async putPipeline (this: That, params: T.LogstashPutPipelineRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putPipeline (this: That, params: T.LogstashPutPipelineRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/mget.ts b/src/api/api/mget.ts index 62f275d77..c254d5fd8 100644 --- a/src/api/api/mget.ts +++ b/src/api/api/mget.ts @@ -38,8 +38,8 @@ import * as T from '../types' interface That { transport: Transport } /** - * Get multiple documents. Get multiple JSON documents by ID from one or more indices. If you specify an index in the request URI, you only need to specify the document IDs in the request body. To ensure fast responses, this multi get (mget) API responds with partial results if one or more shards fail. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-multi-get.html | Elasticsearch API documentation} + * Get multiple documents. Get multiple JSON documents by ID from one or more indices. If you specify an index in the request URI, you only need to specify the document IDs in the request body. To ensure fast responses, this multi get (mget) API responds with partial results if one or more shards fail. **Filter source fields** By default, the `_source` field is returned for every document (if stored). Use the `_source` and `_source_include` or `source_exclude` attributes to filter what fields are returned for a particular document. You can include the `_source`, `_source_includes`, and `_source_excludes` query parameters in the request URI to specify the defaults to use when there are no per-document instructions. **Get stored fields** Use the `stored_fields` attribute to specify the set of stored fields you want to retrieve. Any requested fields that are not stored are ignored. You can include the `stored_fields` query parameter in the request URI to specify the defaults to use when there are no per-document instructions. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-mget | Elasticsearch API documentation} */ export default async function MgetApi (this: That, params?: T.MgetRequest, options?: TransportRequestOptionsWithOutMeta): Promise> export default async function MgetApi (this: That, params?: T.MgetRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/migration.ts b/src/api/api/migration.ts index 49fed1c3b..5ddf19b7d 100644 --- a/src/api/api/migration.ts +++ b/src/api/api/migration.ts @@ -45,7 +45,7 @@ export default class Migration { /** * Get deprecation information. Get information about different cluster, node, and index level settings that use deprecated features that will be removed or changed in the next major version. TIP: This APIs is designed for indirect use by the Upgrade Assistant. You are strongly recommended to use the Upgrade Assistant. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/migration-api-deprecation.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-migration-deprecations | Elasticsearch API documentation} */ async deprecations (this: That, params?: T.MigrationDeprecationsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deprecations (this: That, params?: T.MigrationDeprecationsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -95,7 +95,7 @@ export default class Migration { /** * Get feature migration information. Version upgrades sometimes require changes to how features store configuration information and data in system indices. Check which features need to be migrated and the status of any migrations that are in progress. TIP: This API is designed for indirect use by the Upgrade Assistant. You are strongly recommended to use the Upgrade Assistant. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/feature-migration-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-migration-get-feature-upgrade-status | Elasticsearch API documentation} */ async getFeatureUpgradeStatus (this: That, params?: T.MigrationGetFeatureUpgradeStatusRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getFeatureUpgradeStatus (this: That, params?: T.MigrationGetFeatureUpgradeStatusRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -135,7 +135,7 @@ export default class Migration { /** * Start the feature migration. Version upgrades sometimes require changes to how features store configuration information and data in system indices. This API starts the automatic migration process. Some functionality might be temporarily unavailable during the migration process. TIP: The API is designed for indirect use by the Upgrade Assistant. We strongly recommend you use the Upgrade Assistant. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/feature-migration-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-migration-get-feature-upgrade-status | Elasticsearch API documentation} */ async postFeatureUpgrade (this: That, params?: T.MigrationPostFeatureUpgradeRequest, options?: TransportRequestOptionsWithOutMeta): Promise async postFeatureUpgrade (this: That, params?: T.MigrationPostFeatureUpgradeRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/ml.ts b/src/api/api/ml.ts index 1dbc32a63..52548d378 100644 --- a/src/api/api/ml.ts +++ b/src/api/api/ml.ts @@ -45,7 +45,7 @@ export default class Ml { /** * Clear trained model deployment cache. Cache will be cleared on all nodes where the trained model is assigned. A trained model deployment may have an inference cache enabled. As requests are handled by each allocated node, their responses may be cached on that individual node. Calling this API clears the caches without restarting the deployment. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/clear-trained-model-deployment-cache.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-clear-trained-model-deployment-cache | Elasticsearch API documentation} */ async clearTrainedModelDeploymentCache (this: That, params: T.MlClearTrainedModelDeploymentCacheRequest, options?: TransportRequestOptionsWithOutMeta): Promise async clearTrainedModelDeploymentCache (this: That, params: T.MlClearTrainedModelDeploymentCacheRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class Ml { /** * Close anomaly detection jobs. A job can be opened and closed multiple times throughout its lifecycle. A closed job cannot receive data or perform analysis operations, but you can still explore and navigate results. When you close a job, it runs housekeeping tasks such as pruning the model history, flushing buffers, calculating final results and persisting the model snapshots. Depending upon the size of the job, it could take several minutes to close and the equivalent time to re-open. After it is closed, the job has a minimal overhead on the cluster except for maintaining its meta data. Therefore it is a best practice to close jobs that are no longer required to process data. If you close an anomaly detection job whose datafeed is running, the request first tries to stop the datafeed. This behavior is equivalent to calling stop datafeed API with the same timeout and force parameters as the close job request. When a datafeed that has a specified end date stops, it automatically closes its associated job. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-close-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-close-job | Elasticsearch API documentation} */ async closeJob (this: That, params: T.MlCloseJobRequest, options?: TransportRequestOptionsWithOutMeta): Promise async closeJob (this: That, params: T.MlCloseJobRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -133,8 +133,8 @@ export default class Ml { } /** - * Delete a calendar. Removes all scheduled events from a calendar, then deletes it. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-delete-calendar.html | Elasticsearch API documentation} + * Delete a calendar. Remove all scheduled events from a calendar, then delete it. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-calendar | Elasticsearch API documentation} */ async deleteCalendar (this: That, params: T.MlDeleteCalendarRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteCalendar (this: That, params: T.MlDeleteCalendarRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -176,7 +176,7 @@ export default class Ml { /** * Delete events from a calendar. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-delete-calendar-event.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-calendar-event | Elasticsearch API documentation} */ async deleteCalendarEvent (this: That, params: T.MlDeleteCalendarEventRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteCalendarEvent (this: That, params: T.MlDeleteCalendarEventRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -219,7 +219,7 @@ export default class Ml { /** * Delete anomaly jobs from a calendar. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-delete-calendar-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-calendar-job | Elasticsearch API documentation} */ async deleteCalendarJob (this: That, params: T.MlDeleteCalendarJobRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteCalendarJob (this: That, params: T.MlDeleteCalendarJobRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -262,7 +262,7 @@ export default class Ml { /** * Delete a data frame analytics job. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-dfanalytics.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-data-frame-analytics | Elasticsearch API documentation} */ async deleteDataFrameAnalytics (this: That, params: T.MlDeleteDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteDataFrameAnalytics (this: That, params: T.MlDeleteDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -304,7 +304,7 @@ export default class Ml { /** * Delete a datafeed. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-delete-datafeed.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-datafeed | Elasticsearch API documentation} */ async deleteDatafeed (this: That, params: T.MlDeleteDatafeedRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteDatafeed (this: That, params: T.MlDeleteDatafeedRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -345,8 +345,8 @@ export default class Ml { } /** - * Delete expired ML data. Deletes all job results, model snapshots and forecast data that have exceeded their retention days period. Machine learning state documents that are not associated with any job are also deleted. You can limit the request to a single or set of anomaly detection jobs by using a job identifier, a group name, a comma-separated list of jobs, or a wildcard expression. You can delete expired data for all anomaly detection jobs by using _all, by specifying * as the , or by omitting the . - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-delete-expired-data.html | Elasticsearch API documentation} + * Delete expired ML data. Delete all job results, model snapshots and forecast data that have exceeded their retention days period. Machine learning state documents that are not associated with any job are also deleted. You can limit the request to a single or set of anomaly detection jobs by using a job identifier, a group name, a comma-separated list of jobs, or a wildcard expression. You can delete expired data for all anomaly detection jobs by using `_all`, by specifying `*` as the ``, or by omitting the ``. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-expired-data | Elasticsearch API documentation} */ async deleteExpiredData (this: That, params?: T.MlDeleteExpiredDataRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteExpiredData (this: That, params?: T.MlDeleteExpiredDataRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -401,7 +401,7 @@ export default class Ml { /** * Delete a filter. If an anomaly detection job references the filter, you cannot delete the filter. You must update or delete the job before you can delete the filter. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-delete-filter.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-filter | Elasticsearch API documentation} */ async deleteFilter (this: That, params: T.MlDeleteFilterRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteFilter (this: That, params: T.MlDeleteFilterRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -443,7 +443,7 @@ export default class Ml { /** * Delete forecasts from a job. By default, forecasts are retained for 14 days. You can specify a different retention period with the `expires_in` parameter in the forecast jobs API. The delete forecast API enables you to delete one or more forecasts before they expire. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-delete-forecast.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-forecast | Elasticsearch API documentation} */ async deleteForecast (this: That, params: T.MlDeleteForecastRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteForecast (this: That, params: T.MlDeleteForecastRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -493,7 +493,7 @@ export default class Ml { /** * Delete an anomaly detection job. All job configuration, model state and results are deleted. It is not currently possible to delete multiple jobs using wildcards or a comma separated list. If you delete a job that has a datafeed, the request first tries to delete the datafeed. This behavior is equivalent to calling the delete datafeed API with the same timeout and force parameters as the delete job request. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-delete-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-job | Elasticsearch API documentation} */ async deleteJob (this: That, params: T.MlDeleteJobRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteJob (this: That, params: T.MlDeleteJobRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -535,7 +535,7 @@ export default class Ml { /** * Delete a model snapshot. You cannot delete the active model snapshot. To delete that snapshot, first revert to a different one. To identify the active model snapshot, refer to the `model_snapshot_id` in the results from the get jobs API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-delete-snapshot.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-model-snapshot | Elasticsearch API documentation} */ async deleteModelSnapshot (this: That, params: T.MlDeleteModelSnapshotRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteModelSnapshot (this: That, params: T.MlDeleteModelSnapshotRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -578,7 +578,7 @@ export default class Ml { /** * Delete an unreferenced trained model. The request deletes a trained inference model that is not referenced by an ingest pipeline. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-trained-models.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-trained-model | Elasticsearch API documentation} */ async deleteTrainedModel (this: That, params: T.MlDeleteTrainedModelRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteTrainedModel (this: That, params: T.MlDeleteTrainedModelRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -620,7 +620,7 @@ export default class Ml { /** * Delete a trained model alias. This API deletes an existing model alias that refers to a trained model. If the model alias is missing or refers to a model other than the one identified by the `model_id`, this API returns an error. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-trained-models-aliases.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-delete-trained-model-alias | Elasticsearch API documentation} */ async deleteTrainedModelAlias (this: That, params: T.MlDeleteTrainedModelAliasRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteTrainedModelAlias (this: That, params: T.MlDeleteTrainedModelAliasRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -662,8 +662,8 @@ export default class Ml { } /** - * Estimate job model memory usage. Makes an estimation of the memory usage for an anomaly detection job model. It is based on analysis configuration details for the job and cardinality estimates for the fields it references. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-apis.html | Elasticsearch API documentation} + * Estimate job model memory usage. Make an estimation of the memory usage for an anomaly detection job model. The estimate is based on analysis configuration details for the job and cardinality estimates for the fields it references. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-estimate-model-memory | Elasticsearch API documentation} */ async estimateModelMemory (this: That, params?: T.MlEstimateModelMemoryRequest, options?: TransportRequestOptionsWithOutMeta): Promise async estimateModelMemory (this: That, params?: T.MlEstimateModelMemoryRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -708,7 +708,7 @@ export default class Ml { /** * Evaluate data frame analytics. The API packages together commonly used evaluation metrics for various types of machine learning features. This has been designed for use on indexes created by data frame analytics. Evaluation requires both a ground truth field and an analytics result field to be present. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/evaluate-dfanalytics.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-evaluate-data-frame | Elasticsearch API documentation} */ async evaluateDataFrame (this: That, params: T.MlEvaluateDataFrameRequest, options?: TransportRequestOptionsWithOutMeta): Promise async evaluateDataFrame (this: That, params: T.MlEvaluateDataFrameRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -752,7 +752,7 @@ export default class Ml { /** * Explain data frame analytics config. This API provides explanations for a data frame analytics config that either exists already or one that has not been created yet. The following explanations are provided: * which fields are included or not in the analysis and why, * how much memory is estimated to be required. The estimate can be used when deciding the appropriate value for model_memory_limit setting later on. If you have object fields or fields that are excluded via source filtering, they are not included in the explanation. - * @see {@link http://www.elastic.co/guide/en/elasticsearch/reference/master/explain-dfanalytics.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-explain-data-frame-analytics | Elasticsearch API documentation} */ async explainDataFrameAnalytics (this: That, params?: T.MlExplainDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async explainDataFrameAnalytics (this: That, params?: T.MlExplainDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -807,7 +807,7 @@ export default class Ml { /** * Force buffered data to be processed. The flush jobs API is only applicable when sending data for analysis using the post data API. Depending on the content of the buffer, then it might additionally calculate new results. Both flush and close operations are similar, however the flush is more efficient if you are expecting to send more data for analysis. When flushing, the job remains open and is available to continue analyzing data. A close operation additionally prunes and persists the model state to disk and the job must be opened again before analyzing further data. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-flush-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-flush-job | Elasticsearch API documentation} */ async flushJob (this: That, params: T.MlFlushJobRequest, options?: TransportRequestOptionsWithOutMeta): Promise async flushJob (this: That, params: T.MlFlushJobRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -854,7 +854,7 @@ export default class Ml { /** * Predict future behavior of a time series. Forecasts are not supported for jobs that perform population analysis; an error occurs if you try to create a forecast for a job that has an `over_field_name` in its configuration. Forcasts predict future behavior based on historical data. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-forecast.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-forecast | Elasticsearch API documentation} */ async forecast (this: That, params: T.MlForecastRequest, options?: TransportRequestOptionsWithOutMeta): Promise async forecast (this: That, params: T.MlForecastRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -901,7 +901,7 @@ export default class Ml { /** * Get anomaly detection job results for buckets. The API presents a chronological view of the records, grouped by bucket. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-get-bucket.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-buckets | Elasticsearch API documentation} */ async getBuckets (this: That, params: T.MlGetBucketsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getBuckets (this: That, params: T.MlGetBucketsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -956,7 +956,7 @@ export default class Ml { /** * Get info about events in calendars. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-get-calendar-event.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-calendar-events | Elasticsearch API documentation} */ async getCalendarEvents (this: That, params: T.MlGetCalendarEventsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getCalendarEvents (this: That, params: T.MlGetCalendarEventsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -998,7 +998,7 @@ export default class Ml { /** * Get calendar configuration info. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-get-calendar.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-calendars | Elasticsearch API documentation} */ async getCalendars (this: That, params?: T.MlGetCalendarsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getCalendars (this: That, params?: T.MlGetCalendarsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1053,7 +1053,7 @@ export default class Ml { /** * Get anomaly detection job results for categories. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-get-category.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-categories | Elasticsearch API documentation} */ async getCategories (this: That, params: T.MlGetCategoriesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getCategories (this: That, params: T.MlGetCategoriesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1108,7 +1108,7 @@ export default class Ml { /** * Get data frame analytics job configuration info. You can get information for multiple data frame analytics jobs in a single API request by using a comma-separated list of data frame analytics jobs or a wildcard expression. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-dfanalytics.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-data-frame-analytics | Elasticsearch API documentation} */ async getDataFrameAnalytics (this: That, params?: T.MlGetDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getDataFrameAnalytics (this: That, params?: T.MlGetDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1158,7 +1158,7 @@ export default class Ml { /** * Get data frame analytics jobs usage info. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-dfanalytics-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-data-frame-analytics-stats | Elasticsearch API documentation} */ async getDataFrameAnalyticsStats (this: That, params?: T.MlGetDataFrameAnalyticsStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getDataFrameAnalyticsStats (this: That, params?: T.MlGetDataFrameAnalyticsStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1208,7 +1208,7 @@ export default class Ml { /** * Get datafeeds usage info. You can get statistics for multiple datafeeds in a single API request by using a comma-separated list of datafeeds or a wildcard expression. You can get statistics for all datafeeds by using `_all`, by specifying `*` as the ``, or by omitting the ``. If the datafeed is stopped, the only information you receive is the `datafeed_id` and the `state`. This API returns a maximum of 10,000 datafeeds. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-get-datafeed-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-datafeed-stats | Elasticsearch API documentation} */ async getDatafeedStats (this: That, params?: T.MlGetDatafeedStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getDatafeedStats (this: That, params?: T.MlGetDatafeedStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1258,7 +1258,7 @@ export default class Ml { /** * Get datafeeds configuration info. You can get information for multiple datafeeds in a single API request by using a comma-separated list of datafeeds or a wildcard expression. You can get information for all datafeeds by using `_all`, by specifying `*` as the ``, or by omitting the ``. This API returns a maximum of 10,000 datafeeds. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-get-datafeed.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-datafeeds | Elasticsearch API documentation} */ async getDatafeeds (this: That, params?: T.MlGetDatafeedsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getDatafeeds (this: That, params?: T.MlGetDatafeedsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1308,7 +1308,7 @@ export default class Ml { /** * Get filters. You can get a single filter or all filters. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-get-filter.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-filters | Elasticsearch API documentation} */ async getFilters (this: That, params?: T.MlGetFiltersRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getFilters (this: That, params?: T.MlGetFiltersRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1358,7 +1358,7 @@ export default class Ml { /** * Get anomaly detection job results for influencers. Influencers are the entities that have contributed to, or are to blame for, the anomalies. Influencer results are available only if an `influencer_field_name` is specified in the job configuration. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-get-influencer.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-influencers | Elasticsearch API documentation} */ async getInfluencers (this: That, params: T.MlGetInfluencersRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getInfluencers (this: That, params: T.MlGetInfluencersRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1405,7 +1405,7 @@ export default class Ml { /** * Get anomaly detection jobs usage info. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-get-job-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-job-stats | Elasticsearch API documentation} */ async getJobStats (this: That, params?: T.MlGetJobStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getJobStats (this: That, params?: T.MlGetJobStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1455,7 +1455,7 @@ export default class Ml { /** * Get anomaly detection jobs configuration info. You can get information for multiple anomaly detection jobs in a single API request by using a group name, a comma-separated list of jobs, or a wildcard expression. You can get information for all anomaly detection jobs by using `_all`, by specifying `*` as the ``, or by omitting the ``. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-get-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-jobs | Elasticsearch API documentation} */ async getJobs (this: That, params?: T.MlGetJobsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getJobs (this: That, params?: T.MlGetJobsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1505,7 +1505,7 @@ export default class Ml { /** * Get machine learning memory usage info. Get information about how machine learning jobs and trained models are using memory, on each node, both within the JVM heap, and natively, outside of the JVM. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-ml-memory.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-memory-stats | Elasticsearch API documentation} */ async getMemoryStats (this: That, params?: T.MlGetMemoryStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getMemoryStats (this: That, params?: T.MlGetMemoryStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1555,7 +1555,7 @@ export default class Ml { /** * Get anomaly detection job model snapshot upgrade usage info. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-get-job-model-snapshot-upgrade-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-model-snapshot-upgrade-stats | Elasticsearch API documentation} */ async getModelSnapshotUpgradeStats (this: That, params: T.MlGetModelSnapshotUpgradeStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getModelSnapshotUpgradeStats (this: That, params: T.MlGetModelSnapshotUpgradeStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1598,7 +1598,7 @@ export default class Ml { /** * Get model snapshots info. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-get-snapshot.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-model-snapshots | Elasticsearch API documentation} */ async getModelSnapshots (this: That, params: T.MlGetModelSnapshotsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getModelSnapshots (this: That, params: T.MlGetModelSnapshotsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1653,7 +1653,7 @@ export default class Ml { /** * Get overall bucket results. Retrievs overall bucket results that summarize the bucket results of multiple anomaly detection jobs. The `overall_score` is calculated by combining the scores of all the buckets within the overall bucket span. First, the maximum `anomaly_score` per anomaly detection job in the overall bucket is calculated. Then the `top_n` of those scores are averaged to result in the `overall_score`. This means that you can fine-tune the `overall_score` so that it is more or less sensitive to the number of jobs that detect an anomaly at the same time. For example, if you set `top_n` to `1`, the `overall_score` is the maximum bucket score in the overall bucket. Alternatively, if you set `top_n` to the number of jobs, the `overall_score` is high only when all jobs detect anomalies in that overall bucket. If you set the `bucket_span` parameter (to a value greater than its default), the `overall_score` is the maximum `overall_score` of the overall buckets that have a span equal to the jobs' largest bucket span. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-get-overall-buckets.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-overall-buckets | Elasticsearch API documentation} */ async getOverallBuckets (this: That, params: T.MlGetOverallBucketsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getOverallBuckets (this: That, params: T.MlGetOverallBucketsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1700,7 +1700,7 @@ export default class Ml { /** * Get anomaly records for an anomaly detection job. Records contain the detailed analytical results. They describe the anomalous activity that has been identified in the input data based on the detector configuration. There can be many anomaly records depending on the characteristics and size of the input data. In practice, there are often too many to be able to manually process them. The machine learning features therefore perform a sophisticated aggregation of the anomaly records into buckets. The number of record results depends on the number of anomalies found in each bucket, which relates to the number of time series being modeled and the number of detectors. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-get-record.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-records | Elasticsearch API documentation} */ async getRecords (this: That, params: T.MlGetRecordsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getRecords (this: That, params: T.MlGetRecordsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1747,7 +1747,7 @@ export default class Ml { /** * Get trained model configuration info. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-trained-models.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-trained-models | Elasticsearch API documentation} */ async getTrainedModels (this: That, params?: T.MlGetTrainedModelsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getTrainedModels (this: That, params?: T.MlGetTrainedModelsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1797,7 +1797,7 @@ export default class Ml { /** * Get trained models usage info. You can get usage information for multiple trained models in a single API request by using a comma-separated list of model IDs or a wildcard expression. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-trained-models-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-get-trained-models-stats | Elasticsearch API documentation} */ async getTrainedModelsStats (this: That, params?: T.MlGetTrainedModelsStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getTrainedModelsStats (this: That, params?: T.MlGetTrainedModelsStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1847,7 +1847,7 @@ export default class Ml { /** * Evaluate a trained model. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/infer-trained-model.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-infer-trained-model | Elasticsearch API documentation} */ async inferTrainedModel (this: That, params: T.MlInferTrainedModelRequest, options?: TransportRequestOptionsWithOutMeta): Promise async inferTrainedModel (this: That, params: T.MlInferTrainedModelRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1894,7 +1894,7 @@ export default class Ml { /** * Get machine learning information. Get defaults and limits used by machine learning. This endpoint is designed to be used by a user interface that needs to fully understand machine learning configurations where some options are not specified, meaning that the defaults should be used. This endpoint may be used to find out what those defaults are. It also provides information about the maximum size of machine learning jobs that could run in the current cluster configuration. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-ml-info.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-info | Elasticsearch API documentation} */ async info (this: That, params?: T.MlInfoRequest, options?: TransportRequestOptionsWithOutMeta): Promise async info (this: That, params?: T.MlInfoRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1934,7 +1934,7 @@ export default class Ml { /** * Open anomaly detection jobs. An anomaly detection job must be opened to be ready to receive and analyze data. It can be opened and closed multiple times throughout its lifecycle. When you open a new job, it starts with an empty model. When you open an existing job, the most recent model state is automatically loaded. The job is ready to resume its analysis from where it left off, once new data is received. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-open-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-open-job | Elasticsearch API documentation} */ async openJob (this: That, params: T.MlOpenJobRequest, options?: TransportRequestOptionsWithOutMeta): Promise async openJob (this: That, params: T.MlOpenJobRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1981,7 +1981,7 @@ export default class Ml { /** * Add scheduled events to the calendar. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-post-calendar-event.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-post-calendar-events | Elasticsearch API documentation} */ async postCalendarEvents (this: That, params: T.MlPostCalendarEventsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async postCalendarEvents (this: That, params: T.MlPostCalendarEventsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2028,7 +2028,7 @@ export default class Ml { /** * Send data to an anomaly detection job for analysis. IMPORTANT: For each job, data can be accepted from only a single connection at a time. It is not currently possible to post data to multiple jobs using wildcards or a comma-separated list. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-post-data.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-post-data | Elasticsearch API documentation} */ async postData (this: That, params: T.MlPostDataRequest, options?: TransportRequestOptionsWithOutMeta): Promise async postData (this: That, params: T.MlPostDataRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2064,8 +2064,8 @@ export default class Ml { } /** - * Preview features used by data frame analytics. Previews the extracted features used by a data frame analytics config. - * @see {@link http://www.elastic.co/guide/en/elasticsearch/reference/master/preview-dfanalytics.html | Elasticsearch API documentation} + * Preview features used by data frame analytics. Preview the extracted features used by a data frame analytics config. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-preview-data-frame-analytics | Elasticsearch API documentation} */ async previewDataFrameAnalytics (this: That, params?: T.MlPreviewDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async previewDataFrameAnalytics (this: That, params?: T.MlPreviewDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2120,7 +2120,7 @@ export default class Ml { /** * Preview a datafeed. This API returns the first "page" of search results from a datafeed. You can preview an existing datafeed or provide configuration details for a datafeed and anomaly detection job in the API. The preview shows the structure of the data that will be passed to the anomaly detection engine. IMPORTANT: When Elasticsearch security features are enabled, the preview uses the credentials of the user that called the API. However, when the datafeed starts it uses the roles of the last user that created or updated the datafeed. To get a preview that accurately reflects the behavior of the datafeed, use the appropriate credentials. You can also use secondary authorization headers to supply the credentials. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-preview-datafeed.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-preview-datafeed | Elasticsearch API documentation} */ async previewDatafeed (this: That, params?: T.MlPreviewDatafeedRequest, options?: TransportRequestOptionsWithOutMeta): Promise> async previewDatafeed (this: That, params?: T.MlPreviewDatafeedRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> @@ -2175,7 +2175,7 @@ export default class Ml { /** * Create a calendar. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-put-calendar.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-calendar | Elasticsearch API documentation} */ async putCalendar (this: That, params: T.MlPutCalendarRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putCalendar (this: That, params: T.MlPutCalendarRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2222,7 +2222,7 @@ export default class Ml { /** * Add anomaly detection job to calendar. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-put-calendar-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-calendar-job | Elasticsearch API documentation} */ async putCalendarJob (this: That, params: T.MlPutCalendarJobRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putCalendarJob (this: That, params: T.MlPutCalendarJobRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2265,7 +2265,7 @@ export default class Ml { /** * Create a data frame analytics job. This API creates a data frame analytics job that performs an analysis on the source indices and stores the outcome in a destination index. By default, the query used in the source configuration is `{"match_all": {}}`. If the destination index does not exist, it is created automatically when you start the job. If you supply only a subset of the regression or classification parameters, hyperparameter optimization occurs. It determines a value for each of the undefined parameters. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-dfanalytics.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-data-frame-analytics | Elasticsearch API documentation} */ async putDataFrameAnalytics (this: That, params: T.MlPutDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putDataFrameAnalytics (this: That, params: T.MlPutDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2312,7 +2312,7 @@ export default class Ml { /** * Create a datafeed. Datafeeds retrieve data from Elasticsearch for analysis by an anomaly detection job. You can associate only one datafeed with each anomaly detection job. The datafeed contains a query that runs at a defined interval (`frequency`). If you are concerned about delayed data, you can add a delay (`query_delay') at each interval. By default, the datafeed uses the following query: `{"match_all": {"boost": 1}}`. When Elasticsearch security features are enabled, your datafeed remembers which roles the user who created it had at the time of creation and runs the query using those same roles. If you provide secondary authorization headers, those credentials are used instead. You must use Kibana, this API, or the create anomaly detection jobs API to create a datafeed. Do not add a datafeed directly to the `.ml-config` index. Do not give users `write` privileges on the `.ml-config` index. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-put-datafeed.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-datafeed | Elasticsearch API documentation} */ async putDatafeed (this: That, params: T.MlPutDatafeedRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putDatafeed (this: That, params: T.MlPutDatafeedRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2359,7 +2359,7 @@ export default class Ml { /** * Create a filter. A filter contains a list of strings. It can be used by one or more anomaly detection jobs. Specifically, filters are referenced in the `custom_rules` property of detector configuration objects. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-put-filter.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-filter | Elasticsearch API documentation} */ async putFilter (this: That, params: T.MlPutFilterRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putFilter (this: That, params: T.MlPutFilterRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2406,7 +2406,7 @@ export default class Ml { /** * Create an anomaly detection job. If you include a `datafeed_config`, you must have read index privileges on the source index. If you include a `datafeed_config` but do not provide a query, the datafeed uses `{"match_all": {"boost": 1}}`. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-put-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-job | Elasticsearch API documentation} */ async putJob (this: That, params: T.MlPutJobRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putJob (this: That, params: T.MlPutJobRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2453,7 +2453,7 @@ export default class Ml { /** * Create a trained model. Enable you to supply a trained model that is not created by data frame analytics. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-trained-models.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-trained-model | Elasticsearch API documentation} */ async putTrainedModel (this: That, params: T.MlPutTrainedModelRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putTrainedModel (this: That, params: T.MlPutTrainedModelRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2500,7 +2500,7 @@ export default class Ml { /** * Create or update a trained model alias. A trained model alias is a logical name used to reference a single trained model. You can use aliases instead of trained model identifiers to make it easier to reference your models. For example, you can use aliases in inference aggregations and processors. An alias must be unique and refer to only a single trained model. However, you can have multiple aliases for each trained model. If you use this API to update an alias such that it references a different trained model ID and the model uses a different type of data frame analytics, an error occurs. For example, this situation occurs if you have a trained model for regression analysis and a trained model for classification analysis; you cannot reassign an alias from one type of trained model to another. If you use this API to update an alias and there are very few input fields in common between the old and new trained models for the model alias, the API returns a warning. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-trained-models-aliases.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-trained-model-alias | Elasticsearch API documentation} */ async putTrainedModelAlias (this: That, params: T.MlPutTrainedModelAliasRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putTrainedModelAlias (this: That, params: T.MlPutTrainedModelAliasRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2543,7 +2543,7 @@ export default class Ml { /** * Create part of a trained model definition. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-trained-model-definition-part.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-trained-model-definition-part | Elasticsearch API documentation} */ async putTrainedModelDefinitionPart (this: That, params: T.MlPutTrainedModelDefinitionPartRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putTrainedModelDefinitionPart (this: That, params: T.MlPutTrainedModelDefinitionPartRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2591,7 +2591,7 @@ export default class Ml { /** * Create a trained model vocabulary. This API is supported only for natural language processing (NLP) models. The vocabulary is stored in the index as described in `inference_config.*.vocabulary` of the trained model definition. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-trained-model-vocabulary.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-put-trained-model-vocabulary | Elasticsearch API documentation} */ async putTrainedModelVocabulary (this: That, params: T.MlPutTrainedModelVocabularyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putTrainedModelVocabulary (this: That, params: T.MlPutTrainedModelVocabularyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2638,7 +2638,7 @@ export default class Ml { /** * Reset an anomaly detection job. All model state and results are deleted. The job is ready to start over as if it had just been created. It is not currently possible to reset multiple jobs using wildcards or a comma separated list. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-reset-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-reset-job | Elasticsearch API documentation} */ async resetJob (this: That, params: T.MlResetJobRequest, options?: TransportRequestOptionsWithOutMeta): Promise async resetJob (this: That, params: T.MlResetJobRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2680,7 +2680,7 @@ export default class Ml { /** * Revert to a snapshot. The machine learning features react quickly to anomalous input, learning new behaviors in data. Highly anomalous input increases the variance in the models whilst the system learns whether this is a new step-change in behavior or a one-off event. In the case where this anomalous input is known to be a one-off, then it might be appropriate to reset the model state to a time before this event. For example, you might consider reverting to a saved snapshot after Black Friday or a critical system failure. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-revert-snapshot.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-revert-model-snapshot | Elasticsearch API documentation} */ async revertModelSnapshot (this: That, params: T.MlRevertModelSnapshotRequest, options?: TransportRequestOptionsWithOutMeta): Promise async revertModelSnapshot (this: That, params: T.MlRevertModelSnapshotRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2728,7 +2728,7 @@ export default class Ml { /** * Set upgrade_mode for ML indices. Sets a cluster wide upgrade_mode setting that prepares machine learning indices for an upgrade. When upgrading your cluster, in some circumstances you must restart your nodes and reindex your machine learning indices. In those circumstances, there must be no machine learning jobs running. You can close the machine learning jobs, do the upgrade, then open all the jobs again. Alternatively, you can use this API to temporarily halt tasks associated with the jobs and datafeeds and prevent new jobs from opening. You can also use this API during upgrades that do not require you to reindex your machine learning indices, though stopping jobs is not a requirement in that case. You can see the current value for the upgrade_mode setting by using the get machine learning info API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-set-upgrade-mode.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-set-upgrade-mode | Elasticsearch API documentation} */ async setUpgradeMode (this: That, params?: T.MlSetUpgradeModeRequest, options?: TransportRequestOptionsWithOutMeta): Promise async setUpgradeMode (this: That, params?: T.MlSetUpgradeModeRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2768,7 +2768,7 @@ export default class Ml { /** * Start a data frame analytics job. A data frame analytics job can be started and stopped multiple times throughout its lifecycle. If the destination index does not exist, it is created automatically the first time you start the data frame analytics job. The `index.number_of_shards` and `index.number_of_replicas` settings for the destination index are copied from the source index. If there are multiple source indices, the destination index copies the highest setting values. The mappings for the destination index are also copied from the source indices. If there are any mapping conflicts, the job fails to start. If the destination index exists, it is used as is. You can therefore set up the destination index in advance with custom settings and mappings. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/start-dfanalytics.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-start-data-frame-analytics | Elasticsearch API documentation} */ async startDataFrameAnalytics (this: That, params: T.MlStartDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async startDataFrameAnalytics (this: That, params: T.MlStartDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2810,7 +2810,7 @@ export default class Ml { /** * Start datafeeds. A datafeed must be started in order to retrieve data from Elasticsearch. A datafeed can be started and stopped multiple times throughout its lifecycle. Before you can start a datafeed, the anomaly detection job must be open. Otherwise, an error occurs. If you restart a stopped datafeed, it continues processing input data from the next millisecond after it was stopped. If new data was indexed for that exact millisecond between stopping and starting, it will be ignored. When Elasticsearch security features are enabled, your datafeed remembers which roles the last user to create or update it had at the time of creation or update and runs the query using those same roles. If you provided secondary authorization headers when you created or updated the datafeed, those credentials are used instead. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-start-datafeed.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-start-datafeed | Elasticsearch API documentation} */ async startDatafeed (this: That, params: T.MlStartDatafeedRequest, options?: TransportRequestOptionsWithOutMeta): Promise async startDatafeed (this: That, params: T.MlStartDatafeedRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2857,7 +2857,7 @@ export default class Ml { /** * Start a trained model deployment. It allocates the model to every machine learning node. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/start-trained-model-deployment.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-start-trained-model-deployment | Elasticsearch API documentation} */ async startTrainedModelDeployment (this: That, params: T.MlStartTrainedModelDeploymentRequest, options?: TransportRequestOptionsWithOutMeta): Promise async startTrainedModelDeployment (this: That, params: T.MlStartTrainedModelDeploymentRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2899,7 +2899,7 @@ export default class Ml { /** * Stop data frame analytics jobs. A data frame analytics job can be started and stopped multiple times throughout its lifecycle. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/stop-dfanalytics.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-stop-data-frame-analytics | Elasticsearch API documentation} */ async stopDataFrameAnalytics (this: That, params: T.MlStopDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stopDataFrameAnalytics (this: That, params: T.MlStopDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2941,7 +2941,7 @@ export default class Ml { /** * Stop datafeeds. A datafeed that is stopped ceases to retrieve data from Elasticsearch. A datafeed can be started and stopped multiple times throughout its lifecycle. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-stop-datafeed.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-stop-datafeed | Elasticsearch API documentation} */ async stopDatafeed (this: That, params: T.MlStopDatafeedRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stopDatafeed (this: That, params: T.MlStopDatafeedRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2988,7 +2988,7 @@ export default class Ml { /** * Stop a trained model deployment. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/stop-trained-model-deployment.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-stop-trained-model-deployment | Elasticsearch API documentation} */ async stopTrainedModelDeployment (this: That, params: T.MlStopTrainedModelDeploymentRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stopTrainedModelDeployment (this: That, params: T.MlStopTrainedModelDeploymentRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -3030,7 +3030,7 @@ export default class Ml { /** * Update a data frame analytics job. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-dfanalytics.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-update-data-frame-analytics | Elasticsearch API documentation} */ async updateDataFrameAnalytics (this: That, params: T.MlUpdateDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateDataFrameAnalytics (this: That, params: T.MlUpdateDataFrameAnalyticsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -3077,7 +3077,7 @@ export default class Ml { /** * Update a datafeed. You must stop and start the datafeed for the changes to be applied. When Elasticsearch security features are enabled, your datafeed remembers which roles the user who updated it had at the time of the update and runs the query using those same roles. If you provide secondary authorization headers, those credentials are used instead. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-update-datafeed.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-update-datafeed | Elasticsearch API documentation} */ async updateDatafeed (this: That, params: T.MlUpdateDatafeedRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateDatafeed (this: That, params: T.MlUpdateDatafeedRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -3124,7 +3124,7 @@ export default class Ml { /** * Update a filter. Updates the description of a filter, adds items, or removes items from the list. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-update-filter.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-update-filter | Elasticsearch API documentation} */ async updateFilter (this: That, params: T.MlUpdateFilterRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateFilter (this: That, params: T.MlUpdateFilterRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -3171,7 +3171,7 @@ export default class Ml { /** * Update an anomaly detection job. Updates certain properties of an anomaly detection job. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-update-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-update-job | Elasticsearch API documentation} */ async updateJob (this: That, params: T.MlUpdateJobRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateJob (this: That, params: T.MlUpdateJobRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -3218,7 +3218,7 @@ export default class Ml { /** * Update a snapshot. Updates certain properties of a snapshot. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-update-snapshot.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-update-model-snapshot | Elasticsearch API documentation} */ async updateModelSnapshot (this: That, params: T.MlUpdateModelSnapshotRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateModelSnapshot (this: That, params: T.MlUpdateModelSnapshotRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -3266,7 +3266,7 @@ export default class Ml { /** * Update a trained model deployment. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-trained-model-deployment.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-update-trained-model-deployment | Elasticsearch API documentation} */ async updateTrainedModelDeployment (this: That, params: T.MlUpdateTrainedModelDeploymentRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateTrainedModelDeployment (this: That, params: T.MlUpdateTrainedModelDeploymentRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -3312,8 +3312,8 @@ export default class Ml { } /** - * Upgrade a snapshot. Upgrades an anomaly detection model snapshot to the latest major version. Over time, older snapshot formats are deprecated and removed. Anomaly detection jobs support only snapshots that are from the current or previous major version. This API provides a means to upgrade a snapshot to the current major version. This aids in preparing the cluster for an upgrade to the next major version. Only one snapshot per anomaly detection job can be upgraded at a time and the upgraded snapshot cannot be the current snapshot of the anomaly detection job. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/ml-upgrade-job-model-snapshot.html | Elasticsearch API documentation} + * Upgrade a snapshot. Upgrade an anomaly detection model snapshot to the latest major version. Over time, older snapshot formats are deprecated and removed. Anomaly detection jobs support only snapshots that are from the current or previous major version. This API provides a means to upgrade a snapshot to the current major version. This aids in preparing the cluster for an upgrade to the next major version. Only one snapshot per anomaly detection job can be upgraded at a time and the upgraded snapshot cannot be the current snapshot of the anomaly detection job. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-upgrade-job-snapshot | Elasticsearch API documentation} */ async upgradeJobSnapshot (this: That, params: T.MlUpgradeJobSnapshotRequest, options?: TransportRequestOptionsWithOutMeta): Promise async upgradeJobSnapshot (this: That, params: T.MlUpgradeJobSnapshotRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -3401,7 +3401,7 @@ export default class Ml { /** * Validate an anomaly detection job. - * @see {@link https://www.elastic.co/guide/en/machine-learning/master/ml-jobs.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch | Elasticsearch API documentation} */ async validateDetector (this: That, params: T.MlValidateDetectorRequest, options?: TransportRequestOptionsWithOutMeta): Promise async validateDetector (this: That, params: T.MlValidateDetectorRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/monitoring.ts b/src/api/api/monitoring.ts index c4a09fc33..053fea53a 100644 --- a/src/api/api/monitoring.ts +++ b/src/api/api/monitoring.ts @@ -45,7 +45,7 @@ export default class Monitoring { /** * Send monitoring data. This API is used by the monitoring features to send monitoring data. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/monitor-elasticsearch-cluster.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch | Elasticsearch API documentation} */ async bulk (this: That, params: T.MonitoringBulkRequest, options?: TransportRequestOptionsWithOutMeta): Promise async bulk (this: That, params: T.MonitoringBulkRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/msearch.ts b/src/api/api/msearch.ts index 575e95b19..573c4f385 100644 --- a/src/api/api/msearch.ts +++ b/src/api/api/msearch.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Run multiple searches. The format of the request is similar to the bulk API format and makes use of the newline delimited JSON (NDJSON) format. The structure is as follows: ``` header\n body\n header\n body\n ``` This structure is specifically optimized to reduce parsing if a specific search ends up redirected to another node. IMPORTANT: The final line of data must end with a newline character `\n`. Each newline character may be preceded by a carriage return `\r`. When sending requests to this endpoint the `Content-Type` header should be set to `application/x-ndjson`. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-multi-search.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-msearch | Elasticsearch API documentation} */ export default async function MsearchApi> (this: That, params: T.MsearchRequest, options?: TransportRequestOptionsWithOutMeta): Promise> export default async function MsearchApi> (this: That, params: T.MsearchRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/msearch_template.ts b/src/api/api/msearch_template.ts index 54ffc9d32..019b9d1b8 100644 --- a/src/api/api/msearch_template.ts +++ b/src/api/api/msearch_template.ts @@ -38,8 +38,8 @@ import * as T from '../types' interface That { transport: Transport } /** - * Run multiple templated searches. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-multi-search.html | Elasticsearch API documentation} + * Run multiple templated searches. Run multiple templated searches with a single request. If you are providing a text file or text input to `curl`, use the `--data-binary` flag instead of `-d` to preserve newlines. For example: ``` $ cat requests { "index": "my-index" } { "id": "my-search-template", "params": { "query_string": "hello world", "from": 0, "size": 10 }} { "index": "my-other-index" } { "id": "my-other-search-template", "params": { "query_type": "match_all" }} $ curl -H "Content-Type: application/x-ndjson" -XGET localhost:9200/_msearch/template --data-binary "@requests"; echo ``` + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-msearch-template | Elasticsearch API documentation} */ export default async function MsearchTemplateApi> (this: That, params: T.MsearchTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise> export default async function MsearchTemplateApi> (this: That, params: T.MsearchTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/mtermvectors.ts b/src/api/api/mtermvectors.ts index fef6e4592..bd4faccbb 100644 --- a/src/api/api/mtermvectors.ts +++ b/src/api/api/mtermvectors.ts @@ -38,8 +38,8 @@ import * as T from '../types' interface That { transport: Transport } /** - * Get multiple term vectors. You can specify existing documents by index and ID or provide artificial documents in the body of the request. You can specify the index in the request body or request URI. The response contains a `docs` array with all the fetched termvectors. Each element has the structure provided by the termvectors API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-multi-termvectors.html | Elasticsearch API documentation} + * Get multiple term vectors. Get multiple term vectors with a single request. You can specify existing documents by index and ID or provide artificial documents in the body of the request. You can specify the index in the request body or request URI. The response contains a `docs` array with all the fetched termvectors. Each element has the structure provided by the termvectors API. **Artificial documents** You can also use `mtermvectors` to generate term vectors for artificial documents provided in the body of the request. The mapping used is determined by the specified `_index`. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-mtermvectors | Elasticsearch API documentation} */ export default async function MtermvectorsApi (this: That, params?: T.MtermvectorsRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function MtermvectorsApi (this: That, params?: T.MtermvectorsRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/nodes.ts b/src/api/api/nodes.ts index 27ca13040..1ce489ae0 100644 --- a/src/api/api/nodes.ts +++ b/src/api/api/nodes.ts @@ -45,7 +45,7 @@ export default class Nodes { /** * Clear the archived repositories metering. Clear the archived repositories metering information in the cluster. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/clear-repositories-metering-archive-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-nodes-clear-repositories-metering-archive | Elasticsearch API documentation} */ async clearRepositoriesMeteringArchive (this: That, params: T.NodesClearRepositoriesMeteringArchiveRequest, options?: TransportRequestOptionsWithOutMeta): Promise async clearRepositoriesMeteringArchive (this: That, params: T.NodesClearRepositoriesMeteringArchiveRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -88,7 +88,7 @@ export default class Nodes { /** * Get cluster repositories metering. Get repositories metering information for a cluster. This API exposes monotonically non-decreasing counters and it is expected that clients would durably store the information needed to compute aggregations over a period of time. Additionally, the information exposed by this API is volatile, meaning that it will not be present after node restarts. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-repositories-metering-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-nodes-get-repositories-metering-info | Elasticsearch API documentation} */ async getRepositoriesMeteringInfo (this: That, params: T.NodesGetRepositoriesMeteringInfoRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getRepositoriesMeteringInfo (this: That, params: T.NodesGetRepositoriesMeteringInfoRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -130,7 +130,7 @@ export default class Nodes { /** * Get the hot threads for nodes. Get a breakdown of the hot threads on each selected node in the cluster. The output is plain text with a breakdown of the top hot threads for each node. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-nodes-hot-threads.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-nodes-hot-threads | Elasticsearch API documentation} */ async hotThreads (this: That, params?: T.NodesHotThreadsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async hotThreads (this: That, params?: T.NodesHotThreadsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -180,7 +180,7 @@ export default class Nodes { /** * Get node information. By default, the API returns all attributes and core settings for cluster nodes. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-nodes-info.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-nodes-info | Elasticsearch API documentation} */ async info (this: That, params?: T.NodesInfoRequest, options?: TransportRequestOptionsWithOutMeta): Promise async info (this: That, params?: T.NodesInfoRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -237,7 +237,7 @@ export default class Nodes { /** * Reload the keystore on nodes in the cluster. Secure settings are stored in an on-disk keystore. Certain of these settings are reloadable. That is, you can change them on disk and reload them without restarting any nodes in the cluster. When you have updated reloadable secure settings in your keystore, you can use this API to reload those settings on each node. When the Elasticsearch keystore is password protected and not simply obfuscated, you must provide the password for the keystore when you reload the secure settings. Reloading the settings for the whole cluster assumes that the keystores for all nodes are protected with the same password; this method is allowed only when inter-node communications are encrypted. Alternatively, you can reload the secure settings on each node by locally accessing the API and passing the node-specific Elasticsearch keystore password. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/secure-settings.html#reloadable-secure-settings | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-nodes-reload-secure-settings | Elasticsearch API documentation} */ async reloadSecureSettings (this: That, params?: T.NodesReloadSecureSettingsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async reloadSecureSettings (this: That, params?: T.NodesReloadSecureSettingsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -292,7 +292,7 @@ export default class Nodes { /** * Get node statistics. Get statistics for nodes in a cluster. By default, all stats are returned. You can limit the returned information by using metrics. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-nodes-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-nodes-stats | Elasticsearch API documentation} */ async stats (this: That, params?: T.NodesStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stats (this: That, params?: T.NodesStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -356,7 +356,7 @@ export default class Nodes { /** * Get feature usage information. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/cluster-nodes-usage.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-nodes-usage | Elasticsearch API documentation} */ async usage (this: That, params?: T.NodesUsageRequest, options?: TransportRequestOptionsWithOutMeta): Promise async usage (this: That, params?: T.NodesUsageRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/open_point_in_time.ts b/src/api/api/open_point_in_time.ts index 685e46870..4cd2a733e 100644 --- a/src/api/api/open_point_in_time.ts +++ b/src/api/api/open_point_in_time.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Open a point in time. A search request by default runs against the most recent visible data of the target indices, which is called point in time. Elasticsearch pit (point in time) is a lightweight view into the state of the data as it existed when initiated. In some cases, it’s preferred to perform multiple search requests using the same point in time. For example, if refreshes happen between `search_after` requests, then the results of those requests might not be consistent as changes happening between searches are only visible to the more recent point in time. A point in time must be opened explicitly before being used in search requests. A subsequent search request with the `pit` parameter must not specify `index`, `routing`, or `preference` values as these parameters are copied from the point in time. Just like regular searches, you can use `from` and `size` to page through point in time search results, up to the first 10,000 hits. If you want to retrieve more hits, use PIT with `search_after`. IMPORTANT: The open point in time request and each subsequent search request can return different identifiers; always use the most recently received ID for the next search request. When a PIT that contains shard failures is used in a search request, the missing are always reported in the search response as a `NoShardAvailableActionException` exception. To get rid of these exceptions, a new PIT needs to be created so that shards missing from the previous PIT can be handled, assuming they become available in the meantime. **Keeping point in time alive** The `keep_alive` parameter, which is passed to a open point in time request and search request, extends the time to live of the corresponding point in time. The value does not need to be long enough to process all data — it just needs to be long enough for the next request. Normally, the background merge process optimizes the index by merging together smaller segments to create new, bigger segments. Once the smaller segments are no longer needed they are deleted. However, open point-in-times prevent the old segments from being deleted since they are still in use. TIP: Keeping older segments alive means that more disk space and file handles are needed. Ensure that you have configured your nodes to have ample free file handles. Additionally, if a segment contains deleted or updated documents then the point in time must keep track of whether each document in the segment was live at the time of the initial search request. Ensure that your nodes have sufficient heap space if you have many open point-in-times on an index that is subject to ongoing deletes or updates. Note that a point-in-time doesn't prevent its associated indices from being deleted. You can check how many point-in-times (that is, search contexts) are open with the nodes stats API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/point-in-time-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-open-point-in-time | Elasticsearch API documentation} */ export default async function OpenPointInTimeApi (this: That, params: T.OpenPointInTimeRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function OpenPointInTimeApi (this: That, params: T.OpenPointInTimeRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/ping.ts b/src/api/api/ping.ts index 277e3c725..908709afd 100644 --- a/src/api/api/ping.ts +++ b/src/api/api/ping.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Ping the cluster. Get information about whether the cluster is running. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/index.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-cluster | Elasticsearch API documentation} */ export default async function PingApi (this: That, params?: T.PingRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function PingApi (this: That, params?: T.PingRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/put_script.ts b/src/api/api/put_script.ts index a989cf966..d3350ca5b 100644 --- a/src/api/api/put_script.ts +++ b/src/api/api/put_script.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Create or update a script or search template. Creates or updates a stored script or search template. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/modules-scripting.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-put-script | Elasticsearch API documentation} */ export default async function PutScriptApi (this: That, params: T.PutScriptRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function PutScriptApi (this: That, params: T.PutScriptRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/query_rules.ts b/src/api/api/query_rules.ts index efddebcc9..bb7a964ee 100644 --- a/src/api/api/query_rules.ts +++ b/src/api/api/query_rules.ts @@ -45,7 +45,7 @@ export default class QueryRules { /** * Delete a query rule. Delete a query rule within a query ruleset. This is a destructive action that is only recoverable by re-adding the same rule with the create or update query rule API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-query-rule.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-delete-rule | Elasticsearch API documentation} */ async deleteRule (this: That, params: T.QueryRulesDeleteRuleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteRule (this: That, params: T.QueryRulesDeleteRuleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -88,7 +88,7 @@ export default class QueryRules { /** * Delete a query ruleset. Remove a query ruleset and its associated data. This is a destructive action that is not recoverable. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-query-ruleset.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-delete-ruleset | Elasticsearch API documentation} */ async deleteRuleset (this: That, params: T.QueryRulesDeleteRulesetRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteRuleset (this: That, params: T.QueryRulesDeleteRulesetRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -130,7 +130,7 @@ export default class QueryRules { /** * Get a query rule. Get details about a query rule within a query ruleset. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-query-rule.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-get-rule | Elasticsearch API documentation} */ async getRule (this: That, params: T.QueryRulesGetRuleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getRule (this: That, params: T.QueryRulesGetRuleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -173,7 +173,7 @@ export default class QueryRules { /** * Get a query ruleset. Get details about a query ruleset. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-query-ruleset.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-get-ruleset | Elasticsearch API documentation} */ async getRuleset (this: That, params: T.QueryRulesGetRulesetRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getRuleset (this: That, params: T.QueryRulesGetRulesetRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -215,7 +215,7 @@ export default class QueryRules { /** * Get all query rulesets. Get summarized information about the query rulesets. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/list-query-rulesets.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-list-rulesets | Elasticsearch API documentation} */ async listRulesets (this: That, params?: T.QueryRulesListRulesetsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async listRulesets (this: That, params?: T.QueryRulesListRulesetsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -255,7 +255,7 @@ export default class QueryRules { /** * Create or update a query rule. Create or update a query rule within a query ruleset. IMPORTANT: Due to limitations within pinned queries, you can only pin documents using ids or docs, but cannot use both in single rule. It is advised to use one or the other in query rulesets, to avoid errors. Additionally, pinned queries have a maximum limit of 100 pinned hits. If multiple matching rules pin more than 100 documents, only the first 100 documents are pinned in the order they are specified in the ruleset. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-query-rule.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-put-rule | Elasticsearch API documentation} */ async putRule (this: That, params: T.QueryRulesPutRuleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putRule (this: That, params: T.QueryRulesPutRuleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -303,7 +303,7 @@ export default class QueryRules { /** * Create or update a query ruleset. There is a limit of 100 rules per ruleset. This limit can be increased by using the `xpack.applications.rules.max_rules_per_ruleset` cluster setting. IMPORTANT: Due to limitations within pinned queries, you can only select documents using `ids` or `docs`, but cannot use both in single rule. It is advised to use one or the other in query rulesets, to avoid errors. Additionally, pinned queries have a maximum limit of 100 pinned hits. If multiple matching rules pin more than 100 documents, only the first 100 documents are pinned in the order they are specified in the ruleset. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-query-ruleset.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-put-ruleset | Elasticsearch API documentation} */ async putRuleset (this: That, params: T.QueryRulesPutRulesetRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putRuleset (this: That, params: T.QueryRulesPutRulesetRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -350,7 +350,7 @@ export default class QueryRules { /** * Test a query ruleset. Evaluate match criteria against a query ruleset to identify the rules that would match that criteria. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/test-query-ruleset.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-query-rules-test | Elasticsearch API documentation} */ async test (this: That, params: T.QueryRulesTestRequest, options?: TransportRequestOptionsWithOutMeta): Promise async test (this: That, params: T.QueryRulesTestRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/rank_eval.ts b/src/api/api/rank_eval.ts index 890b2eec2..bd3af65e5 100644 --- a/src/api/api/rank_eval.ts +++ b/src/api/api/rank_eval.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Evaluate ranked search results. Evaluate the quality of ranked search results over a set of typical search queries. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-rank-eval.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rank-eval | Elasticsearch API documentation} */ export default async function RankEvalApi (this: That, params: T.RankEvalRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function RankEvalApi (this: That, params: T.RankEvalRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/reindex.ts b/src/api/api/reindex.ts index 74f29853c..5c83f147b 100644 --- a/src/api/api/reindex.ts +++ b/src/api/api/reindex.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Reindex documents. Copy documents from a source to a destination. You can copy all documents to the destination index or reindex a subset of the documents. The source can be any existing index, alias, or data stream. The destination must differ from the source. For example, you cannot reindex a data stream into itself. IMPORTANT: Reindex requires `_source` to be enabled for all documents in the source. The destination should be configured as wanted before calling the reindex API. Reindex does not copy the settings from the source or its associated template. Mappings, shard counts, and replicas, for example, must be configured ahead of time. If the Elasticsearch security features are enabled, you must have the following security privileges: * The `read` index privilege for the source data stream, index, or alias. * The `write` index privilege for the destination data stream, index, or index alias. * To automatically create a data stream or index with a reindex API request, you must have the `auto_configure`, `create_index`, or `manage` index privilege for the destination data stream, index, or alias. * If reindexing from a remote cluster, the `source.remote.user` must have the `monitor` cluster privilege and the `read` index privilege for the source data stream, index, or alias. If reindexing from a remote cluster, you must explicitly allow the remote host in the `reindex.remote.whitelist` setting. Automatic data stream creation requires a matching index template with data stream enabled. The `dest` element can be configured like the index API to control optimistic concurrency control. Omitting `version_type` or setting it to `internal` causes Elasticsearch to blindly dump documents into the destination, overwriting any that happen to have the same ID. Setting `version_type` to `external` causes Elasticsearch to preserve the `version` from the source, create any documents that are missing, and update any documents that have an older version in the destination than they do in the source. Setting `op_type` to `create` causes the reindex API to create only missing documents in the destination. All existing documents will cause a version conflict. IMPORTANT: Because data streams are append-only, any reindex request to a destination data stream must have an `op_type` of `create`. A reindex can only add new documents to a destination data stream. It cannot update existing documents in a destination data stream. By default, version conflicts abort the reindex process. To continue reindexing if there are conflicts, set the `conflicts` request body property to `proceed`. In this case, the response includes a count of the version conflicts that were encountered. Note that the handling of other error types is unaffected by the `conflicts` property. Additionally, if you opt to count version conflicts, the operation could attempt to reindex more documents from the source than `max_docs` until it has successfully indexed `max_docs` documents into the target or it has gone through every document in the source query. NOTE: The reindex API makes no effort to handle ID collisions. The last document written will "win" but the order isn't usually predictable so it is not a good idea to rely on this behavior. Instead, make sure that IDs are unique by using a script. **Running reindex asynchronously** If the request contains `wait_for_completion=false`, Elasticsearch performs some preflight checks, launches the request, and returns a task you can use to cancel or get the status of the task. Elasticsearch creates a record of this task as a document at `_tasks/`. **Reindex from multiple sources** If you have many sources to reindex it is generally better to reindex them one at a time rather than using a glob pattern to pick up multiple sources. That way you can resume the process if there are any errors by removing the partially completed source and starting over. It also makes parallelizing the process fairly simple: split the list of sources to reindex and run each list in parallel. For example, you can use a bash script like this: ``` for index in i1 i2 i3 i4 i5; do curl -HContent-Type:application/json -XPOST localhost:9200/_reindex?pretty -d'{ "source": { "index": "'$index'" }, "dest": { "index": "'$index'-reindexed" } }' done ``` **Throttling** Set `requests_per_second` to any positive decimal number (`1.4`, `6`, `1000`, for example) to throttle the rate at which reindex issues batches of index operations. Requests are throttled by padding each batch with a wait time. To turn off throttling, set `requests_per_second` to `-1`. The throttling is done by waiting between batches so that the scroll that reindex uses internally can be given a timeout that takes into account the padding. The padding time is the difference between the batch size divided by the `requests_per_second` and the time spent writing. By default the batch size is `1000`, so if `requests_per_second` is set to `500`: ``` target_time = 1000 / 500 per second = 2 seconds wait_time = target_time - write_time = 2 seconds - .5 seconds = 1.5 seconds ``` Since the batch is issued as a single bulk request, large batch sizes cause Elasticsearch to create many requests and then wait for a while before starting the next set. This is "bursty" instead of "smooth". **Slicing** Reindex supports sliced scroll to parallelize the reindexing process. This parallelization can improve efficiency and provide a convenient way to break the request down into smaller parts. NOTE: Reindexing from remote clusters does not support manual or automatic slicing. You can slice a reindex request manually by providing a slice ID and total number of slices to each request. You can also let reindex automatically parallelize by using sliced scroll to slice on `_id`. The `slices` parameter specifies the number of slices to use. Adding `slices` to the reindex request just automates the manual process, creating sub-requests which means it has some quirks: * You can see these requests in the tasks API. These sub-requests are "child" tasks of the task for the request with slices. * Fetching the status of the task for the request with `slices` only contains the status of completed slices. * These sub-requests are individually addressable for things like cancellation and rethrottling. * Rethrottling the request with `slices` will rethrottle the unfinished sub-request proportionally. * Canceling the request with `slices` will cancel each sub-request. * Due to the nature of `slices`, each sub-request won't get a perfectly even portion of the documents. All documents will be addressed, but some slices may be larger than others. Expect larger slices to have a more even distribution. * Parameters like `requests_per_second` and `max_docs` on a request with `slices` are distributed proportionally to each sub-request. Combine that with the previous point about distribution being uneven and you should conclude that using `max_docs` with `slices` might not result in exactly `max_docs` documents being reindexed. * Each sub-request gets a slightly different snapshot of the source, though these are all taken at approximately the same time. If slicing automatically, setting `slices` to `auto` will choose a reasonable number for most indices. If slicing manually or otherwise tuning automatic slicing, use the following guidelines. Query performance is most efficient when the number of slices is equal to the number of shards in the index. If that number is large (for example, `500`), choose a lower number as too many slices will hurt performance. Setting slices higher than the number of shards generally does not improve efficiency and adds overhead. Indexing performance scales linearly across available resources with the number of slices. Whether query or indexing performance dominates the runtime depends on the documents being reindexed and cluster resources. **Modify documents during reindexing** Like `_update_by_query`, reindex operations support a script that modifies the document. Unlike `_update_by_query`, the script is allowed to modify the document's metadata. Just as in `_update_by_query`, you can set `ctx.op` to change the operation that is run on the destination. For example, set `ctx.op` to `noop` if your script decides that the document doesn’t have to be indexed in the destination. This "no operation" will be reported in the `noop` counter in the response body. Set `ctx.op` to `delete` if your script decides that the document must be deleted from the destination. The deletion will be reported in the `deleted` counter in the response body. Setting `ctx.op` to anything else will return an error, as will setting any other field in `ctx`. Think of the possibilities! Just be careful; you are able to change: * `_id` * `_index` * `_version` * `_routing` Setting `_version` to `null` or clearing it from the `ctx` map is just like not sending the version in an indexing request. It will cause the document to be overwritten in the destination regardless of the version on the target or the version type you use in the reindex API. **Reindex from remote** Reindex supports reindexing from a remote Elasticsearch cluster. The `host` parameter must contain a scheme, host, port, and optional path. The `username` and `password` parameters are optional and when they are present the reindex operation will connect to the remote Elasticsearch node using basic authentication. Be sure to use HTTPS when using basic authentication or the password will be sent in plain text. There are a range of settings available to configure the behavior of the HTTPS connection. When using Elastic Cloud, it is also possible to authenticate against the remote cluster through the use of a valid API key. Remote hosts must be explicitly allowed with the `reindex.remote.whitelist` setting. It can be set to a comma delimited list of allowed remote host and port combinations. Scheme is ignored; only the host and port are used. For example: ``` reindex.remote.whitelist: [otherhost:9200, another:9200, 127.0.10.*:9200, localhost:*"] ``` The list of allowed hosts must be configured on any nodes that will coordinate the reindex. This feature should work with remote clusters of any version of Elasticsearch. This should enable you to upgrade from any version of Elasticsearch to the current version by reindexing from a cluster of the old version. WARNING: Elasticsearch does not support forward compatibility across major versions. For example, you cannot reindex from a 7.x cluster into a 6.x cluster. To enable queries sent to older versions of Elasticsearch, the `query` parameter is sent directly to the remote host without validation or modification. NOTE: Reindexing from remote clusters does not support manual or automatic slicing. Reindexing from a remote server uses an on-heap buffer that defaults to a maximum size of 100mb. If the remote index includes very large documents you'll need to use a smaller batch size. It is also possible to set the socket read timeout on the remote connection with the `socket_timeout` field and the connection timeout with the `connect_timeout` field. Both default to 30 seconds. **Configuring SSL parameters** Reindex from remote supports configurable SSL settings. These must be specified in the `elasticsearch.yml` file, with the exception of the secure settings, which you add in the Elasticsearch keystore. It is not possible to configure SSL in the body of the reindex request. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-reindex.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-reindex | Elasticsearch API documentation} */ export default async function ReindexApi (this: That, params: T.ReindexRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function ReindexApi (this: That, params: T.ReindexRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/reindex_rethrottle.ts b/src/api/api/reindex_rethrottle.ts index 9653803eb..d32f80c01 100644 --- a/src/api/api/reindex_rethrottle.ts +++ b/src/api/api/reindex_rethrottle.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Throttle a reindex operation. Change the number of requests per second for a particular reindex operation. For example: ``` POST _reindex/r1A2WoRbTwKZ516z6NEs5A:36619/_rethrottle?requests_per_second=-1 ``` Rethrottling that speeds up the query takes effect immediately. Rethrottling that slows down the query will take effect after completing the current batch. This behavior prevents scroll timeouts. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-reindex.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-reindex | Elasticsearch API documentation} */ export default async function ReindexRethrottleApi (this: That, params: T.ReindexRethrottleRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function ReindexRethrottleApi (this: That, params: T.ReindexRethrottleRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/render_search_template.ts b/src/api/api/render_search_template.ts index 650ba34b1..57b5377c6 100644 --- a/src/api/api/render_search_template.ts +++ b/src/api/api/render_search_template.ts @@ -39,14 +39,14 @@ interface That { transport: Transport } /** * Render a search template. Render a search template as a search request body. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/render-search-template-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-render-search-template | Elasticsearch API documentation} */ export default async function RenderSearchTemplateApi (this: That, params?: T.RenderSearchTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function RenderSearchTemplateApi (this: That, params?: T.RenderSearchTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise> export default async function RenderSearchTemplateApi (this: That, params?: T.RenderSearchTemplateRequest, options?: TransportRequestOptions): Promise export default async function RenderSearchTemplateApi (this: That, params?: T.RenderSearchTemplateRequest, options?: TransportRequestOptions): Promise { - const acceptedPath: string[] = ['id'] - const acceptedBody: string[] = ['file', 'params', 'source'] + const acceptedPath: string[] = [] + const acceptedBody: string[] = ['id', 'file', 'params', 'source'] const userQuery = params?.querystring const querystring: Record = userQuery != null ? { ...userQuery } : {} diff --git a/src/api/api/rollup.ts b/src/api/api/rollup.ts index 16401f165..b45043728 100644 --- a/src/api/api/rollup.ts +++ b/src/api/api/rollup.ts @@ -45,7 +45,7 @@ export default class Rollup { /** * Delete a rollup job. A job must be stopped before it can be deleted. If you attempt to delete a started job, an error occurs. Similarly, if you attempt to delete a nonexistent job, an exception occurs. IMPORTANT: When you delete a job, you remove only the process that is actively monitoring and rolling up data. The API does not delete any previously rolled up data. This is by design; a user may wish to roll up a static data set. Because the data set is static, after it has been fully rolled up there is no need to keep the indexing rollup job around (as there will be no new data). Thus the job can be deleted, leaving behind the rolled up data for analysis. If you wish to also remove the rollup data and the rollup index contains the data for only a single job, you can delete the whole rollup index. If the rollup index stores data from several jobs, you must issue a delete-by-query that targets the rollup job's identifier in the rollup index. For example: ``` POST my_rollup_index/_delete_by_query { "query": { "term": { "_rollup.id": "the_rollup_job_id" } } } ``` - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-delete-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-delete-job | Elasticsearch API documentation} */ async deleteJob (this: That, params: T.RollupDeleteJobRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteJob (this: That, params: T.RollupDeleteJobRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class Rollup { /** * Get rollup job information. Get the configuration, stats, and status of rollup jobs. NOTE: This API returns only active (both `STARTED` and `STOPPED`) jobs. If a job was created, ran for a while, then was deleted, the API does not return any details about it. For details about a historical rollup job, the rollup capabilities API may be more useful. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-get-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-get-jobs | Elasticsearch API documentation} */ async getJobs (this: That, params?: T.RollupGetJobsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getJobs (this: That, params?: T.RollupGetJobsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -137,7 +137,7 @@ export default class Rollup { /** * Get the rollup job capabilities. Get the capabilities of any rollup jobs that have been configured for a specific index or index pattern. This API is useful because a rollup job is often configured to rollup only a subset of fields from the source index. Furthermore, only certain aggregations can be configured for various fields, leading to a limited subset of functionality depending on that configuration. This API enables you to inspect an index and determine: 1. Does this index have associated rollup data somewhere in the cluster? 2. If yes to the first question, what fields were rolled up, what aggregations can be performed, and where does the data live? - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-get-rollup-caps.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-get-rollup-caps | Elasticsearch API documentation} */ async getRollupCaps (this: That, params?: T.RollupGetRollupCapsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getRollupCaps (this: That, params?: T.RollupGetRollupCapsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -187,7 +187,7 @@ export default class Rollup { /** * Get the rollup index capabilities. Get the rollup capabilities of all jobs inside of a rollup index. A single rollup index may store the data for multiple rollup jobs and may have a variety of capabilities depending on those jobs. This API enables you to determine: * What jobs are stored in an index (or indices specified via a pattern)? * What target indices were rolled up, what fields were used in those rollups, and what aggregations can be performed on each job? - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-get-rollup-index-caps.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-get-rollup-index-caps | Elasticsearch API documentation} */ async getRollupIndexCaps (this: That, params: T.RollupGetRollupIndexCapsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getRollupIndexCaps (this: That, params: T.RollupGetRollupIndexCapsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -229,7 +229,7 @@ export default class Rollup { /** * Create a rollup job. WARNING: From 8.15.0, calling this API in a cluster with no rollup usage will fail with a message about the deprecation and planned removal of rollup features. A cluster needs to contain either a rollup job or a rollup index in order for this API to be allowed to run. The rollup job configuration contains all the details about how the job should run, when it indexes documents, and what future queries will be able to run against the rollup index. There are three main sections to the job configuration: the logistical details about the job (for example, the cron schedule), the fields that are used for grouping, and what metrics to collect for each group. Jobs are created in a `STOPPED` state. You can start them with the start rollup jobs API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-put-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-put-job | Elasticsearch API documentation} */ async putJob (this: That, params: T.RollupPutJobRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putJob (this: That, params: T.RollupPutJobRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -276,7 +276,7 @@ export default class Rollup { /** * Search rolled-up data. The rollup search endpoint is needed because, internally, rolled-up documents utilize a different document structure than the original data. It rewrites standard Query DSL into a format that matches the rollup documents then takes the response and rewrites it back to what a client would expect given the original query. The request body supports a subset of features from the regular search API. The following functionality is not available: `size`: Because rollups work on pre-aggregated data, no search hits can be returned and so size must be set to zero or omitted entirely. `highlighter`, `suggestors`, `post_filter`, `profile`, `explain`: These are similarly disallowed. **Searching both historical rollup and non-rollup data** The rollup search API has the capability to search across both "live" non-rollup data and the aggregated rollup data. This is done by simply adding the live indices to the URI. For example: ``` GET sensor-1,sensor_rollup/_rollup_search { "size": 0, "aggregations": { "max_temperature": { "max": { "field": "temperature" } } } } ``` The rollup search endpoint does two things when the search runs: * The original request is sent to the non-rollup index unaltered. * A rewritten version of the original request is sent to the rollup index. When the two responses are received, the endpoint rewrites the rollup response and merges the two together. During the merging process, if there is any overlap in buckets between the two responses, the buckets from the non-rollup index are used. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-search.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-rollup-search | Elasticsearch API documentation} */ async rollupSearch> (this: That, params: T.RollupRollupSearchRequest, options?: TransportRequestOptionsWithOutMeta): Promise> async rollupSearch> (this: That, params: T.RollupRollupSearchRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> @@ -323,7 +323,7 @@ export default class Rollup { /** * Start rollup jobs. If you try to start a job that does not exist, an exception occurs. If you try to start a job that is already started, nothing happens. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-start-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-start-job | Elasticsearch API documentation} */ async startJob (this: That, params: T.RollupStartJobRequest, options?: TransportRequestOptionsWithOutMeta): Promise async startJob (this: That, params: T.RollupStartJobRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -365,7 +365,7 @@ export default class Rollup { /** * Stop rollup jobs. If you try to stop a job that does not exist, an exception occurs. If you try to stop a job that is already stopped, nothing happens. Since only a stopped job can be deleted, it can be useful to block the API until the indexer has fully stopped. This is accomplished with the `wait_for_completion` query parameter, and optionally a timeout. For example: ``` POST _rollup/job/sensor/_stop?wait_for_completion=true&timeout=10s ``` The parameter blocks the API call from returning until either the job has moved to STOPPED or the specified time has elapsed. If the specified time elapses without the job moving to STOPPED, a timeout exception occurs. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/rollup-stop-job.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-rollup-stop-job | Elasticsearch API documentation} */ async stopJob (this: That, params: T.RollupStopJobRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stopJob (this: That, params: T.RollupStopJobRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/scroll.ts b/src/api/api/scroll.ts index e6b3fb611..5bd03110b 100644 --- a/src/api/api/scroll.ts +++ b/src/api/api/scroll.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Run a scrolling search. IMPORTANT: The scroll API is no longer recommend for deep pagination. If you need to preserve the index state while paging through more than 10,000 hits, use the `search_after` parameter with a point in time (PIT). The scroll API gets large sets of results from a single scrolling search request. To get the necessary scroll ID, submit a search API request that includes an argument for the `scroll` query parameter. The `scroll` parameter indicates how long Elasticsearch should retain the search context for the request. The search response returns a scroll ID in the `_scroll_id` response body parameter. You can then use the scroll ID with the scroll API to retrieve the next batch of results for the request. If the Elasticsearch security features are enabled, the access to the results of a specific scroll ID is restricted to the user or API key that submitted the search. You can also use the scroll API to specify a new scroll parameter that extends or shortens the retention period for the search context. IMPORTANT: Results from a scrolling search reflect the state of the index at the time of the initial search request. Subsequent indexing or document changes only affect later search and scroll requests. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-request-body.html#request-body-search-scroll | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-scroll | Elasticsearch API documentation} */ export default async function ScrollApi> (this: That, params: T.ScrollRequest, options?: TransportRequestOptionsWithOutMeta): Promise> export default async function ScrollApi> (this: That, params: T.ScrollRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/search.ts b/src/api/api/search.ts index 11294d979..cf2630413 100644 --- a/src/api/api/search.ts +++ b/src/api/api/search.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Run a search. Get search hits that match the query defined in the request. You can provide search queries using the `q` query string parameter or the request body. If both are specified, only the query parameter is used. If the Elasticsearch security features are enabled, you must have the read index privilege for the target data stream, index, or alias. For cross-cluster search, refer to the documentation about configuring CCS privileges. To search a point in time (PIT) for an alias, you must have the `read` index privilege for the alias's data streams or indices. **Search slicing** When paging through a large number of documents, it can be helpful to split the search into multiple slices to consume them independently with the `slice` and `pit` properties. By default the splitting is done first on the shards, then locally on each shard. The local splitting partitions the shard into contiguous ranges based on Lucene document IDs. For instance if the number of shards is equal to 2 and you request 4 slices, the slices 0 and 2 are assigned to the first shard and the slices 1 and 3 are assigned to the second shard. IMPORTANT: The same point-in-time ID should be used for all slices. If different PIT IDs are used, slices can overlap and miss documents. This situation can occur because the splitting criterion is based on Lucene document IDs, which are not stable across changes to the index. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-search.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search | Elasticsearch API documentation} */ export default async function SearchApi> (this: That, params?: T.SearchRequest, options?: TransportRequestOptionsWithOutMeta): Promise> export default async function SearchApi> (this: That, params?: T.SearchRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/search_application.ts b/src/api/api/search_application.ts index b892ec9dd..71e583672 100644 --- a/src/api/api/search_application.ts +++ b/src/api/api/search_application.ts @@ -45,7 +45,7 @@ export default class SearchApplication { /** * Delete a search application. Remove a search application and its associated alias. Indices attached to the search application are not removed. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-search-application.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-delete | Elasticsearch API documentation} */ async delete (this: That, params: T.SearchApplicationDeleteRequest, options?: TransportRequestOptionsWithOutMeta): Promise async delete (this: That, params: T.SearchApplicationDeleteRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class SearchApplication { /** * Delete a behavioral analytics collection. The associated data stream is also deleted. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-analytics-collection.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-delete-behavioral-analytics | Elasticsearch API documentation} */ async deleteBehavioralAnalytics (this: That, params: T.SearchApplicationDeleteBehavioralAnalyticsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteBehavioralAnalytics (this: That, params: T.SearchApplicationDeleteBehavioralAnalyticsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -129,7 +129,7 @@ export default class SearchApplication { /** * Get search application details. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-search-application.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-get | Elasticsearch API documentation} */ async get (this: That, params: T.SearchApplicationGetRequest, options?: TransportRequestOptionsWithOutMeta): Promise async get (this: That, params: T.SearchApplicationGetRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -171,7 +171,7 @@ export default class SearchApplication { /** * Get behavioral analytics collections. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/list-analytics-collection.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-get-behavioral-analytics | Elasticsearch API documentation} */ async getBehavioralAnalytics (this: That, params?: T.SearchApplicationGetBehavioralAnalyticsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getBehavioralAnalytics (this: That, params?: T.SearchApplicationGetBehavioralAnalyticsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -221,7 +221,7 @@ export default class SearchApplication { /** * Get search applications. Get information about search applications. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/list-search-applications.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-get-behavioral-analytics | Elasticsearch API documentation} */ async list (this: That, params?: T.SearchApplicationListRequest, options?: TransportRequestOptionsWithOutMeta): Promise async list (this: That, params?: T.SearchApplicationListRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -261,7 +261,7 @@ export default class SearchApplication { /** * Create a behavioral analytics collection event. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/post-analytics-collection-event.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-post-behavioral-analytics-event | Elasticsearch API documentation} */ async postBehavioralAnalyticsEvent (this: That, params: T.SearchApplicationPostBehavioralAnalyticsEventRequest, options?: TransportRequestOptionsWithOutMeta): Promise async postBehavioralAnalyticsEvent (this: That, params: T.SearchApplicationPostBehavioralAnalyticsEventRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -299,7 +299,7 @@ export default class SearchApplication { /** * Create or update a search application. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-search-application.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-put | Elasticsearch API documentation} */ async put (this: That, params: T.SearchApplicationPutRequest, options?: TransportRequestOptionsWithOutMeta): Promise async put (this: That, params: T.SearchApplicationPutRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -336,7 +336,7 @@ export default class SearchApplication { /** * Create a behavioral analytics collection. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-analytics-collection.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-put-behavioral-analytics | Elasticsearch API documentation} */ async putBehavioralAnalytics (this: That, params: T.SearchApplicationPutBehavioralAnalyticsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putBehavioralAnalytics (this: That, params: T.SearchApplicationPutBehavioralAnalyticsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -378,7 +378,7 @@ export default class SearchApplication { /** * Render a search application query. Generate an Elasticsearch query using the specified query parameters and the search template associated with the search application or a default template if none is specified. If a parameter used in the search template is not specified in `params`, the parameter's default value will be used. The API returns the specific Elasticsearch query that would be generated and run by calling the search application search API. You must have `read` privileges on the backing alias of the search application. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-application-render-query.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-render-query | Elasticsearch API documentation} */ async renderQuery (this: That, params: T.SearchApplicationRenderQueryRequest, options?: TransportRequestOptionsWithOutMeta): Promise async renderQuery (this: That, params: T.SearchApplicationRenderQueryRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -425,7 +425,7 @@ export default class SearchApplication { /** * Run a search application search. Generate and run an Elasticsearch query that uses the specified query parameteter and the search template associated with the search application or default template. Unspecified template parameters are assigned their default values if applicable. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-application-search.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-application-search | Elasticsearch API documentation} */ async search> (this: That, params: T.SearchApplicationSearchRequest, options?: TransportRequestOptionsWithOutMeta): Promise> async search> (this: That, params: T.SearchApplicationSearchRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/search_mvt.ts b/src/api/api/search_mvt.ts index 54e002d7a..c9384a91e 100644 --- a/src/api/api/search_mvt.ts +++ b/src/api/api/search_mvt.ts @@ -38,8 +38,8 @@ import * as T from '../types' interface That { transport: Transport } /** - * Search a vector tile. Search a vector tile for geospatial values. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-vector-tile-api.html | Elasticsearch API documentation} + * Search a vector tile. Search a vector tile for geospatial values. Before using this API, you should be familiar with the Mapbox vector tile specification. The API returns results as a binary mapbox vector tile. Internally, Elasticsearch translates a vector tile search API request into a search containing: * A `geo_bounding_box` query on the ``. The query uses the `//` tile as a bounding box. * A `geotile_grid` or `geohex_grid` aggregation on the ``. The `grid_agg` parameter determines the aggregation type. The aggregation uses the `//` tile as a bounding box. * Optionally, a `geo_bounds` aggregation on the ``. The search only includes this aggregation if the `exact_bounds` parameter is `true`. * If the optional parameter `with_labels` is `true`, the internal search will include a dynamic runtime field that calls the `getLabelPosition` function of the geometry doc value. This enables the generation of new point features containing suggested geometry labels, so that, for example, multi-polygons will have only one label. For example, Elasticsearch may translate a vector tile search API request with a `grid_agg` argument of `geotile` and an `exact_bounds` argument of `true` into the following search ``` GET my-index/_search { "size": 10000, "query": { "geo_bounding_box": { "my-geo-field": { "top_left": { "lat": -40.979898069620134, "lon": -45 }, "bottom_right": { "lat": -66.51326044311186, "lon": 0 } } } }, "aggregations": { "grid": { "geotile_grid": { "field": "my-geo-field", "precision": 11, "size": 65536, "bounds": { "top_left": { "lat": -40.979898069620134, "lon": -45 }, "bottom_right": { "lat": -66.51326044311186, "lon": 0 } } } }, "bounds": { "geo_bounds": { "field": "my-geo-field", "wrap_longitude": false } } } } ``` The API returns results as a binary Mapbox vector tile. Mapbox vector tiles are encoded as Google Protobufs (PBF). By default, the tile contains three layers: * A `hits` layer containing a feature for each `` value matching the `geo_bounding_box` query. * An `aggs` layer containing a feature for each cell of the `geotile_grid` or `geohex_grid`. The layer only contains features for cells with matching data. * A meta layer containing: * A feature containing a bounding box. By default, this is the bounding box of the tile. * Value ranges for any sub-aggregations on the `geotile_grid` or `geohex_grid`. * Metadata for the search. The API only returns features that can display at its zoom level. For example, if a polygon feature has no area at its zoom level, the API omits it. The API returns errors as UTF-8 encoded JSON. IMPORTANT: You can specify several options for this API as either a query parameter or request body parameter. If you specify both parameters, the query parameter takes precedence. **Grid precision for geotile** For a `grid_agg` of `geotile`, you can use cells in the `aggs` layer as tiles for lower zoom levels. `grid_precision` represents the additional zoom levels available through these cells. The final precision is computed by as follows: ` + grid_precision`. For example, if `` is 7 and `grid_precision` is 8, then the `geotile_grid` aggregation will use a precision of 15. The maximum final precision is 29. The `grid_precision` also determines the number of cells for the grid as follows: `(2^grid_precision) x (2^grid_precision)`. For example, a value of 8 divides the tile into a grid of 256 x 256 cells. The `aggs` layer only contains features for cells with matching data. **Grid precision for geohex** For a `grid_agg` of `geohex`, Elasticsearch uses `` and `grid_precision` to calculate a final precision as follows: ` + grid_precision`. This precision determines the H3 resolution of the hexagonal cells produced by the `geohex` aggregation. The following table maps the H3 resolution for each precision. For example, if `` is 3 and `grid_precision` is 3, the precision is 6. At a precision of 6, hexagonal cells have an H3 resolution of 2. If `` is 3 and `grid_precision` is 4, the precision is 7. At a precision of 7, hexagonal cells have an H3 resolution of 3. | Precision | Unique tile bins | H3 resolution | Unique hex bins | Ratio | | --------- | ---------------- | ------------- | ----------------| ----- | | 1 | 4 | 0 | 122 | 30.5 | | 2 | 16 | 0 | 122 | 7.625 | | 3 | 64 | 1 | 842 | 13.15625 | | 4 | 256 | 1 | 842 | 3.2890625 | | 5 | 1024 | 2 | 5882 | 5.744140625 | | 6 | 4096 | 2 | 5882 | 1.436035156 | | 7 | 16384 | 3 | 41162 | 2.512329102 | | 8 | 65536 | 3 | 41162 | 0.6280822754 | | 9 | 262144 | 4 | 288122 | 1.099098206 | | 10 | 1048576 | 4 | 288122 | 0.2747745514 | | 11 | 4194304 | 5 | 2016842 | 0.4808526039 | | 12 | 16777216 | 6 | 14117882 | 0.8414913416 | | 13 | 67108864 | 6 | 14117882 | 0.2103728354 | | 14 | 268435456 | 7 | 98825162 | 0.3681524172 | | 15 | 1073741824 | 8 | 691776122 | 0.644266719 | | 16 | 4294967296 | 8 | 691776122 | 0.1610666797 | | 17 | 17179869184 | 9 | 4842432842 | 0.2818666889 | | 18 | 68719476736 | 10 | 33897029882 | 0.4932667053 | | 19 | 274877906944 | 11 | 237279209162 | 0.8632167343 | | 20 | 1099511627776 | 11 | 237279209162 | 0.2158041836 | | 21 | 4398046511104 | 12 | 1660954464122 | 0.3776573213 | | 22 | 17592186044416 | 13 | 11626681248842 | 0.6609003122 | | 23 | 70368744177664 | 13 | 11626681248842 | 0.165225078 | | 24 | 281474976710656 | 14 | 81386768741882 | 0.2891438866 | | 25 | 1125899906842620 | 15 | 569707381193162 | 0.5060018015 | | 26 | 4503599627370500 | 15 | 569707381193162 | 0.1265004504 | | 27 | 18014398509482000 | 15 | 569707381193162 | 0.03162511259 | | 28 | 72057594037927900 | 15 | 569707381193162 | 0.007906278149 | | 29 | 288230376151712000 | 15 | 569707381193162 | 0.001976569537 | Hexagonal cells don't align perfectly on a vector tile. Some cells may intersect more than one vector tile. To compute the H3 resolution for each precision, Elasticsearch compares the average density of hexagonal bins at each resolution with the average density of tile bins at each zoom level. Elasticsearch uses the H3 resolution that is closest to the corresponding geotile density. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-mvt | Elasticsearch API documentation} */ export default async function SearchMvtApi (this: That, params: T.SearchMvtRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function SearchMvtApi (this: That, params: T.SearchMvtRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/search_shards.ts b/src/api/api/search_shards.ts index 544660325..f2fff30a5 100644 --- a/src/api/api/search_shards.ts +++ b/src/api/api/search_shards.ts @@ -38,8 +38,8 @@ import * as T from '../types' interface That { transport: Transport } /** - * Get the search shards. Get the indices and shards that a search request would be run against. This information can be useful for working out issues or planning optimizations with routing and shard preferences. When filtered aliases are used, the filter is returned as part of the indices section. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-shards.html | Elasticsearch API documentation} + * Get the search shards. Get the indices and shards that a search request would be run against. This information can be useful for working out issues or planning optimizations with routing and shard preferences. When filtered aliases are used, the filter is returned as part of the `indices` section. If the Elasticsearch security features are enabled, you must have the `view_index_metadata` or `manage` index privilege for the target data stream, index, or alias. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-shards | Elasticsearch API documentation} */ export default async function SearchShardsApi (this: That, params?: T.SearchShardsRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function SearchShardsApi (this: That, params?: T.SearchShardsRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/search_template.ts b/src/api/api/search_template.ts index 2bcef664e..f63c77a45 100644 --- a/src/api/api/search_template.ts +++ b/src/api/api/search_template.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Run a search with a search template. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-template.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-search-template | Elasticsearch API documentation} */ export default async function SearchTemplateApi (this: That, params?: T.SearchTemplateRequest, options?: TransportRequestOptionsWithOutMeta): Promise> export default async function SearchTemplateApi (this: That, params?: T.SearchTemplateRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/searchable_snapshots.ts b/src/api/api/searchable_snapshots.ts index d26592c27..4c8af1dda 100644 --- a/src/api/api/searchable_snapshots.ts +++ b/src/api/api/searchable_snapshots.ts @@ -45,7 +45,7 @@ export default class SearchableSnapshots { /** * Get cache statistics. Get statistics about the shared cache for partially mounted indices. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/searchable-snapshots-api-cache-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-searchable-snapshots-cache-stats | Elasticsearch API documentation} */ async cacheStats (this: That, params?: T.SearchableSnapshotsCacheStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async cacheStats (this: That, params?: T.SearchableSnapshotsCacheStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -95,7 +95,7 @@ export default class SearchableSnapshots { /** * Clear the cache. Clear indices and data streams from the shared cache for partially mounted indices. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/searchable-snapshots-api-clear-cache.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-searchable-snapshots-clear-cache | Elasticsearch API documentation} */ async clearCache (this: That, params?: T.SearchableSnapshotsClearCacheRequest, options?: TransportRequestOptionsWithOutMeta): Promise async clearCache (this: That, params?: T.SearchableSnapshotsClearCacheRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -145,7 +145,7 @@ export default class SearchableSnapshots { /** * Mount a snapshot. Mount a snapshot as a searchable snapshot index. Do not use this API for snapshots managed by index lifecycle management (ILM). Manually mounting ILM-managed snapshots can interfere with ILM processes. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/searchable-snapshots-api-mount-snapshot.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-searchable-snapshots-mount | Elasticsearch API documentation} */ async mount (this: That, params: T.SearchableSnapshotsMountRequest, options?: TransportRequestOptionsWithOutMeta): Promise async mount (this: That, params: T.SearchableSnapshotsMountRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -193,7 +193,7 @@ export default class SearchableSnapshots { /** * Get searchable snapshot statistics. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/searchable-snapshots-api-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-searchable-snapshots-stats | Elasticsearch API documentation} */ async stats (this: That, params?: T.SearchableSnapshotsStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stats (this: That, params?: T.SearchableSnapshotsStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/security.ts b/src/api/api/security.ts index 201d2c550..3484f5933 100644 --- a/src/api/api/security.ts +++ b/src/api/api/security.ts @@ -45,7 +45,7 @@ export default class Security { /** * Activate a user profile. Create or update a user profile on behalf of another user. NOTE: The user profile feature is designed only for use by Kibana and Elastic's Observability, Enterprise Search, and Elastic Security solutions. Individual users and external applications should not call this API directly. The calling application must have either an `access_token` or a combination of `username` and `password` for the user that the profile document is intended for. Elastic reserves the right to change or remove this feature in future releases without prior notice. This API creates or updates a profile document for end users with information that is extracted from the user's authentication object including `username`, `full_name,` `roles`, and the authentication realm. For example, in the JWT `access_token` case, the profile user's `username` is extracted from the JWT token claim pointed to by the `claims.principal` setting of the JWT realm that authenticated the token. When updating a profile document, the API enables the document if it was disabled. Any updates do not change existing content for either the `labels` or `data` fields. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-activate-user-profile.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-activate-user-profile | Elasticsearch API documentation} */ async activateUserProfile (this: That, params: T.SecurityActivateUserProfileRequest, options?: TransportRequestOptionsWithOutMeta): Promise async activateUserProfile (this: That, params: T.SecurityActivateUserProfileRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -89,7 +89,7 @@ export default class Security { /** * Authenticate a user. Authenticates a user and returns information about the authenticated user. Include the user information in a [basic auth header](https://en.wikipedia.org/wiki/Basic_access_authentication). A successful call returns a JSON structure that shows user information such as their username, the roles that are assigned to the user, any assigned metadata, and information about the realms that authenticated and authorized the user. If the user cannot be authenticated, this API returns a 401 status code. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-authenticate.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-authenticate | Elasticsearch API documentation} */ async authenticate (this: That, params?: T.SecurityAuthenticateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async authenticate (this: That, params?: T.SecurityAuthenticateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -129,7 +129,7 @@ export default class Security { /** * Bulk delete roles. The role management APIs are generally the preferred way to manage roles, rather than using file-based role management. The bulk delete roles API cannot delete roles that are defined in roles files. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-bulk-delete-role.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-bulk-delete-role | Elasticsearch API documentation} */ async bulkDeleteRole (this: That, params: T.SecurityBulkDeleteRoleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async bulkDeleteRole (this: That, params: T.SecurityBulkDeleteRoleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -173,7 +173,7 @@ export default class Security { /** * Bulk create or update roles. The role management APIs are generally the preferred way to manage roles, rather than using file-based role management. The bulk create or update roles API cannot update roles that are defined in roles files. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-bulk-put-role.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-bulk-put-role | Elasticsearch API documentation} */ async bulkPutRole (this: That, params: T.SecurityBulkPutRoleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async bulkPutRole (this: That, params: T.SecurityBulkPutRoleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -217,7 +217,7 @@ export default class Security { /** * Bulk update API keys. Update the attributes for multiple API keys. IMPORTANT: It is not possible to use an API key as the authentication credential for this API. To update API keys, the owner user's credentials are required. This API is similar to the update API key API but enables you to apply the same update to multiple API keys in one API call. This operation can greatly improve performance over making individual updates. It is not possible to update expired or invalidated API keys. This API supports updates to API key access scope, metadata and expiration. The access scope of each API key is derived from the `role_descriptors` you specify in the request and a snapshot of the owner user's permissions at the time of the request. The snapshot of the owner's permissions is updated automatically on every call. IMPORTANT: If you don't specify `role_descriptors` in the request, a call to this API might still change an API key's access scope. This change can occur if the owner user's permissions have changed since the API key was created or last modified. A successful request returns a JSON structure that contains the IDs of all updated API keys, the IDs of API keys that already had the requested changes and did not require an update, and error details for any failed update. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-bulk-update-api-keys.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-bulk-update-api-keys | Elasticsearch API documentation} */ async bulkUpdateApiKeys (this: That, params: T.SecurityBulkUpdateApiKeysRequest, options?: TransportRequestOptionsWithOutMeta): Promise async bulkUpdateApiKeys (this: That, params: T.SecurityBulkUpdateApiKeysRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -261,7 +261,7 @@ export default class Security { /** * Change passwords. Change the passwords of users in the native realm and built-in users. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-change-password.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-change-password | Elasticsearch API documentation} */ async changePassword (this: That, params?: T.SecurityChangePasswordRequest, options?: TransportRequestOptionsWithOutMeta): Promise async changePassword (this: That, params?: T.SecurityChangePasswordRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -316,7 +316,7 @@ export default class Security { /** * Clear the API key cache. Evict a subset of all entries from the API key cache. The cache is also automatically cleared on state changes of the security index. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-clear-api-key-cache.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-clear-api-key-cache | Elasticsearch API documentation} */ async clearApiKeyCache (this: That, params: T.SecurityClearApiKeyCacheRequest, options?: TransportRequestOptionsWithOutMeta): Promise async clearApiKeyCache (this: That, params: T.SecurityClearApiKeyCacheRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -358,7 +358,7 @@ export default class Security { /** * Clear the privileges cache. Evict privileges from the native application privilege cache. The cache is also automatically cleared for applications that have their privileges updated. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-clear-privilege-cache.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-clear-cached-privileges | Elasticsearch API documentation} */ async clearCachedPrivileges (this: That, params: T.SecurityClearCachedPrivilegesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async clearCachedPrivileges (this: That, params: T.SecurityClearCachedPrivilegesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -400,7 +400,7 @@ export default class Security { /** * Clear the user cache. Evict users from the user cache. You can completely clear the cache or evict specific users. User credentials are cached in memory on each node to avoid connecting to a remote authentication service or hitting the disk for every incoming request. There are realm settings that you can use to configure the user cache. For more information, refer to the documentation about controlling the user cache. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-clear-cache.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-clear-cached-realms | Elasticsearch API documentation} */ async clearCachedRealms (this: That, params: T.SecurityClearCachedRealmsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async clearCachedRealms (this: That, params: T.SecurityClearCachedRealmsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -442,7 +442,7 @@ export default class Security { /** * Clear the roles cache. Evict roles from the native role cache. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-clear-role-cache.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-clear-cached-roles | Elasticsearch API documentation} */ async clearCachedRoles (this: That, params: T.SecurityClearCachedRolesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async clearCachedRoles (this: That, params: T.SecurityClearCachedRolesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -484,7 +484,7 @@ export default class Security { /** * Clear service account token caches. Evict a subset of all entries from the service account token caches. Two separate caches exist for service account tokens: one cache for tokens backed by the `service_tokens` file, and another for tokens backed by the `.security` index. This API clears matching entries from both caches. The cache for service account tokens backed by the `.security` index is cleared automatically on state changes of the security index. The cache for tokens backed by the `service_tokens` file is cleared automatically on file changes. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-clear-service-token-caches.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-clear-cached-service-tokens | Elasticsearch API documentation} */ async clearCachedServiceTokens (this: That, params: T.SecurityClearCachedServiceTokensRequest, options?: TransportRequestOptionsWithOutMeta): Promise async clearCachedServiceTokens (this: That, params: T.SecurityClearCachedServiceTokensRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -528,7 +528,7 @@ export default class Security { /** * Create an API key. Create an API key for access without requiring basic authentication. IMPORTANT: If the credential that is used to authenticate this request is an API key, the derived API key cannot have any privileges. If you specify privileges, the API returns an error. A successful request returns a JSON structure that contains the API key, its unique id, and its name. If applicable, it also returns expiration information for the API key in milliseconds. NOTE: By default, API keys never expire. You can specify expiration information when you create the API keys. The API keys are created by the Elasticsearch API key service, which is automatically enabled. To configure or turn off the API key service, refer to API key service setting documentation. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-create-api-key.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-create-api-key | Elasticsearch API documentation} */ async createApiKey (this: That, params?: T.SecurityCreateApiKeyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async createApiKey (this: That, params?: T.SecurityCreateApiKeyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -573,7 +573,7 @@ export default class Security { /** * Create a cross-cluster API key. Create an API key of the `cross_cluster` type for the API key based remote cluster access. A `cross_cluster` API key cannot be used to authenticate through the REST interface. IMPORTANT: To authenticate this request you must use a credential that is not an API key. Even if you use an API key that has the required privilege, the API returns an error. Cross-cluster API keys are created by the Elasticsearch API key service, which is automatically enabled. NOTE: Unlike REST API keys, a cross-cluster API key does not capture permissions of the authenticated user. The API key’s effective permission is exactly as specified with the `access` property. A successful request returns a JSON structure that contains the API key, its unique ID, and its name. If applicable, it also returns expiration information for the API key in milliseconds. By default, API keys never expire. You can specify expiration information when you create the API keys. Cross-cluster API keys can only be updated with the update cross-cluster API key API. Attempting to update them with the update REST API key API or the bulk update REST API keys API will result in an error. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-create-cross-cluster-api-key.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-create-cross-cluster-api-key | Elasticsearch API documentation} */ async createCrossClusterApiKey (this: That, params: T.SecurityCreateCrossClusterApiKeyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async createCrossClusterApiKey (this: That, params: T.SecurityCreateCrossClusterApiKeyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -617,7 +617,7 @@ export default class Security { /** * Create a service account token. Create a service accounts token for access without requiring basic authentication. NOTE: Service account tokens never expire. You must actively delete them if they are no longer needed. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-create-service-token.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-create-service-token | Elasticsearch API documentation} */ async createServiceToken (this: That, params: T.SecurityCreateServiceTokenRequest, options?: TransportRequestOptionsWithOutMeta): Promise async createServiceToken (this: That, params: T.SecurityCreateServiceTokenRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -668,7 +668,7 @@ export default class Security { /** * Delegate PKI authentication. This API implements the exchange of an X509Certificate chain for an Elasticsearch access token. The certificate chain is validated, according to RFC 5280, by sequentially considering the trust configuration of every installed PKI realm that has `delegation.enabled` set to `true`. A successfully trusted client certificate is also subject to the validation of the subject distinguished name according to thw `username_pattern` of the respective realm. This API is called by smart and trusted proxies, such as Kibana, which terminate the user's TLS session but still want to authenticate the user by using a PKI realm—-as if the user connected directly to Elasticsearch. IMPORTANT: The association between the subject public key in the target certificate and the corresponding private key is not validated. This is part of the TLS authentication process and it is delegated to the proxy that calls this API. The proxy is trusted to have performed the TLS authentication and this API translates that authentication into an Elasticsearch access token. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-delegate-pki-authentication.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-delegate-pki | Elasticsearch API documentation} */ async delegatePki (this: That, params: T.SecurityDelegatePkiRequest, options?: TransportRequestOptionsWithOutMeta): Promise async delegatePki (this: That, params: T.SecurityDelegatePkiRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -712,7 +712,7 @@ export default class Security { /** * Delete application privileges. To use this API, you must have one of the following privileges: * The `manage_security` cluster privilege (or a greater privilege such as `all`). * The "Manage Application Privileges" global privilege for the application being referenced in the request. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-delete-privilege.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-delete-privileges | Elasticsearch API documentation} */ async deletePrivileges (this: That, params: T.SecurityDeletePrivilegesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deletePrivileges (this: That, params: T.SecurityDeletePrivilegesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -755,7 +755,7 @@ export default class Security { /** * Delete roles. Delete roles in the native realm. The role management APIs are generally the preferred way to manage roles, rather than using file-based role management. The delete roles API cannot remove roles that are defined in roles files. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-delete-role.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-delete-role | Elasticsearch API documentation} */ async deleteRole (this: That, params: T.SecurityDeleteRoleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteRole (this: That, params: T.SecurityDeleteRoleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -797,7 +797,7 @@ export default class Security { /** * Delete role mappings. Role mappings define which roles are assigned to each user. The role mapping APIs are generally the preferred way to manage role mappings rather than using role mapping files. The delete role mappings API cannot remove role mappings that are defined in role mapping files. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-delete-role-mapping.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-delete-role-mapping | Elasticsearch API documentation} */ async deleteRoleMapping (this: That, params: T.SecurityDeleteRoleMappingRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteRoleMapping (this: That, params: T.SecurityDeleteRoleMappingRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -839,7 +839,7 @@ export default class Security { /** * Delete service account tokens. Delete service account tokens for a service in a specified namespace. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-delete-service-token.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-delete-service-token | Elasticsearch API documentation} */ async deleteServiceToken (this: That, params: T.SecurityDeleteServiceTokenRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteServiceToken (this: That, params: T.SecurityDeleteServiceTokenRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -883,7 +883,7 @@ export default class Security { /** * Delete users. Delete users from the native realm. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-delete-user.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-delete-user | Elasticsearch API documentation} */ async deleteUser (this: That, params: T.SecurityDeleteUserRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteUser (this: That, params: T.SecurityDeleteUserRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -925,7 +925,7 @@ export default class Security { /** * Disable users. Disable users in the native realm. By default, when you create users, they are enabled. You can use this API to revoke a user's access to Elasticsearch. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-disable-user.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-disable-user | Elasticsearch API documentation} */ async disableUser (this: That, params: T.SecurityDisableUserRequest, options?: TransportRequestOptionsWithOutMeta): Promise async disableUser (this: That, params: T.SecurityDisableUserRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -967,7 +967,7 @@ export default class Security { /** * Disable a user profile. Disable user profiles so that they are not visible in user profile searches. NOTE: The user profile feature is designed only for use by Kibana and Elastic's Observability, Enterprise Search, and Elastic Security solutions. Individual users and external applications should not call this API directly. Elastic reserves the right to change or remove this feature in future releases without prior notice. When you activate a user profile, its automatically enabled and visible in user profile searches. You can use the disable user profile API to disable a user profile so it’s not visible in these searches. To re-enable a disabled user profile, use the enable user profile API . - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-disable-user-profile.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-disable-user-profile | Elasticsearch API documentation} */ async disableUserProfile (this: That, params: T.SecurityDisableUserProfileRequest, options?: TransportRequestOptionsWithOutMeta): Promise async disableUserProfile (this: That, params: T.SecurityDisableUserProfileRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1009,7 +1009,7 @@ export default class Security { /** * Enable users. Enable users in the native realm. By default, when you create users, they are enabled. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-enable-user.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-enable-user | Elasticsearch API documentation} */ async enableUser (this: That, params: T.SecurityEnableUserRequest, options?: TransportRequestOptionsWithOutMeta): Promise async enableUser (this: That, params: T.SecurityEnableUserRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1051,7 +1051,7 @@ export default class Security { /** * Enable a user profile. Enable user profiles to make them visible in user profile searches. NOTE: The user profile feature is designed only for use by Kibana and Elastic's Observability, Enterprise Search, and Elastic Security solutions. Individual users and external applications should not call this API directly. Elastic reserves the right to change or remove this feature in future releases without prior notice. When you activate a user profile, it's automatically enabled and visible in user profile searches. If you later disable the user profile, you can use the enable user profile API to make the profile visible in these searches again. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-enable-user-profile.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-enable-user-profile | Elasticsearch API documentation} */ async enableUserProfile (this: That, params: T.SecurityEnableUserProfileRequest, options?: TransportRequestOptionsWithOutMeta): Promise async enableUserProfile (this: That, params: T.SecurityEnableUserProfileRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1093,7 +1093,7 @@ export default class Security { /** * Enroll Kibana. Enable a Kibana instance to configure itself for communication with a secured Elasticsearch cluster. NOTE: This API is currently intended for internal use only by Kibana. Kibana uses this API internally to configure itself for communications with an Elasticsearch cluster that already has security features enabled. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-kibana-enrollment.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-enroll-kibana | Elasticsearch API documentation} */ async enrollKibana (this: That, params?: T.SecurityEnrollKibanaRequest, options?: TransportRequestOptionsWithOutMeta): Promise async enrollKibana (this: That, params?: T.SecurityEnrollKibanaRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1133,7 +1133,7 @@ export default class Security { /** * Enroll a node. Enroll a new node to allow it to join an existing cluster with security features enabled. The response contains all the necessary information for the joining node to bootstrap discovery and security related settings so that it can successfully join the cluster. The response contains key and certificate material that allows the caller to generate valid signed certificates for the HTTP layer of all nodes in the cluster. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-node-enrollment.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-enroll-node | Elasticsearch API documentation} */ async enrollNode (this: That, params?: T.SecurityEnrollNodeRequest, options?: TransportRequestOptionsWithOutMeta): Promise async enrollNode (this: That, params?: T.SecurityEnrollNodeRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1173,7 +1173,7 @@ export default class Security { /** * Get API key information. Retrieves information for one or more API keys. NOTE: If you have only the `manage_own_api_key` privilege, this API returns only the API keys that you own. If you have `read_security`, `manage_api_key` or greater privileges (including `manage_security`), this API returns all API keys regardless of ownership. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-get-api-key.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-api-key | Elasticsearch API documentation} */ async getApiKey (this: That, params?: T.SecurityGetApiKeyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getApiKey (this: That, params?: T.SecurityGetApiKeyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1213,7 +1213,7 @@ export default class Security { /** * Get builtin privileges. Get the list of cluster privileges and index privileges that are available in this version of Elasticsearch. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-get-builtin-privileges.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-builtin-privileges | Elasticsearch API documentation} */ async getBuiltinPrivileges (this: That, params?: T.SecurityGetBuiltinPrivilegesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getBuiltinPrivileges (this: That, params?: T.SecurityGetBuiltinPrivilegesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1253,7 +1253,7 @@ export default class Security { /** * Get application privileges. To use this API, you must have one of the following privileges: * The `read_security` cluster privilege (or a greater privilege such as `manage_security` or `all`). * The "Manage Application Privileges" global privilege for the application being referenced in the request. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-get-privileges.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-privileges | Elasticsearch API documentation} */ async getPrivileges (this: That, params?: T.SecurityGetPrivilegesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getPrivileges (this: That, params?: T.SecurityGetPrivilegesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1307,7 +1307,7 @@ export default class Security { /** * Get roles. Get roles in the native realm. The role management APIs are generally the preferred way to manage roles, rather than using file-based role management. The get roles API cannot retrieve roles that are defined in roles files. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-get-role.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-role | Elasticsearch API documentation} */ async getRole (this: That, params?: T.SecurityGetRoleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getRole (this: That, params?: T.SecurityGetRoleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1357,7 +1357,7 @@ export default class Security { /** * Get role mappings. Role mappings define which roles are assigned to each user. The role mapping APIs are generally the preferred way to manage role mappings rather than using role mapping files. The get role mappings API cannot retrieve role mappings that are defined in role mapping files. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-get-role-mapping.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-role-mapping | Elasticsearch API documentation} */ async getRoleMapping (this: That, params?: T.SecurityGetRoleMappingRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getRoleMapping (this: That, params?: T.SecurityGetRoleMappingRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1407,7 +1407,7 @@ export default class Security { /** * Get service accounts. Get a list of service accounts that match the provided path parameters. NOTE: Currently, only the `elastic/fleet-server` service account is available. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-get-service-accounts.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-service-accounts | Elasticsearch API documentation} */ async getServiceAccounts (this: That, params?: T.SecurityGetServiceAccountsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getServiceAccounts (this: That, params?: T.SecurityGetServiceAccountsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1461,7 +1461,7 @@ export default class Security { /** * Get service account credentials. To use this API, you must have at least the `read_security` cluster privilege (or a greater privilege such as `manage_service_account` or `manage_security`). The response includes service account tokens that were created with the create service account tokens API as well as file-backed tokens from all nodes of the cluster. NOTE: For tokens backed by the `service_tokens` file, the API collects them from all nodes of the cluster. Tokens with the same name from different nodes are assumed to be the same token and are only counted once towards the total number of service tokens. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-get-service-credentials.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-service-credentials | Elasticsearch API documentation} */ async getServiceCredentials (this: That, params: T.SecurityGetServiceCredentialsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getServiceCredentials (this: That, params: T.SecurityGetServiceCredentialsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1504,7 +1504,7 @@ export default class Security { /** * Get security index settings. Get the user-configurable settings for the security internal index (`.security` and associated indices). Only a subset of the index settings — those that are user-configurable—will be shown. This includes: * `index.auto_expand_replicas` * `index.number_of_replicas` - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-get-settings.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-settings | Elasticsearch API documentation} */ async getSettings (this: That, params?: T.SecurityGetSettingsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getSettings (this: That, params?: T.SecurityGetSettingsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1544,7 +1544,7 @@ export default class Security { /** * Get a token. Create a bearer token for access without requiring basic authentication. The tokens are created by the Elasticsearch Token Service, which is automatically enabled when you configure TLS on the HTTP interface. Alternatively, you can explicitly enable the `xpack.security.authc.token.enabled` setting. When you are running in production mode, a bootstrap check prevents you from enabling the token service unless you also enable TLS on the HTTP interface. The get token API takes the same parameters as a typical OAuth 2.0 token API except for the use of a JSON request body. A successful get token API call returns a JSON structure that contains the access token, the amount of time (seconds) that the token expires in, the type, and the scope if available. The tokens returned by the get token API have a finite period of time for which they are valid and after that time period, they can no longer be used. That time period is defined by the `xpack.security.authc.token.timeout` setting. If you want to invalidate a token immediately, you can do so by using the invalidate token API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-get-token.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-token | Elasticsearch API documentation} */ async getToken (this: That, params?: T.SecurityGetTokenRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getToken (this: That, params?: T.SecurityGetTokenRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1589,7 +1589,7 @@ export default class Security { /** * Get users. Get information about users in the native realm and built-in users. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-get-user.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-user | Elasticsearch API documentation} */ async getUser (this: That, params?: T.SecurityGetUserRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getUser (this: That, params?: T.SecurityGetUserRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1639,7 +1639,7 @@ export default class Security { /** * Get user privileges. Get the security privileges for the logged in user. All users can use this API, but only to determine their own privileges. To check the privileges of other users, you must use the run as feature. To check whether a user has a specific list of privileges, use the has privileges API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-get-user-privileges.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-user-privileges | Elasticsearch API documentation} */ async getUserPrivileges (this: That, params?: T.SecurityGetUserPrivilegesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getUserPrivileges (this: That, params?: T.SecurityGetUserPrivilegesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1679,7 +1679,7 @@ export default class Security { /** * Get a user profile. Get a user's profile using the unique profile ID. NOTE: The user profile feature is designed only for use by Kibana and Elastic's Observability, Enterprise Search, and Elastic Security solutions. Individual users and external applications should not call this API directly. Elastic reserves the right to change or remove this feature in future releases without prior notice. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-get-user-profile.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-get-user-profile | Elasticsearch API documentation} */ async getUserProfile (this: That, params: T.SecurityGetUserProfileRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getUserProfile (this: That, params: T.SecurityGetUserProfileRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1721,7 +1721,7 @@ export default class Security { /** * Grant an API key. Create an API key on behalf of another user. This API is similar to the create API keys API, however it creates the API key for a user that is different than the user that runs the API. The caller must have authentication credentials for the user on whose behalf the API key will be created. It is not possible to use this API to create an API key without that user's credentials. The supported user authentication credential types are: * username and password * Elasticsearch access tokens * JWTs The user, for whom the authentication credentials is provided, can optionally "run as" (impersonate) another user. In this case, the API key will be created on behalf of the impersonated user. This API is intended be used by applications that need to create and manage API keys for end users, but cannot guarantee that those users have permission to create API keys on their own behalf. The API keys are created by the Elasticsearch API key service, which is automatically enabled. A successful grant API key API call returns a JSON structure that contains the API key, its unique id, and its name. If applicable, it also returns expiration information for the API key in milliseconds. By default, API keys never expire. You can specify expiration information when you create the API keys. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-grant-api-key.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-grant-api-key | Elasticsearch API documentation} */ async grantApiKey (this: That, params: T.SecurityGrantApiKeyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async grantApiKey (this: That, params: T.SecurityGrantApiKeyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1765,7 +1765,7 @@ export default class Security { /** * Check user privileges. Determine whether the specified user has a specified list of privileges. All users can use this API, but only to determine their own privileges. To check the privileges of other users, you must use the run as feature. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-has-privileges.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-has-privileges | Elasticsearch API documentation} */ async hasPrivileges (this: That, params?: T.SecurityHasPrivilegesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async hasPrivileges (this: That, params?: T.SecurityHasPrivilegesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1820,7 +1820,7 @@ export default class Security { /** * Check user profile privileges. Determine whether the users associated with the specified user profile IDs have all the requested privileges. NOTE: The user profile feature is designed only for use by Kibana and Elastic's Observability, Enterprise Search, and Elastic Security solutions. Individual users and external applications should not call this API directly. Elastic reserves the right to change or remove this feature in future releases without prior notice. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-has-privileges-user-profile.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-has-privileges-user-profile | Elasticsearch API documentation} */ async hasPrivilegesUserProfile (this: That, params: T.SecurityHasPrivilegesUserProfileRequest, options?: TransportRequestOptionsWithOutMeta): Promise async hasPrivilegesUserProfile (this: That, params: T.SecurityHasPrivilegesUserProfileRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1864,7 +1864,7 @@ export default class Security { /** * Invalidate API keys. This API invalidates API keys created by the create API key or grant API key APIs. Invalidated API keys fail authentication, but they can still be viewed using the get API key information and query API key information APIs, for at least the configured retention period, until they are automatically deleted. To use this API, you must have at least the `manage_security`, `manage_api_key`, or `manage_own_api_key` cluster privileges. The `manage_security` privilege allows deleting any API key, including both REST and cross cluster API keys. The `manage_api_key` privilege allows deleting any REST API key, but not cross cluster API keys. The `manage_own_api_key` only allows deleting REST API keys that are owned by the user. In addition, with the `manage_own_api_key` privilege, an invalidation request must be issued in one of the three formats: - Set the parameter `owner=true`. - Or, set both `username` and `realm_name` to match the user's identity. - Or, if the request is issued by an API key, that is to say an API key invalidates itself, specify its ID in the `ids` field. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-invalidate-api-key.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-invalidate-api-key | Elasticsearch API documentation} */ async invalidateApiKey (this: That, params?: T.SecurityInvalidateApiKeyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async invalidateApiKey (this: That, params?: T.SecurityInvalidateApiKeyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1909,7 +1909,7 @@ export default class Security { /** * Invalidate a token. The access tokens returned by the get token API have a finite period of time for which they are valid. After that time period, they can no longer be used. The time period is defined by the `xpack.security.authc.token.timeout` setting. The refresh tokens returned by the get token API are only valid for 24 hours. They can also be used exactly once. If you want to invalidate one or more access or refresh tokens immediately, use this invalidate token API. NOTE: While all parameters are optional, at least one of them is required. More specifically, either one of `token` or `refresh_token` parameters is required. If none of these two are specified, then `realm_name` and/or `username` need to be specified. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-invalidate-token.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-invalidate-token | Elasticsearch API documentation} */ async invalidateToken (this: That, params?: T.SecurityInvalidateTokenRequest, options?: TransportRequestOptionsWithOutMeta): Promise async invalidateToken (this: That, params?: T.SecurityInvalidateTokenRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1954,7 +1954,7 @@ export default class Security { /** * Authenticate OpenID Connect. Exchange an OpenID Connect authentication response message for an Elasticsearch internal access token and refresh token that can be subsequently used for authentication. Elasticsearch exposes all the necessary OpenID Connect related functionality with the OpenID Connect APIs. These APIs are used internally by Kibana in order to provide OpenID Connect based authentication, but can also be used by other, custom web applications or other clients. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-oidc-authenticate.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-oidc-authenticate | Elasticsearch API documentation} */ async oidcAuthenticate (this: That, params: T.SecurityOidcAuthenticateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async oidcAuthenticate (this: That, params: T.SecurityOidcAuthenticateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -1998,7 +1998,7 @@ export default class Security { /** * Logout of OpenID Connect. Invalidate an access token and a refresh token that were generated as a response to the `/_security/oidc/authenticate` API. If the OpenID Connect authentication realm in Elasticsearch is accordingly configured, the response to this call will contain a URI pointing to the end session endpoint of the OpenID Connect Provider in order to perform single logout. Elasticsearch exposes all the necessary OpenID Connect related functionality with the OpenID Connect APIs. These APIs are used internally by Kibana in order to provide OpenID Connect based authentication, but can also be used by other, custom web applications or other clients. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-oidc-logout.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-oidc-logout | Elasticsearch API documentation} */ async oidcLogout (this: That, params: T.SecurityOidcLogoutRequest, options?: TransportRequestOptionsWithOutMeta): Promise async oidcLogout (this: That, params: T.SecurityOidcLogoutRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2042,7 +2042,7 @@ export default class Security { /** * Prepare OpenID connect authentication. Create an oAuth 2.0 authentication request as a URL string based on the configuration of the OpenID Connect authentication realm in Elasticsearch. The response of this API is a URL pointing to the Authorization Endpoint of the configured OpenID Connect Provider, which can be used to redirect the browser of the user in order to continue the authentication process. Elasticsearch exposes all the necessary OpenID Connect related functionality with the OpenID Connect APIs. These APIs are used internally by Kibana in order to provide OpenID Connect based authentication, but can also be used by other, custom web applications or other clients. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-oidc-prepare-authentication.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-oidc-prepare-authentication | Elasticsearch API documentation} */ async oidcPrepareAuthentication (this: That, params?: T.SecurityOidcPrepareAuthenticationRequest, options?: TransportRequestOptionsWithOutMeta): Promise async oidcPrepareAuthentication (this: That, params?: T.SecurityOidcPrepareAuthenticationRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2087,7 +2087,7 @@ export default class Security { /** * Create or update application privileges. To use this API, you must have one of the following privileges: * The `manage_security` cluster privilege (or a greater privilege such as `all`). * The "Manage Application Privileges" global privilege for the application being referenced in the request. Application names are formed from a prefix, with an optional suffix that conform to the following rules: * The prefix must begin with a lowercase ASCII letter. * The prefix must contain only ASCII letters or digits. * The prefix must be at least 3 characters long. * If the suffix exists, it must begin with either a dash `-` or `_`. * The suffix cannot contain any of the following characters: `\`, `/`, `*`, `?`, `"`, `<`, `>`, `|`, `,`, `*`. * No part of the name can contain whitespace. Privilege names must begin with a lowercase ASCII letter and must contain only ASCII letters and digits along with the characters `_`, `-`, and `.`. Action names can contain any number of printable ASCII characters and must contain at least one of the following characters: `/`, `*`, `:`. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-put-privileges.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-put-privileges | Elasticsearch API documentation} */ async putPrivileges (this: That, params: T.SecurityPutPrivilegesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putPrivileges (this: That, params: T.SecurityPutPrivilegesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2121,7 +2121,7 @@ export default class Security { /** * Create or update roles. The role management APIs are generally the preferred way to manage roles in the native realm, rather than using file-based role management. The create or update roles API cannot update roles that are defined in roles files. File-based role management is not available in Elastic Serverless. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-put-role.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-put-role | Elasticsearch API documentation} */ async putRole (this: That, params: T.SecurityPutRoleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putRole (this: That, params: T.SecurityPutRoleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2168,7 +2168,7 @@ export default class Security { /** * Create or update role mappings. Role mappings define which roles are assigned to each user. Each mapping has rules that identify users and a list of roles that are granted to those users. The role mapping APIs are generally the preferred way to manage role mappings rather than using role mapping files. The create or update role mappings API cannot update role mappings that are defined in role mapping files. NOTE: This API does not create roles. Rather, it maps users to existing roles. Roles can be created by using the create or update roles API or roles files. **Role templates** The most common use for role mappings is to create a mapping from a known value on the user to a fixed role name. For example, all users in the `cn=admin,dc=example,dc=com` LDAP group should be given the superuser role in Elasticsearch. The `roles` field is used for this purpose. For more complex needs, it is possible to use Mustache templates to dynamically determine the names of the roles that should be granted to the user. The `role_templates` field is used for this purpose. NOTE: To use role templates successfully, the relevant scripting feature must be enabled. Otherwise, all attempts to create a role mapping with role templates fail. All of the user fields that are available in the role mapping rules are also available in the role templates. Thus it is possible to assign a user to a role that reflects their username, their groups, or the name of the realm to which they authenticated. By default a template is evaluated to produce a single string that is the name of the role which should be assigned to the user. If the format of the template is set to "json" then the template is expected to produce a JSON string or an array of JSON strings for the role names. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-put-role-mapping.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-put-role-mapping | Elasticsearch API documentation} */ async putRoleMapping (this: That, params: T.SecurityPutRoleMappingRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putRoleMapping (this: That, params: T.SecurityPutRoleMappingRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2215,7 +2215,7 @@ export default class Security { /** * Create or update users. Add and update users in the native realm. A password is required for adding a new user but is optional when updating an existing user. To change a user's password without updating any other fields, use the change password API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-put-user.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-put-user | Elasticsearch API documentation} */ async putUser (this: That, params: T.SecurityPutUserRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putUser (this: That, params: T.SecurityPutUserRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2262,7 +2262,7 @@ export default class Security { /** * Find API keys with a query. Get a paginated list of API keys and their information. You can optionally filter the results with a query. To use this API, you must have at least the `manage_own_api_key` or the `read_security` cluster privileges. If you have only the `manage_own_api_key` privilege, this API returns only the API keys that you own. If you have the `read_security`, `manage_api_key`, or greater privileges (including `manage_security`), this API returns all API keys regardless of ownership. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-query-api-key.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-query-api-keys | Elasticsearch API documentation} */ async queryApiKeys (this: That, params?: T.SecurityQueryApiKeysRequest, options?: TransportRequestOptionsWithOutMeta): Promise async queryApiKeys (this: That, params?: T.SecurityQueryApiKeysRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2307,7 +2307,7 @@ export default class Security { /** * Find roles with a query. Get roles in a paginated manner. The role management APIs are generally the preferred way to manage roles, rather than using file-based role management. The query roles API does not retrieve roles that are defined in roles files, nor built-in ones. You can optionally filter the results with a query. Also, the results can be paginated and sorted. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-query-role.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-query-role | Elasticsearch API documentation} */ async queryRole (this: That, params?: T.SecurityQueryRoleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async queryRole (this: That, params?: T.SecurityQueryRoleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2352,7 +2352,7 @@ export default class Security { /** * Find users with a query. Get information for users in a paginated manner. You can optionally filter the results with a query. NOTE: As opposed to the get user API, built-in users are excluded from the result. This API is only for native users. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-query-user.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-query-user | Elasticsearch API documentation} */ async queryUser (this: That, params?: T.SecurityQueryUserRequest, options?: TransportRequestOptionsWithOutMeta): Promise async queryUser (this: That, params?: T.SecurityQueryUserRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2397,7 +2397,7 @@ export default class Security { /** * Authenticate SAML. Submit a SAML response message to Elasticsearch for consumption. NOTE: This API is intended for use by custom web applications other than Kibana. If you are using Kibana, refer to the documentation for configuring SAML single-sign-on on the Elastic Stack. The SAML message that is submitted can be: * A response to a SAML authentication request that was previously created using the SAML prepare authentication API. * An unsolicited SAML message in the case of an IdP-initiated single sign-on (SSO) flow. In either case, the SAML message needs to be a base64 encoded XML document with a root element of ``. After successful validation, Elasticsearch responds with an Elasticsearch internal access token and refresh token that can be subsequently used for authentication. This API endpoint essentially exchanges SAML responses that indicate successful authentication in the IdP for Elasticsearch access and refresh tokens, which can be used for authentication against Elasticsearch. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-saml-authenticate.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-saml-authenticate | Elasticsearch API documentation} */ async samlAuthenticate (this: That, params: T.SecuritySamlAuthenticateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async samlAuthenticate (this: That, params: T.SecuritySamlAuthenticateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2441,7 +2441,7 @@ export default class Security { /** * Logout of SAML completely. Verifies the logout response sent from the SAML IdP. NOTE: This API is intended for use by custom web applications other than Kibana. If you are using Kibana, refer to the documentation for configuring SAML single-sign-on on the Elastic Stack. The SAML IdP may send a logout response back to the SP after handling the SP-initiated SAML Single Logout. This API verifies the response by ensuring the content is relevant and validating its signature. An empty response is returned if the verification process is successful. The response can be sent by the IdP with either the HTTP-Redirect or the HTTP-Post binding. The caller of this API must prepare the request accordingly so that this API can handle either of them. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-saml-complete-logout.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-saml-complete-logout | Elasticsearch API documentation} */ async samlCompleteLogout (this: That, params: T.SecuritySamlCompleteLogoutRequest, options?: TransportRequestOptionsWithOutMeta): Promise async samlCompleteLogout (this: That, params: T.SecuritySamlCompleteLogoutRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2485,7 +2485,7 @@ export default class Security { /** * Invalidate SAML. Submit a SAML LogoutRequest message to Elasticsearch for consumption. NOTE: This API is intended for use by custom web applications other than Kibana. If you are using Kibana, refer to the documentation for configuring SAML single-sign-on on the Elastic Stack. The logout request comes from the SAML IdP during an IdP initiated Single Logout. The custom web application can use this API to have Elasticsearch process the `LogoutRequest`. After successful validation of the request, Elasticsearch invalidates the access token and refresh token that corresponds to that specific SAML principal and provides a URL that contains a SAML LogoutResponse message. Thus the user can be redirected back to their IdP. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-saml-invalidate.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-saml-invalidate | Elasticsearch API documentation} */ async samlInvalidate (this: That, params: T.SecuritySamlInvalidateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async samlInvalidate (this: That, params: T.SecuritySamlInvalidateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2529,7 +2529,7 @@ export default class Security { /** * Logout of SAML. Submits a request to invalidate an access token and refresh token. NOTE: This API is intended for use by custom web applications other than Kibana. If you are using Kibana, refer to the documentation for configuring SAML single-sign-on on the Elastic Stack. This API invalidates the tokens that were generated for a user by the SAML authenticate API. If the SAML realm in Elasticsearch is configured accordingly and the SAML IdP supports this, the Elasticsearch response contains a URL to redirect the user to the IdP that contains a SAML logout request (starting an SP-initiated SAML Single Logout). - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-saml-logout.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-saml-logout | Elasticsearch API documentation} */ async samlLogout (this: That, params: T.SecuritySamlLogoutRequest, options?: TransportRequestOptionsWithOutMeta): Promise async samlLogout (this: That, params: T.SecuritySamlLogoutRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2573,7 +2573,7 @@ export default class Security { /** * Prepare SAML authentication. Create a SAML authentication request (``) as a URL string based on the configuration of the respective SAML realm in Elasticsearch. NOTE: This API is intended for use by custom web applications other than Kibana. If you are using Kibana, refer to the documentation for configuring SAML single-sign-on on the Elastic Stack. This API returns a URL pointing to the SAML Identity Provider. You can use the URL to redirect the browser of the user in order to continue the authentication process. The URL includes a single parameter named `SAMLRequest`, which contains a SAML Authentication request that is deflated and Base64 encoded. If the configuration dictates that SAML authentication requests should be signed, the URL has two extra parameters named `SigAlg` and `Signature`. These parameters contain the algorithm used for the signature and the signature value itself. It also returns a random string that uniquely identifies this SAML Authentication request. The caller of this API needs to store this identifier as it needs to be used in a following step of the authentication process. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-saml-prepare-authentication.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-saml-prepare-authentication | Elasticsearch API documentation} */ async samlPrepareAuthentication (this: That, params?: T.SecuritySamlPrepareAuthenticationRequest, options?: TransportRequestOptionsWithOutMeta): Promise async samlPrepareAuthentication (this: That, params?: T.SecuritySamlPrepareAuthenticationRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2618,7 +2618,7 @@ export default class Security { /** * Create SAML service provider metadata. Generate SAML metadata for a SAML 2.0 Service Provider. The SAML 2.0 specification provides a mechanism for Service Providers to describe their capabilities and configuration using a metadata file. This API generates Service Provider metadata based on the configuration of a SAML realm in Elasticsearch. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-saml-sp-metadata.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-saml-service-provider-metadata | Elasticsearch API documentation} */ async samlServiceProviderMetadata (this: That, params: T.SecuritySamlServiceProviderMetadataRequest, options?: TransportRequestOptionsWithOutMeta): Promise async samlServiceProviderMetadata (this: That, params: T.SecuritySamlServiceProviderMetadataRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2660,7 +2660,7 @@ export default class Security { /** * Suggest a user profile. Get suggestions for user profiles that match specified search criteria. NOTE: The user profile feature is designed only for use by Kibana and Elastic's Observability, Enterprise Search, and Elastic Security solutions. Individual users and external applications should not call this API directly. Elastic reserves the right to change or remove this feature in future releases without prior notice. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-suggest-user-profile.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-suggest-user-profiles | Elasticsearch API documentation} */ async suggestUserProfiles (this: That, params?: T.SecuritySuggestUserProfilesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async suggestUserProfiles (this: That, params?: T.SecuritySuggestUserProfilesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2705,7 +2705,7 @@ export default class Security { /** * Update an API key. Update attributes of an existing API key. This API supports updates to an API key's access scope, expiration, and metadata. To use this API, you must have at least the `manage_own_api_key` cluster privilege. Users can only update API keys that they created or that were granted to them. To update another user’s API key, use the `run_as` feature to submit a request on behalf of another user. IMPORTANT: It's not possible to use an API key as the authentication credential for this API. The owner user’s credentials are required. Use this API to update API keys created by the create API key or grant API Key APIs. If you need to apply the same update to many API keys, you can use the bulk update API keys API to reduce overhead. It's not possible to update expired API keys or API keys that have been invalidated by the invalidate API key API. The access scope of an API key is derived from the `role_descriptors` you specify in the request and a snapshot of the owner user's permissions at the time of the request. The snapshot of the owner's permissions is updated automatically on every call. IMPORTANT: If you don't specify `role_descriptors` in the request, a call to this API might still change the API key's access scope. This change can occur if the owner user's permissions have changed since the API key was created or last modified. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-update-api-key.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-update-api-key | Elasticsearch API documentation} */ async updateApiKey (this: That, params: T.SecurityUpdateApiKeyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateApiKey (this: That, params: T.SecurityUpdateApiKeyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2752,7 +2752,7 @@ export default class Security { /** * Update a cross-cluster API key. Update the attributes of an existing cross-cluster API key, which is used for API key based remote cluster access. To use this API, you must have at least the `manage_security` cluster privilege. Users can only update API keys that they created. To update another user's API key, use the `run_as` feature to submit a request on behalf of another user. IMPORTANT: It's not possible to use an API key as the authentication credential for this API. To update an API key, the owner user's credentials are required. It's not possible to update expired API keys, or API keys that have been invalidated by the invalidate API key API. This API supports updates to an API key's access scope, metadata, and expiration. The owner user's information, such as the `username` and `realm`, is also updated automatically on every call. NOTE: This API cannot update REST API keys, which should be updated by either the update API key or bulk update API keys API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-update-cross-cluster-api-key.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-update-cross-cluster-api-key | Elasticsearch API documentation} */ async updateCrossClusterApiKey (this: That, params: T.SecurityUpdateCrossClusterApiKeyRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateCrossClusterApiKey (this: That, params: T.SecurityUpdateCrossClusterApiKeyRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2799,7 +2799,7 @@ export default class Security { /** * Update security index settings. Update the user-configurable settings for the security internal index (`.security` and associated indices). Only a subset of settings are allowed to be modified. This includes `index.auto_expand_replicas` and `index.number_of_replicas`. NOTE: If `index.auto_expand_replicas` is set, `index.number_of_replicas` will be ignored during updates. If a specific index is not in use on the system and settings are provided for it, the request will be rejected. This API does not yet support configuring the settings for indices before they are in use. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-update-settings.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-update-settings | Elasticsearch API documentation} */ async updateSettings (this: That, params?: T.SecurityUpdateSettingsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateSettings (this: That, params?: T.SecurityUpdateSettingsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -2844,7 +2844,7 @@ export default class Security { /** * Update user profile data. Update specific data for the user profile that is associated with a unique ID. NOTE: The user profile feature is designed only for use by Kibana and Elastic's Observability, Enterprise Search, and Elastic Security solutions. Individual users and external applications should not call this API directly. Elastic reserves the right to change or remove this feature in future releases without prior notice. To use this API, you must have one of the following privileges: * The `manage_user_profile` cluster privilege. * The `update_profile_data` global privilege for the namespaces that are referenced in the request. This API updates the `labels` and `data` fields of an existing user profile document with JSON objects. New keys and their values are added to the profile document and conflicting keys are replaced by data that's included in the request. For both labels and data, content is namespaced by the top-level fields. The `update_profile_data` global privilege grants privileges for updating only the allowed namespaces. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-update-user-profile-data.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-security-update-user-profile-data | Elasticsearch API documentation} */ async updateUserProfileData (this: That, params: T.SecurityUpdateUserProfileDataRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateUserProfileData (this: That, params: T.SecurityUpdateUserProfileDataRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/shutdown.ts b/src/api/api/shutdown.ts index 61a4ce6cb..ffa3b9c39 100644 --- a/src/api/api/shutdown.ts +++ b/src/api/api/shutdown.ts @@ -45,7 +45,7 @@ export default class Shutdown { /** * Cancel node shutdown preparations. Remove a node from the shutdown list so it can resume normal operations. You must explicitly clear the shutdown request when a node rejoins the cluster or when a node has permanently left the cluster. Shutdown requests are never removed automatically by Elasticsearch. NOTE: This feature is designed for indirect use by Elastic Cloud, Elastic Cloud Enterprise, and Elastic Cloud on Kubernetes. Direct use is not supported. If the operator privileges feature is enabled, you must be an operator to use this API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-shutdown.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-shutdown-delete-node | Elasticsearch API documentation} */ async deleteNode (this: That, params: T.ShutdownDeleteNodeRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteNode (this: That, params: T.ShutdownDeleteNodeRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class Shutdown { /** * Get the shutdown status. Get information about nodes that are ready to be shut down, have shut down preparations still in progress, or have stalled. The API returns status information for each part of the shut down process. NOTE: This feature is designed for indirect use by Elasticsearch Service, Elastic Cloud Enterprise, and Elastic Cloud on Kubernetes. Direct use is not supported. If the operator privileges feature is enabled, you must be an operator to use this API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-shutdown.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-shutdown-get-node | Elasticsearch API documentation} */ async getNode (this: That, params?: T.ShutdownGetNodeRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getNode (this: That, params?: T.ShutdownGetNodeRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -137,7 +137,7 @@ export default class Shutdown { /** * Prepare a node to be shut down. NOTE: This feature is designed for indirect use by Elastic Cloud, Elastic Cloud Enterprise, and Elastic Cloud on Kubernetes. Direct use is not supported. If you specify a node that is offline, it will be prepared for shut down when it rejoins the cluster. If the operator privileges feature is enabled, you must be an operator to use this API. The API migrates ongoing tasks and index shards to other nodes as needed to prepare a node to be restarted or shut down and removed from the cluster. This ensures that Elasticsearch can be stopped safely with minimal disruption to the cluster. You must specify the type of shutdown: `restart`, `remove`, or `replace`. If a node is already being prepared for shutdown, you can use this API to change the shutdown type. IMPORTANT: This API does NOT terminate the Elasticsearch process. Monitor the node shutdown status to determine when it is safe to stop Elasticsearch. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-shutdown.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-shutdown-put-node | Elasticsearch API documentation} */ async putNode (this: That, params: T.ShutdownPutNodeRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putNode (this: That, params: T.ShutdownPutNodeRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/simulate.ts b/src/api/api/simulate.ts index ee6e13de6..ba1689505 100644 --- a/src/api/api/simulate.ts +++ b/src/api/api/simulate.ts @@ -45,7 +45,7 @@ export default class Simulate { /** * Simulate data ingestion. Run ingest pipelines against a set of provided documents, optionally with substitute pipeline definitions, to simulate ingesting data into an index. This API is meant to be used for troubleshooting or pipeline development, as it does not actually index any data into Elasticsearch. The API runs the default and final pipeline for that index against a set of documents provided in the body of the request. If a pipeline contains a reroute processor, it follows that reroute processor to the new index, running that index's pipelines as well the same way that a non-simulated ingest would. No data is indexed into Elasticsearch. Instead, the transformed document is returned, along with the list of pipelines that have been run and the name of the index where the document would have been indexed if this were not a simulation. The transformed document is validated against the mappings that would apply to this index, and any validation error is reported in the result. This API differs from the simulate pipeline API in that you specify a single pipeline for that API, and it runs only that one pipeline. The simulate pipeline API is more useful for developing a single pipeline, while the simulate ingest API is more useful for troubleshooting the interaction of the various pipelines that get applied when ingesting into an index. By default, the pipeline definitions that are currently in the system are used. However, you can supply substitute pipeline definitions in the body of the request. These will be used in place of the pipeline definitions that are already in the system. This can be used to replace existing pipeline definitions or to create new ones. The pipeline substitutions are used only within this request. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/simulate-ingest-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-simulate-ingest | Elasticsearch API documentation} */ async ingest (this: That, params: T.SimulateIngestRequest, options?: TransportRequestOptionsWithOutMeta): Promise async ingest (this: That, params: T.SimulateIngestRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/slm.ts b/src/api/api/slm.ts index 9cb2542aa..9e6a856f9 100644 --- a/src/api/api/slm.ts +++ b/src/api/api/slm.ts @@ -45,7 +45,7 @@ export default class Slm { /** * Delete a policy. Delete a snapshot lifecycle policy definition. This operation prevents any future snapshots from being taken but does not cancel in-progress snapshots or remove previously-taken snapshots. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/slm-api-delete-policy.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-delete-lifecycle | Elasticsearch API documentation} */ async deleteLifecycle (this: That, params: T.SlmDeleteLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteLifecycle (this: That, params: T.SlmDeleteLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class Slm { /** * Run a policy. Immediately create a snapshot according to the snapshot lifecycle policy without waiting for the scheduled time. The snapshot policy is normally applied according to its schedule, but you might want to manually run a policy before performing an upgrade or other maintenance. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/slm-api-execute-lifecycle.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-execute-lifecycle | Elasticsearch API documentation} */ async executeLifecycle (this: That, params: T.SlmExecuteLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async executeLifecycle (this: That, params: T.SlmExecuteLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -129,7 +129,7 @@ export default class Slm { /** * Run a retention policy. Manually apply the retention policy to force immediate removal of snapshots that are expired according to the snapshot lifecycle policy retention rules. The retention policy is normally applied according to its schedule. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/slm-api-execute-retention.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-execute-retention | Elasticsearch API documentation} */ async executeRetention (this: That, params?: T.SlmExecuteRetentionRequest, options?: TransportRequestOptionsWithOutMeta): Promise async executeRetention (this: That, params?: T.SlmExecuteRetentionRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -169,7 +169,7 @@ export default class Slm { /** * Get policy information. Get snapshot lifecycle policy definitions and information about the latest snapshot attempts. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/slm-api-get-policy.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-get-lifecycle | Elasticsearch API documentation} */ async getLifecycle (this: That, params?: T.SlmGetLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getLifecycle (this: That, params?: T.SlmGetLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -219,7 +219,7 @@ export default class Slm { /** * Get snapshot lifecycle management statistics. Get global and policy-level statistics about actions taken by snapshot lifecycle management. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/slm-api-get-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-get-stats | Elasticsearch API documentation} */ async getStats (this: That, params?: T.SlmGetStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getStats (this: That, params?: T.SlmGetStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -259,7 +259,7 @@ export default class Slm { /** * Get the snapshot lifecycle management status. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/slm-api-get-status.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-get-status | Elasticsearch API documentation} */ async getStatus (this: That, params?: T.SlmGetStatusRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getStatus (this: That, params?: T.SlmGetStatusRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -299,7 +299,7 @@ export default class Slm { /** * Create or update a policy. Create or update a snapshot lifecycle policy. If the policy already exists, this request increments the policy version. Only the latest version of a policy is stored. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/slm-api-put-policy.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-put-lifecycle | Elasticsearch API documentation} */ async putLifecycle (this: That, params: T.SlmPutLifecycleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putLifecycle (this: That, params: T.SlmPutLifecycleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -346,7 +346,7 @@ export default class Slm { /** * Start snapshot lifecycle management. Snapshot lifecycle management (SLM) starts automatically when a cluster is formed. Manually starting SLM is necessary only if it has been stopped using the stop SLM API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/slm-api-start.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-start | Elasticsearch API documentation} */ async start (this: That, params?: T.SlmStartRequest, options?: TransportRequestOptionsWithOutMeta): Promise async start (this: That, params?: T.SlmStartRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -386,7 +386,7 @@ export default class Slm { /** * Stop snapshot lifecycle management. Stop all snapshot lifecycle management (SLM) operations and the SLM plugin. This API is useful when you are performing maintenance on a cluster and need to prevent SLM from performing any actions on your data streams or indices. Stopping SLM does not stop any snapshots that are in progress. You can manually trigger snapshots with the run snapshot lifecycle policy API even if SLM is stopped. The API returns a response as soon as the request is acknowledged, but the plugin might continue to run until in-progress operations complete and it can be safely stopped. Use the get snapshot lifecycle management status API to see if SLM is running. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/slm-api-stop.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-slm-stop | Elasticsearch API documentation} */ async stop (this: That, params?: T.SlmStopRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stop (this: That, params?: T.SlmStopRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/snapshot.ts b/src/api/api/snapshot.ts index 762afb7fb..3b37c9bdb 100644 --- a/src/api/api/snapshot.ts +++ b/src/api/api/snapshot.ts @@ -45,7 +45,7 @@ export default class Snapshot { /** * Clean up the snapshot repository. Trigger the review of the contents of a snapshot repository and delete any stale data not referenced by existing snapshots. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/clean-up-snapshot-repo-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-cleanup-repository | Elasticsearch API documentation} */ async cleanupRepository (this: That, params: T.SnapshotCleanupRepositoryRequest, options?: TransportRequestOptionsWithOutMeta): Promise async cleanupRepository (this: That, params: T.SnapshotCleanupRepositoryRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class Snapshot { /** * Clone a snapshot. Clone part of all of a snapshot into another snapshot in the same repository. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/clone-snapshot-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-clone | Elasticsearch API documentation} */ async clone (this: That, params: T.SnapshotCloneRequest, options?: TransportRequestOptionsWithOutMeta): Promise async clone (this: That, params: T.SnapshotCloneRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -136,7 +136,7 @@ export default class Snapshot { /** * Create a snapshot. Take a snapshot of a cluster or of data streams and indices. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/create-snapshot-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-create | Elasticsearch API documentation} */ async create (this: That, params: T.SnapshotCreateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async create (this: That, params: T.SnapshotCreateRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -184,7 +184,7 @@ export default class Snapshot { /** * Create or update a snapshot repository. IMPORTANT: If you are migrating searchable snapshots, the repository name must be identical in the source and destination clusters. To register a snapshot repository, the cluster's global metadata must be writeable. Ensure there are no cluster blocks (for example, `cluster.blocks.read_only` and `clsuter.blocks.read_only_allow_delete` settings) that prevent write access. Several options for this API can be specified using a query parameter or a request body parameter. If both parameters are specified, only the query parameter is used. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-snapshot-repo-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-create-repository | Elasticsearch API documentation} */ async createRepository (this: That, params: T.SnapshotCreateRepositoryRequest, options?: TransportRequestOptionsWithOutMeta): Promise async createRepository (this: That, params: T.SnapshotCreateRepositoryRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -221,7 +221,7 @@ export default class Snapshot { /** * Delete snapshots. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-snapshot-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-delete | Elasticsearch API documentation} */ async delete (this: That, params: T.SnapshotDeleteRequest, options?: TransportRequestOptionsWithOutMeta): Promise async delete (this: That, params: T.SnapshotDeleteRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -264,7 +264,7 @@ export default class Snapshot { /** * Delete snapshot repositories. When a repository is unregistered, Elasticsearch removes only the reference to the location where the repository is storing the snapshots. The snapshots themselves are left untouched and in place. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-snapshot-repo-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-delete-repository | Elasticsearch API documentation} */ async deleteRepository (this: That, params: T.SnapshotDeleteRepositoryRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteRepository (this: That, params: T.SnapshotDeleteRepositoryRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -306,7 +306,7 @@ export default class Snapshot { /** * Get snapshot information. NOTE: The `after` parameter and `next` field enable you to iterate through snapshots with some consistency guarantees regarding concurrent creation or deletion of snapshots. It is guaranteed that any snapshot that exists at the beginning of the iteration and is not concurrently deleted will be seen during the iteration. Snapshots concurrently created may be seen during an iteration. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-snapshot-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-get | Elasticsearch API documentation} */ async get (this: That, params: T.SnapshotGetRequest, options?: TransportRequestOptionsWithOutMeta): Promise async get (this: That, params: T.SnapshotGetRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -349,7 +349,7 @@ export default class Snapshot { /** * Get snapshot repository information. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-snapshot-repo-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-get-repository | Elasticsearch API documentation} */ async getRepository (this: That, params?: T.SnapshotGetRepositoryRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getRepository (this: That, params?: T.SnapshotGetRepositoryRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -399,7 +399,7 @@ export default class Snapshot { /** * Analyze a snapshot repository. Analyze the performance characteristics and any incorrect behaviour found in a repository. The response exposes implementation details of the analysis which may change from version to version. The response body format is therefore not considered stable and may be different in newer versions. There are a large number of third-party storage systems available, not all of which are suitable for use as a snapshot repository by Elasticsearch. Some storage systems behave incorrectly, or perform poorly, especially when accessed concurrently by multiple clients as the nodes of an Elasticsearch cluster do. This API performs a collection of read and write operations on your repository which are designed to detect incorrect behaviour and to measure the performance characteristics of your storage system. The default values for the parameters are deliberately low to reduce the impact of running an analysis inadvertently and to provide a sensible starting point for your investigations. Run your first analysis with the default parameter values to check for simple problems. If successful, run a sequence of increasingly large analyses until you encounter a failure or you reach a `blob_count` of at least `2000`, a `max_blob_size` of at least `2gb`, a `max_total_data_size` of at least `1tb`, and a `register_operation_count` of at least `100`. Always specify a generous timeout, possibly `1h` or longer, to allow time for each analysis to run to completion. Perform the analyses using a multi-node cluster of a similar size to your production cluster so that it can detect any problems that only arise when the repository is accessed by many nodes at once. If the analysis fails, Elasticsearch detected that your repository behaved unexpectedly. This usually means you are using a third-party storage system with an incorrect or incompatible implementation of the API it claims to support. If so, this storage system is not suitable for use as a snapshot repository. You will need to work with the supplier of your storage system to address the incompatibilities that Elasticsearch detects. If the analysis is successful, the API returns details of the testing process, optionally including how long each operation took. You can use this information to determine the performance of your storage system. If any operation fails or returns an incorrect result, the API returns an error. If the API returns an error, it may not have removed all the data it wrote to the repository. The error will indicate the location of any leftover data and this path is also recorded in the Elasticsearch logs. You should verify that this location has been cleaned up correctly. If there is still leftover data at the specified location, you should manually remove it. If the connection from your client to Elasticsearch is closed while the client is waiting for the result of the analysis, the test is cancelled. Some clients are configured to close their connection if no response is received within a certain timeout. An analysis takes a long time to complete so you might need to relax any such client-side timeouts. On cancellation the analysis attempts to clean up the data it was writing, but it may not be able to remove it all. The path to the leftover data is recorded in the Elasticsearch logs. You should verify that this location has been cleaned up correctly. If there is still leftover data at the specified location, you should manually remove it. If the analysis is successful then it detected no incorrect behaviour, but this does not mean that correct behaviour is guaranteed. The analysis attempts to detect common bugs but it does not offer 100% coverage. Additionally, it does not test the following: * Your repository must perform durable writes. Once a blob has been written it must remain in place until it is deleted, even after a power loss or similar disaster. * Your repository must not suffer from silent data corruption. Once a blob has been written, its contents must remain unchanged until it is deliberately modified or deleted. * Your repository must behave correctly even if connectivity from the cluster is disrupted. Reads and writes may fail in this case, but they must not return incorrect results. IMPORTANT: An analysis writes a substantial amount of data to your repository and then reads it back again. This consumes bandwidth on the network between the cluster and the repository, and storage space and I/O bandwidth on the repository itself. You must ensure this load does not affect other users of these systems. Analyses respect the repository settings `max_snapshot_bytes_per_sec` and `max_restore_bytes_per_sec` if available and the cluster setting `indices.recovery.max_bytes_per_sec` which you can use to limit the bandwidth they consume. NOTE: This API is intended for exploratory use by humans. You should expect the request parameters and the response format to vary in future versions. NOTE: Different versions of Elasticsearch may perform different checks for repository compatibility, with newer versions typically being stricter than older ones. A storage system that passes repository analysis with one version of Elasticsearch may fail with a different version. This indicates it behaves incorrectly in ways that the former version did not detect. You must work with the supplier of your storage system to address the incompatibilities detected by the repository analysis API in any version of Elasticsearch. NOTE: This API may not work correctly in a mixed-version cluster. *Implementation details* NOTE: This section of documentation describes how the repository analysis API works in this version of Elasticsearch, but you should expect the implementation to vary between versions. The request parameters and response format depend on details of the implementation so may also be different in newer versions. The analysis comprises a number of blob-level tasks, as set by the `blob_count` parameter and a number of compare-and-exchange operations on linearizable registers, as set by the `register_operation_count` parameter. These tasks are distributed over the data and master-eligible nodes in the cluster for execution. For most blob-level tasks, the executing node first writes a blob to the repository and then instructs some of the other nodes in the cluster to attempt to read the data it just wrote. The size of the blob is chosen randomly, according to the `max_blob_size` and `max_total_data_size` parameters. If any of these reads fails then the repository does not implement the necessary read-after-write semantics that Elasticsearch requires. For some blob-level tasks, the executing node will instruct some of its peers to attempt to read the data before the writing process completes. These reads are permitted to fail, but must not return partial data. If any read returns partial data then the repository does not implement the necessary atomicity semantics that Elasticsearch requires. For some blob-level tasks, the executing node will overwrite the blob while its peers are reading it. In this case the data read may come from either the original or the overwritten blob, but the read operation must not return partial data or a mix of data from the two blobs. If any of these reads returns partial data or a mix of the two blobs then the repository does not implement the necessary atomicity semantics that Elasticsearch requires for overwrites. The executing node will use a variety of different methods to write the blob. For instance, where applicable, it will use both single-part and multi-part uploads. Similarly, the reading nodes will use a variety of different methods to read the data back again. For instance they may read the entire blob from start to end or may read only a subset of the data. For some blob-level tasks, the executing node will cancel the write before it is complete. In this case, it still instructs some of the other nodes in the cluster to attempt to read the blob but all of these reads must fail to find the blob. Linearizable registers are special blobs that Elasticsearch manipulates using an atomic compare-and-exchange operation. This operation ensures correct and strongly-consistent behavior even when the blob is accessed by multiple nodes at the same time. The detailed implementation of the compare-and-exchange operation on linearizable registers varies by repository type. Repository analysis verifies that that uncontended compare-and-exchange operations on a linearizable register blob always succeed. Repository analysis also verifies that contended operations either succeed or report the contention but do not return incorrect results. If an operation fails due to contention, Elasticsearch retries the operation until it succeeds. Most of the compare-and-exchange operations performed by repository analysis atomically increment a counter which is represented as an 8-byte blob. Some operations also verify the behavior on small blobs with sizes other than 8 bytes. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/repo-analysis-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-repository-analyze | Elasticsearch API documentation} */ async repositoryAnalyze (this: That, params: T.SnapshotRepositoryAnalyzeRequest, options?: TransportRequestOptionsWithOutMeta): Promise async repositoryAnalyze (this: That, params: T.SnapshotRepositoryAnalyzeRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -441,7 +441,7 @@ export default class Snapshot { /** * Verify the repository integrity. Verify the integrity of the contents of a snapshot repository. This API enables you to perform a comprehensive check of the contents of a repository, looking for any anomalies in its data or metadata which might prevent you from restoring snapshots from the repository or which might cause future snapshot create or delete operations to fail. If you suspect the integrity of the contents of one of your snapshot repositories, cease all write activity to this repository immediately, set its `read_only` option to `true`, and use this API to verify its integrity. Until you do so: * It may not be possible to restore some snapshots from this repository. * Searchable snapshots may report errors when searched or may have unassigned shards. * Taking snapshots into this repository may fail or may appear to succeed but have created a snapshot which cannot be restored. * Deleting snapshots from this repository may fail or may appear to succeed but leave the underlying data on disk. * Continuing to write to the repository while it is in an invalid state may causing additional damage to its contents. If the API finds any problems with the integrity of the contents of your repository, Elasticsearch will not be able to repair the damage. The only way to bring the repository back into a fully working state after its contents have been damaged is by restoring its contents from a repository backup which was taken before the damage occurred. You must also identify what caused the damage and take action to prevent it from happening again. If you cannot restore a repository backup, register a new repository and use this for all future snapshot operations. In some cases it may be possible to recover some of the contents of a damaged repository, either by restoring as many of its snapshots as needed and taking new snapshots of the restored data, or by using the reindex API to copy data from any searchable snapshots mounted from the damaged repository. Avoid all operations which write to the repository while the verify repository integrity API is running. If something changes the repository contents while an integrity verification is running then Elasticsearch may incorrectly report having detected some anomalies in its contents due to the concurrent writes. It may also incorrectly fail to report some anomalies that the concurrent writes prevented it from detecting. NOTE: This API is intended for exploratory use by humans. You should expect the request parameters and the response format to vary in future versions. NOTE: This API may not work correctly in a mixed-version cluster. The default values for the parameters of this API are designed to limit the impact of the integrity verification on other activities in your cluster. For instance, by default it will only use at most half of the `snapshot_meta` threads to verify the integrity of each snapshot, allowing other snapshot operations to use the other half of this thread pool. If you modify these parameters to speed up the verification process, you risk disrupting other snapshot-related operations in your cluster. For large repositories, consider setting up a separate single-node Elasticsearch cluster just for running the integrity verification API. The response exposes implementation details of the analysis which may change from version to version. The response body format is therefore not considered stable and may be different in newer versions. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/verify-repo-integrity-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-repository-verify-integrity | Elasticsearch API documentation} */ async repositoryVerifyIntegrity (this: That, params: T.SnapshotRepositoryVerifyIntegrityRequest, options?: TransportRequestOptionsWithOutMeta): Promise async repositoryVerifyIntegrity (this: That, params: T.SnapshotRepositoryVerifyIntegrityRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -483,7 +483,7 @@ export default class Snapshot { /** * Restore a snapshot. Restore a snapshot of a cluster or data streams and indices. You can restore a snapshot only to a running cluster with an elected master node. The snapshot repository must be registered and available to the cluster. The snapshot and cluster versions must be compatible. To restore a snapshot, the cluster's global metadata must be writable. Ensure there are't any cluster blocks that prevent writes. The restore operation ignores index blocks. Before you restore a data stream, ensure the cluster contains a matching index template with data streams enabled. To check, use the index management feature in Kibana or the get index template API: ``` GET _index_template/*?filter_path=index_templates.name,index_templates.index_template.index_patterns,index_templates.index_template.data_stream ``` If no such template exists, you can create one or restore a cluster state that contains one. Without a matching index template, a data stream can't roll over or create backing indices. If your snapshot contains data from App Search or Workplace Search, you must restore the Enterprise Search encryption key before you restore the snapshot. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/restore-snapshot-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-restore | Elasticsearch API documentation} */ async restore (this: That, params: T.SnapshotRestoreRequest, options?: TransportRequestOptionsWithOutMeta): Promise async restore (this: That, params: T.SnapshotRestoreRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -531,7 +531,7 @@ export default class Snapshot { /** * Get the snapshot status. Get a detailed description of the current state for each shard participating in the snapshot. Note that this API should be used only to obtain detailed shard-level information for ongoing snapshots. If this detail is not needed or you want to obtain information about one or more existing snapshots, use the get snapshot API. If you omit the `` request path parameter, the request retrieves information only for currently running snapshots. This usage is preferred. If needed, you can specify `` and `` to retrieve information for specific snapshots, even if they're not currently running. WARNING: Using the API to return the status of any snapshots other than currently running snapshots can be expensive. The API requires a read from the repository for each shard in each snapshot. For example, if you have 100 snapshots with 1,000 shards each, an API request that includes all snapshots will require 100,000 reads (100 snapshots x 1,000 shards). Depending on the latency of your storage, such requests can take an extremely long time to return results. These requests can also tax machine resources and, when using cloud storage, incur high processing costs. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-snapshot-status-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-status | Elasticsearch API documentation} */ async status (this: That, params?: T.SnapshotStatusRequest, options?: TransportRequestOptionsWithOutMeta): Promise async status (this: That, params?: T.SnapshotStatusRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -585,7 +585,7 @@ export default class Snapshot { /** * Verify a snapshot repository. Check for common misconfigurations in a snapshot repository. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/verify-snapshot-repo-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-snapshot-verify-repository | Elasticsearch API documentation} */ async verifyRepository (this: That, params: T.SnapshotVerifyRepositoryRequest, options?: TransportRequestOptionsWithOutMeta): Promise async verifyRepository (this: That, params: T.SnapshotVerifyRepositoryRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/sql.ts b/src/api/api/sql.ts index df4bac5d9..871cb7139 100644 --- a/src/api/api/sql.ts +++ b/src/api/api/sql.ts @@ -45,7 +45,7 @@ export default class Sql { /** * Clear an SQL search cursor. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/clear-sql-cursor-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-sql-clear-cursor | Elasticsearch API documentation} */ async clearCursor (this: That, params: T.SqlClearCursorRequest, options?: TransportRequestOptionsWithOutMeta): Promise async clearCursor (this: That, params: T.SqlClearCursorRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -89,7 +89,7 @@ export default class Sql { /** * Delete an async SQL search. Delete an async SQL search or a stored synchronous SQL search. If the search is still running, the API cancels it. If the Elasticsearch security features are enabled, only the following users can use this API to delete a search: * Users with the `cancel_task` cluster privilege. * The user who first submitted the search. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-async-sql-search-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-sql-delete-async | Elasticsearch API documentation} */ async deleteAsync (this: That, params: T.SqlDeleteAsyncRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteAsync (this: That, params: T.SqlDeleteAsyncRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -131,7 +131,7 @@ export default class Sql { /** * Get async SQL search results. Get the current status and available results for an async SQL search or stored synchronous SQL search. If the Elasticsearch security features are enabled, only the user who first submitted the SQL search can retrieve the search using this API. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-async-sql-search-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-sql-get-async | Elasticsearch API documentation} */ async getAsync (this: That, params: T.SqlGetAsyncRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getAsync (this: That, params: T.SqlGetAsyncRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -173,7 +173,7 @@ export default class Sql { /** * Get the async SQL search status. Get the current status of an async SQL search or a stored synchronous SQL search. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-async-sql-search-status-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-sql-get-async-status | Elasticsearch API documentation} */ async getAsyncStatus (this: That, params: T.SqlGetAsyncStatusRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getAsyncStatus (this: That, params: T.SqlGetAsyncStatusRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -215,7 +215,7 @@ export default class Sql { /** * Get SQL search results. Run an SQL request. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/sql-search-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-sql-query | Elasticsearch API documentation} */ async query (this: That, params?: T.SqlQueryRequest, options?: TransportRequestOptionsWithOutMeta): Promise async query (this: That, params?: T.SqlQueryRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -260,7 +260,7 @@ export default class Sql { /** * Translate SQL into Elasticsearch queries. Translate an SQL search into a search API request containing Query DSL. It accepts the same request body parameters as the SQL search API, excluding `cursor`. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/sql-translate-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-sql-translate | Elasticsearch API documentation} */ async translate (this: That, params: T.SqlTranslateRequest, options?: TransportRequestOptionsWithOutMeta): Promise async translate (this: That, params: T.SqlTranslateRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/ssl.ts b/src/api/api/ssl.ts index 9f4b81c50..29f25f090 100644 --- a/src/api/api/ssl.ts +++ b/src/api/api/ssl.ts @@ -45,7 +45,7 @@ export default class Ssl { /** * Get SSL certificates. Get information about the X.509 certificates that are used to encrypt communications in the cluster. The API returns a list that includes certificates from all TLS contexts including: - Settings for transport and HTTP interfaces - TLS settings that are used within authentication realms - TLS settings for remote monitoring exporters The list includes certificates that are used for configuring trust, such as those configured in the `xpack.security.transport.ssl.truststore` and `xpack.security.transport.ssl.certificate_authorities` settings. It also includes certificates that are used for configuring server identity, such as `xpack.security.http.ssl.keystore` and `xpack.security.http.ssl.certificate settings`. The list does not include certificates that are sourced from the default SSL context of the Java Runtime Environment (JRE), even if those certificates are in use within Elasticsearch. NOTE: When a PKCS#11 token is configured as the truststore of the JRE, the API returns all the certificates that are included in the PKCS#11 token irrespective of whether these are used in the Elasticsearch TLS configuration. If Elasticsearch is configured to use a keystore or truststore, the API output includes all certificates in that store, even though some of the certificates might not be in active use within the cluster. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/security-api-ssl.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ssl-certificates | Elasticsearch API documentation} */ async certificates (this: That, params?: T.SslCertificatesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async certificates (this: That, params?: T.SslCertificatesRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/synonyms.ts b/src/api/api/synonyms.ts index 9f52fcff5..379510816 100644 --- a/src/api/api/synonyms.ts +++ b/src/api/api/synonyms.ts @@ -45,7 +45,7 @@ export default class Synonyms { /** * Delete a synonym set. You can only delete a synonyms set that is not in use by any index analyzer. Synonyms sets can be used in synonym graph token filters and synonym token filters. These synonym filters can be used as part of search analyzers. Analyzers need to be loaded when an index is restored (such as when a node starts, or the index becomes open). Even if the analyzer is not used on any field mapping, it still needs to be loaded on the index recovery phase. If any analyzers cannot be loaded, the index becomes unavailable and the cluster status becomes red or yellow as index shards are not available. To prevent that, synonyms sets that are used in analyzers can't be deleted. A delete request in this case will return a 400 response code. To remove a synonyms set, you must first remove all indices that contain analyzers using it. You can migrate an index by creating a new index that does not contain the token filter with the synonyms set, and use the reindex API in order to copy over the index data. Once finished, you can delete the index. When the synonyms set is not used in analyzers, you will be able to delete it. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-synonyms-set.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-delete-synonym | Elasticsearch API documentation} */ async deleteSynonym (this: That, params: T.SynonymsDeleteSynonymRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteSynonym (this: That, params: T.SynonymsDeleteSynonymRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -87,7 +87,7 @@ export default class Synonyms { /** * Delete a synonym rule. Delete a synonym rule from a synonym set. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-synonym-rule.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-delete-synonym-rule | Elasticsearch API documentation} */ async deleteSynonymRule (this: That, params: T.SynonymsDeleteSynonymRuleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteSynonymRule (this: That, params: T.SynonymsDeleteSynonymRuleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -130,7 +130,7 @@ export default class Synonyms { /** * Get a synonym set. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-synonyms-set.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-get-synonym | Elasticsearch API documentation} */ async getSynonym (this: That, params: T.SynonymsGetSynonymRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getSynonym (this: That, params: T.SynonymsGetSynonymRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -172,7 +172,7 @@ export default class Synonyms { /** * Get a synonym rule. Get a synonym rule from a synonym set. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-synonym-rule.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-get-synonym-rule | Elasticsearch API documentation} */ async getSynonymRule (this: That, params: T.SynonymsGetSynonymRuleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getSynonymRule (this: That, params: T.SynonymsGetSynonymRuleRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -215,7 +215,7 @@ export default class Synonyms { /** * Get all synonym sets. Get a summary of all defined synonym sets. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-synonyms-set.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-get-synonym | Elasticsearch API documentation} */ async getSynonymsSets (this: That, params?: T.SynonymsGetSynonymsSetsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getSynonymsSets (this: That, params?: T.SynonymsGetSynonymsSetsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -255,7 +255,7 @@ export default class Synonyms { /** * Create or update a synonym set. Synonyms sets are limited to a maximum of 10,000 synonym rules per set. If you need to manage more synonym rules, you can create multiple synonym sets. When an existing synonyms set is updated, the search analyzers that use the synonyms set are reloaded automatically for all indices. This is equivalent to invoking the reload search analyzers API for all indices that use the synonyms set. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-synonyms-set.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-put-synonym | Elasticsearch API documentation} */ async putSynonym (this: That, params: T.SynonymsPutSynonymRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putSynonym (this: That, params: T.SynonymsPutSynonymRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -302,7 +302,7 @@ export default class Synonyms { /** * Create or update a synonym rule. Create or update a synonym rule in a synonym set. If any of the synonym rules included is invalid, the API returns an error. When you update a synonym rule, all analyzers using the synonyms set will be reloaded automatically to reflect the new rule. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-synonym-rule.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-put-synonym-rule | Elasticsearch API documentation} */ async putSynonymRule (this: That, params: T.SynonymsPutSynonymRuleRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putSynonymRule (this: That, params: T.SynonymsPutSynonymRuleRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/tasks.ts b/src/api/api/tasks.ts index a906a58fd..a8f7ccf20 100644 --- a/src/api/api/tasks.ts +++ b/src/api/api/tasks.ts @@ -45,7 +45,7 @@ export default class Tasks { /** * Cancel a task. WARNING: The task management API is new and should still be considered a beta feature. The API may change in ways that are not backwards compatible. A task may continue to run for some time after it has been cancelled because it may not be able to safely stop its current activity straight away. It is also possible that Elasticsearch must complete its work on other tasks before it can process the cancellation. The get task information API will continue to list these cancelled tasks until they complete. The cancelled flag in the response indicates that the cancellation command has been processed and the task will stop as soon as possible. To troubleshoot why a cancelled task does not complete promptly, use the get task information API with the `?detailed` parameter to identify the other tasks the system is running. You can also use the node hot threads API to obtain detailed information about the work the system is doing instead of completing the cancelled task. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/tasks.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-tasks | Elasticsearch API documentation} */ async cancel (this: That, params?: T.TasksCancelRequest, options?: TransportRequestOptionsWithOutMeta): Promise async cancel (this: That, params?: T.TasksCancelRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -95,7 +95,7 @@ export default class Tasks { /** * Get task information. Get information about a task currently running in the cluster. WARNING: The task management API is new and should still be considered a beta feature. The API may change in ways that are not backwards compatible. If the task identifier is not found, a 404 response code indicates that there are no resources that match the request. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/tasks.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-tasks | Elasticsearch API documentation} */ async get (this: That, params: T.TasksGetRequest, options?: TransportRequestOptionsWithOutMeta): Promise async get (this: That, params: T.TasksGetRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -137,7 +137,7 @@ export default class Tasks { /** * Get all tasks. Get information about the tasks currently running on one or more nodes in the cluster. WARNING: The task management API is new and should still be considered a beta feature. The API may change in ways that are not backwards compatible. **Identifying running tasks** The `X-Opaque-Id header`, when provided on the HTTP request header, is going to be returned as a header in the response as well as in the headers field for in the task information. This enables you to track certain calls or associate certain tasks with the client that started them. For example: ``` curl -i -H "X-Opaque-Id: 123456" "http://localhost:9200/_tasks?group_by=parents" ``` The API returns the following result: ``` HTTP/1.1 200 OK X-Opaque-Id: 123456 content-type: application/json; charset=UTF-8 content-length: 831 { "tasks" : { "u5lcZHqcQhu-rUoFaqDphA:45" : { "node" : "u5lcZHqcQhu-rUoFaqDphA", "id" : 45, "type" : "transport", "action" : "cluster:monitor/tasks/lists", "start_time_in_millis" : 1513823752749, "running_time_in_nanos" : 293139, "cancellable" : false, "headers" : { "X-Opaque-Id" : "123456" }, "children" : [ { "node" : "u5lcZHqcQhu-rUoFaqDphA", "id" : 46, "type" : "direct", "action" : "cluster:monitor/tasks/lists[n]", "start_time_in_millis" : 1513823752750, "running_time_in_nanos" : 92133, "cancellable" : false, "parent_task_id" : "u5lcZHqcQhu-rUoFaqDphA:45", "headers" : { "X-Opaque-Id" : "123456" } } ] } } } ``` In this example, `X-Opaque-Id: 123456` is the ID as a part of the response header. The `X-Opaque-Id` in the task `headers` is the ID for the task that was initiated by the REST request. The `X-Opaque-Id` in the children `headers` is the child task of the task that was initiated by the REST request. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/tasks.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-tasks | Elasticsearch API documentation} */ async list (this: That, params?: T.TasksListRequest, options?: TransportRequestOptionsWithOutMeta): Promise async list (this: That, params?: T.TasksListRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/terms_enum.ts b/src/api/api/terms_enum.ts index af8c1d1e4..ad9fa1e0e 100644 --- a/src/api/api/terms_enum.ts +++ b/src/api/api/terms_enum.ts @@ -38,8 +38,8 @@ import * as T from '../types' interface That { transport: Transport } /** - * Get terms in an index. Discover terms that match a partial string in an index. This "terms enum" API is designed for low-latency look-ups used in auto-complete scenarios. If the `complete` property in the response is false, the returned terms set may be incomplete and should be treated as approximate. This can occur due to a few reasons, such as a request timeout or a node error. NOTE: The terms enum API may return terms from deleted documents. Deleted documents are initially only marked as deleted. It is not until their segments are merged that documents are actually deleted. Until that happens, the terms enum API will return terms from these documents. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/search-terms-enum.html | Elasticsearch API documentation} + * Get terms in an index. Discover terms that match a partial string in an index. This API is designed for low-latency look-ups used in auto-complete scenarios. > info > The terms enum API may return terms from deleted documents. Deleted documents are initially only marked as deleted. It is not until their segments are merged that documents are actually deleted. Until that happens, the terms enum API will return terms from these documents. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-terms-enum | Elasticsearch API documentation} */ export default async function TermsEnumApi (this: That, params: T.TermsEnumRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function TermsEnumApi (this: That, params: T.TermsEnumRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/termvectors.ts b/src/api/api/termvectors.ts index a4333ccc0..c3f461487 100644 --- a/src/api/api/termvectors.ts +++ b/src/api/api/termvectors.ts @@ -38,8 +38,8 @@ import * as T from '../types' interface That { transport: Transport } /** - * Get term vector information. Get information and statistics about terms in the fields of a particular document. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-termvectors.html | Elasticsearch API documentation} + * Get term vector information. Get information and statistics about terms in the fields of a particular document. You can retrieve term vectors for documents stored in the index or for artificial documents passed in the body of the request. You can specify the fields you are interested in through the `fields` parameter or by adding the fields to the request body. For example: ``` GET /my-index-000001/_termvectors/1?fields=message ``` Fields can be specified using wildcards, similar to the multi match query. Term vectors are real-time by default, not near real-time. This can be changed by setting `realtime` parameter to `false`. You can request three types of values: _term information_, _term statistics_, and _field statistics_. By default, all term information and field statistics are returned for all fields but term statistics are excluded. **Term information** * term frequency in the field (always returned) * term positions (`positions: true`) * start and end offsets (`offsets: true`) * term payloads (`payloads: true`), as base64 encoded bytes If the requested information wasn't stored in the index, it will be computed on the fly if possible. Additionally, term vectors could be computed for documents not even existing in the index, but instead provided by the user. > warn > Start and end offsets assume UTF-16 encoding is being used. If you want to use these offsets in order to get the original text that produced this token, you should make sure that the string you are taking a sub-string of is also encoded using UTF-16. **Behaviour** The term and field statistics are not accurate. Deleted documents are not taken into account. The information is only retrieved for the shard the requested document resides in. The term and field statistics are therefore only useful as relative measures whereas the absolute numbers have no meaning in this context. By default, when requesting term vectors of artificial documents, a shard to get the statistics from is randomly selected. Use `routing` only to hit a particular shard. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-termvectors | Elasticsearch API documentation} */ export default async function TermvectorsApi (this: That, params: T.TermvectorsRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function TermvectorsApi (this: That, params: T.TermvectorsRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/text_structure.ts b/src/api/api/text_structure.ts index 86efca83c..fd245e577 100644 --- a/src/api/api/text_structure.ts +++ b/src/api/api/text_structure.ts @@ -45,7 +45,7 @@ export default class TextStructure { /** * Find the structure of a text field. Find the structure of a text field in an Elasticsearch index. This API provides a starting point for extracting further information from log messages already ingested into Elasticsearch. For example, if you have ingested data into a very simple index that has just `@timestamp` and message fields, you can use this API to see what common structure exists in the message field. The response from the API contains: * Sample messages. * Statistics that reveal the most common values for all fields detected within the text and basic numeric statistics for numeric fields. * Information about the structure of the text, which is useful when you write ingest configurations to index it or similarly formatted text. * Appropriate mappings for an Elasticsearch index, which you could use to ingest the text. All this information can be calculated by the structure finder with no guidance. However, you can optionally override some of the decisions about the text structure by specifying one or more query parameters. If the structure finder produces unexpected results, specify the `explain` query parameter and an explanation will appear in the response. It helps determine why the returned structure was chosen. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/find-field-structure.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-text_structure | Elasticsearch API documentation} */ async findFieldStructure (this: That, params: T.TextStructureFindFieldStructureRequest, options?: TransportRequestOptionsWithOutMeta): Promise async findFieldStructure (this: That, params: T.TextStructureFindFieldStructureRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -84,7 +84,7 @@ export default class TextStructure { /** * Find the structure of text messages. Find the structure of a list of text messages. The messages must contain data that is suitable to be ingested into Elasticsearch. This API provides a starting point for ingesting data into Elasticsearch in a format that is suitable for subsequent use with other Elastic Stack functionality. Use this API rather than the find text structure API if your input text has already been split up into separate messages by some other process. The response from the API contains: * Sample messages. * Statistics that reveal the most common values for all fields detected within the text and basic numeric statistics for numeric fields. * Information about the structure of the text, which is useful when you write ingest configurations to index it or similarly formatted text. Appropriate mappings for an Elasticsearch index, which you could use to ingest the text. All this information can be calculated by the structure finder with no guidance. However, you can optionally override some of the decisions about the text structure by specifying one or more query parameters. If the structure finder produces unexpected results, specify the `explain` query parameter and an explanation will appear in the response. It helps determine why the returned structure was chosen. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/find-message-structure.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-text-structure-find-message-structure | Elasticsearch API documentation} */ async findMessageStructure (this: That, params: T.TextStructureFindMessageStructureRequest, options?: TransportRequestOptionsWithOutMeta): Promise async findMessageStructure (this: That, params: T.TextStructureFindMessageStructureRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -128,7 +128,7 @@ export default class TextStructure { /** * Find the structure of a text file. The text file must contain data that is suitable to be ingested into Elasticsearch. This API provides a starting point for ingesting data into Elasticsearch in a format that is suitable for subsequent use with other Elastic Stack functionality. Unlike other Elasticsearch endpoints, the data that is posted to this endpoint does not need to be UTF-8 encoded and in JSON format. It must, however, be text; binary text formats are not currently supported. The size is limited to the Elasticsearch HTTP receive buffer size, which defaults to 100 Mb. The response from the API contains: * A couple of messages from the beginning of the text. * Statistics that reveal the most common values for all fields detected within the text and basic numeric statistics for numeric fields. * Information about the structure of the text, which is useful when you write ingest configurations to index it or similarly formatted text. * Appropriate mappings for an Elasticsearch index, which you could use to ingest the text. All this information can be calculated by the structure finder with no guidance. However, you can optionally override some of the decisions about the text structure by specifying one or more query parameters. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/find-structure.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-text-structure-find-structure | Elasticsearch API documentation} */ async findStructure (this: That, params: T.TextStructureFindStructureRequest, options?: TransportRequestOptionsWithOutMeta): Promise async findStructure (this: That, params: T.TextStructureFindStructureRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -162,7 +162,7 @@ export default class TextStructure { /** * Test a Grok pattern. Test a Grok pattern on one or more lines of text. The API indicates whether the lines match the pattern together with the offsets and lengths of the matched substrings. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/test-grok-pattern.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-text-structure-test-grok-pattern | Elasticsearch API documentation} */ async testGrokPattern (this: That, params: T.TextStructureTestGrokPatternRequest, options?: TransportRequestOptionsWithOutMeta): Promise async testGrokPattern (this: That, params: T.TextStructureTestGrokPatternRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/transform.ts b/src/api/api/transform.ts index b826dfffd..4872de3e1 100644 --- a/src/api/api/transform.ts +++ b/src/api/api/transform.ts @@ -44,8 +44,8 @@ export default class Transform { } /** - * Delete a transform. Deletes a transform. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-transform.html | Elasticsearch API documentation} + * Delete a transform. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-delete-transform | Elasticsearch API documentation} */ async deleteTransform (this: That, params: T.TransformDeleteTransformRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteTransform (this: That, params: T.TransformDeleteTransformRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -125,8 +125,8 @@ export default class Transform { } /** - * Get transforms. Retrieves configuration information for transforms. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-transform.html | Elasticsearch API documentation} + * Get transforms. Get configuration information for transforms. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-get-transform | Elasticsearch API documentation} */ async getTransform (this: That, params?: T.TransformGetTransformRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getTransform (this: That, params?: T.TransformGetTransformRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -175,8 +175,8 @@ export default class Transform { } /** - * Get transform stats. Retrieves usage information for transforms. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/get-transform-stats.html | Elasticsearch API documentation} + * Get transform stats. Get usage information for transforms. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-get-transform-stats | Elasticsearch API documentation} */ async getTransformStats (this: That, params: T.TransformGetTransformStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getTransformStats (this: That, params: T.TransformGetTransformStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -218,7 +218,7 @@ export default class Transform { /** * Preview a transform. Generates a preview of the results that you will get when you create a transform with the same configuration. It returns a maximum of 100 results. The calculations are based on all the current data in the source index. It also generates a list of mappings and settings for the destination index. These values are determined based on the field types of the source index and the transform aggregations. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/preview-transform.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-preview-transform | Elasticsearch API documentation} */ async previewTransform (this: That, params?: T.TransformPreviewTransformRequest, options?: TransportRequestOptionsWithOutMeta): Promise> async previewTransform (this: That, params?: T.TransformPreviewTransformRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> @@ -273,7 +273,7 @@ export default class Transform { /** * Create a transform. Creates a transform. A transform copies data from source indices, transforms it, and persists it into an entity-centric destination index. You can also think of the destination index as a two-dimensional tabular data structure (known as a data frame). The ID for each document in the data frame is generated from a hash of the entity, so there is a unique row per entity. You must choose either the latest or pivot method for your transform; you cannot use both in a single transform. If you choose to use the pivot method for your transform, the entities are defined by the set of `group_by` fields in the pivot object. If you choose to use the latest method, the entities are defined by the `unique_key` field values in the latest object. You must have `create_index`, `index`, and `read` privileges on the destination index and `read` and `view_index_metadata` privileges on the source indices. When Elasticsearch security features are enabled, the transform remembers which roles the user that created it had at the time of creation and uses those same roles. If those roles do not have the required privileges on the source and destination indices, the transform fails when it attempts unauthorized operations. NOTE: You must use Kibana or this API to create a transform. Do not add a transform directly into any `.transform-internal*` indices using the Elasticsearch index API. If Elasticsearch security features are enabled, do not give users any privileges on `.transform-internal*` indices. If you used transforms prior to 7.5, also do not give users any privileges on `.data-frame-internal*` indices. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/put-transform.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-put-transform | Elasticsearch API documentation} */ async putTransform (this: That, params: T.TransformPutTransformRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putTransform (this: That, params: T.TransformPutTransformRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -319,8 +319,8 @@ export default class Transform { } /** - * Reset a transform. Resets a transform. Before you can reset it, you must stop it; alternatively, use the `force` query parameter. If the destination index was created by the transform, it is deleted. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/reset-transform.html | Elasticsearch API documentation} + * Reset a transform. Before you can reset it, you must stop it; alternatively, use the `force` query parameter. If the destination index was created by the transform, it is deleted. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-reset-transform | Elasticsearch API documentation} */ async resetTransform (this: That, params: T.TransformResetTransformRequest, options?: TransportRequestOptionsWithOutMeta): Promise async resetTransform (this: That, params: T.TransformResetTransformRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -361,8 +361,8 @@ export default class Transform { } /** - * Schedule a transform to start now. Instantly runs a transform to process data. If you _schedule_now a transform, it will process the new data instantly, without waiting for the configured frequency interval. After _schedule_now API is called, the transform will be processed again at now + frequency unless _schedule_now API is called again in the meantime. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/schedule-now-transform.html | Elasticsearch API documentation} + * Schedule a transform to start now. Instantly run a transform to process data. If you run this API, the transform will process the new data instantly, without waiting for the configured frequency interval. After the API is called, the transform will be processed again at `now + frequency` unless the API is called again in the meantime. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-schedule-now-transform | Elasticsearch API documentation} */ async scheduleNowTransform (this: That, params: T.TransformScheduleNowTransformRequest, options?: TransportRequestOptionsWithOutMeta): Promise async scheduleNowTransform (this: That, params: T.TransformScheduleNowTransformRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -403,8 +403,8 @@ export default class Transform { } /** - * Start a transform. Starts a transform. When you start a transform, it creates the destination index if it does not already exist. The `number_of_shards` is set to `1` and the `auto_expand_replicas` is set to `0-1`. If it is a pivot transform, it deduces the mapping definitions for the destination index from the source indices and the transform aggregations. If fields in the destination index are derived from scripts (as in the case of `scripted_metric` or `bucket_script` aggregations), the transform uses dynamic mappings unless an index template exists. If it is a latest transform, it does not deduce mapping definitions; it uses dynamic mappings. To use explicit mappings, create the destination index before you start the transform. Alternatively, you can create an index template, though it does not affect the deduced mappings in a pivot transform. When the transform starts, a series of validations occur to ensure its success. If you deferred validation when you created the transform, they occur when you start the transform—with the exception of privilege checks. When Elasticsearch security features are enabled, the transform remembers which roles the user that created it had at the time of creation and uses those same roles. If those roles do not have the required privileges on the source and destination indices, the transform fails when it attempts unauthorized operations. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/start-transform.html | Elasticsearch API documentation} + * Start a transform. When you start a transform, it creates the destination index if it does not already exist. The `number_of_shards` is set to `1` and the `auto_expand_replicas` is set to `0-1`. If it is a pivot transform, it deduces the mapping definitions for the destination index from the source indices and the transform aggregations. If fields in the destination index are derived from scripts (as in the case of `scripted_metric` or `bucket_script` aggregations), the transform uses dynamic mappings unless an index template exists. If it is a latest transform, it does not deduce mapping definitions; it uses dynamic mappings. To use explicit mappings, create the destination index before you start the transform. Alternatively, you can create an index template, though it does not affect the deduced mappings in a pivot transform. When the transform starts, a series of validations occur to ensure its success. If you deferred validation when you created the transform, they occur when you start the transform—with the exception of privilege checks. When Elasticsearch security features are enabled, the transform remembers which roles the user that created it had at the time of creation and uses those same roles. If those roles do not have the required privileges on the source and destination indices, the transform fails when it attempts unauthorized operations. + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-start-transform | Elasticsearch API documentation} */ async startTransform (this: That, params: T.TransformStartTransformRequest, options?: TransportRequestOptionsWithOutMeta): Promise async startTransform (this: That, params: T.TransformStartTransformRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -446,7 +446,7 @@ export default class Transform { /** * Stop transforms. Stops one or more transforms. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/stop-transform.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-stop-transform | Elasticsearch API documentation} */ async stopTransform (this: That, params: T.TransformStopTransformRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stopTransform (this: That, params: T.TransformStopTransformRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -488,7 +488,7 @@ export default class Transform { /** * Update a transform. Updates certain properties of a transform. All updated properties except `description` do not take effect until after the transform starts the next checkpoint, thus there is data consistency in each checkpoint. To use this API, you must have `read` and `view_index_metadata` privileges for the source indices. You must also have `index` and `read` privileges for the destination index. When Elasticsearch security features are enabled, the transform remembers which roles the user who updated it had at the time of update and runs with those privileges. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/update-transform.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-update-transform | Elasticsearch API documentation} */ async updateTransform (this: That, params: T.TransformUpdateTransformRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateTransform (this: That, params: T.TransformUpdateTransformRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -535,7 +535,7 @@ export default class Transform { /** * Upgrade all transforms. Transforms are compatible across minor versions and between supported major versions. However, over time, the format of transform configuration information may change. This API identifies transforms that have a legacy configuration format and upgrades them to the latest version. It also cleans up the internal data structures that store the transform state and checkpoints. The upgrade does not affect the source and destination indices. The upgrade also does not affect the roles that transforms use when Elasticsearch security features are enabled; the role used to read source data and write to the destination index remains unchanged. If a transform upgrade step fails, the upgrade stops and an error is returned about the underlying issue. Resolve the issue then re-run the process again. A summary is returned when the upgrade is finished. To ensure continuous transforms remain running during a major version upgrade of the cluster – for example, from 7.16 to 8.0 – it is recommended to upgrade transforms before upgrading the cluster. You may want to perform a recent cluster backup prior to the upgrade. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/upgrade-transforms.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-upgrade-transforms | Elasticsearch API documentation} */ async upgradeTransforms (this: That, params?: T.TransformUpgradeTransformsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async upgradeTransforms (this: That, params?: T.TransformUpgradeTransformsRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/update.ts b/src/api/api/update.ts index d4dc6f183..06d06ae63 100644 --- a/src/api/api/update.ts +++ b/src/api/api/update.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Update a document. Update a document by running a script or passing a partial document. If the Elasticsearch security features are enabled, you must have the `index` or `write` index privilege for the target index or index alias. The script can update, delete, or skip modifying the document. The API also supports passing a partial document, which is merged into the existing document. To fully replace an existing document, use the index API. This operation: * Gets the document (collocated with the shard) from the index. * Runs the specified script. * Indexes the result. The document must still be reindexed, but using this API removes some network roundtrips and reduces chances of version conflicts between the GET and the index operation. The `_source` field must be enabled to use this API. In addition to `_source`, you can access the following variables through the `ctx` map: `_index`, `_type`, `_id`, `_version`, `_routing`, and `_now` (the current timestamp). - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-update.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-update | Elasticsearch API documentation} */ export default async function UpdateApi (this: That, params: T.UpdateRequest, options?: TransportRequestOptionsWithOutMeta): Promise> export default async function UpdateApi (this: That, params: T.UpdateRequest, options?: TransportRequestOptionsWithMeta): Promise, unknown>> diff --git a/src/api/api/update_by_query.ts b/src/api/api/update_by_query.ts index fb09d42f4..38acf4531 100644 --- a/src/api/api/update_by_query.ts +++ b/src/api/api/update_by_query.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Update documents. Updates documents that match the specified query. If no query is specified, performs an update on every document in the data stream or index without modifying the source, which is useful for picking up mapping changes. If the Elasticsearch security features are enabled, you must have the following index privileges for the target data stream, index, or alias: * `read` * `index` or `write` You can specify the query criteria in the request URI or the request body using the same syntax as the search API. When you submit an update by query request, Elasticsearch gets a snapshot of the data stream or index when it begins processing the request and updates matching documents using internal versioning. When the versions match, the document is updated and the version number is incremented. If a document changes between the time that the snapshot is taken and the update operation is processed, it results in a version conflict and the operation fails. You can opt to count version conflicts instead of halting and returning by setting `conflicts` to `proceed`. Note that if you opt to count version conflicts, the operation could attempt to update more documents from the source than `max_docs` until it has successfully updated `max_docs` documents or it has gone through every document in the source query. NOTE: Documents with a version equal to 0 cannot be updated using update by query because internal versioning does not support 0 as a valid version number. While processing an update by query request, Elasticsearch performs multiple search requests sequentially to find all of the matching documents. A bulk update request is performed for each batch of matching documents. Any query or update failures cause the update by query request to fail and the failures are shown in the response. Any update requests that completed successfully still stick, they are not rolled back. **Throttling update requests** To control the rate at which update by query issues batches of update operations, you can set `requests_per_second` to any positive decimal number. This pads each batch with a wait time to throttle the rate. Set `requests_per_second` to `-1` to turn off throttling. Throttling uses a wait time between batches so that the internal scroll requests can be given a timeout that takes the request padding into account. The padding time is the difference between the batch size divided by the `requests_per_second` and the time spent writing. By default the batch size is 1000, so if `requests_per_second` is set to `500`: ``` target_time = 1000 / 500 per second = 2 seconds wait_time = target_time - write_time = 2 seconds - .5 seconds = 1.5 seconds ``` Since the batch is issued as a single _bulk request, large batch sizes cause Elasticsearch to create many requests and wait before starting the next set. This is "bursty" instead of "smooth". **Slicing** Update by query supports sliced scroll to parallelize the update process. This can improve efficiency and provide a convenient way to break the request down into smaller parts. Setting `slices` to `auto` chooses a reasonable number for most data streams and indices. This setting will use one slice per shard, up to a certain limit. If there are multiple source data streams or indices, it will choose the number of slices based on the index or backing index with the smallest number of shards. Adding `slices` to `_update_by_query` just automates the manual process of creating sub-requests, which means it has some quirks: * You can see these requests in the tasks APIs. These sub-requests are "child" tasks of the task for the request with slices. * Fetching the status of the task for the request with `slices` only contains the status of completed slices. * These sub-requests are individually addressable for things like cancellation and rethrottling. * Rethrottling the request with `slices` will rethrottle the unfinished sub-request proportionally. * Canceling the request with slices will cancel each sub-request. * Due to the nature of slices each sub-request won't get a perfectly even portion of the documents. All documents will be addressed, but some slices may be larger than others. Expect larger slices to have a more even distribution. * Parameters like `requests_per_second` and `max_docs` on a request with slices are distributed proportionally to each sub-request. Combine that with the point above about distribution being uneven and you should conclude that using `max_docs` with `slices` might not result in exactly `max_docs` documents being updated. * Each sub-request gets a slightly different snapshot of the source data stream or index though these are all taken at approximately the same time. If you're slicing manually or otherwise tuning automatic slicing, keep in mind that: * Query performance is most efficient when the number of slices is equal to the number of shards in the index or backing index. If that number is large (for example, 500), choose a lower number as too many slices hurts performance. Setting slices higher than the number of shards generally does not improve efficiency and adds overhead. * Update performance scales linearly across available resources with the number of slices. Whether query or update performance dominates the runtime depends on the documents being reindexed and cluster resources. **Update the document source** Update by query supports scripts to update the document source. As with the update API, you can set `ctx.op` to change the operation that is performed. Set `ctx.op = "noop"` if your script decides that it doesn't have to make any changes. The update by query operation skips updating the document and increments the `noop` counter. Set `ctx.op = "delete"` if your script decides that the document should be deleted. The update by query operation deletes the document and increments the `deleted` counter. Update by query supports only `index`, `noop`, and `delete`. Setting `ctx.op` to anything else is an error. Setting any other field in `ctx` is an error. This API enables you to only modify the source of matching documents; you cannot move them. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-update-by-query.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-update-by-query | Elasticsearch API documentation} */ export default async function UpdateByQueryApi (this: That, params: T.UpdateByQueryRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function UpdateByQueryApi (this: That, params: T.UpdateByQueryRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/update_by_query_rethrottle.ts b/src/api/api/update_by_query_rethrottle.ts index c5c9b6c31..eb96ad0ed 100644 --- a/src/api/api/update_by_query_rethrottle.ts +++ b/src/api/api/update_by_query_rethrottle.ts @@ -39,7 +39,7 @@ interface That { transport: Transport } /** * Throttle an update by query operation. Change the number of requests per second for a particular update by query operation. Rethrottling that speeds up the query takes effect immediately but rethrotting that slows down the query takes effect after completing the current batch to prevent scroll timeouts. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/docs-update-by-query.html#docs-update-by-query-rethrottle | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-update-by-query-rethrottle | Elasticsearch API documentation} */ export default async function UpdateByQueryRethrottleApi (this: That, params: T.UpdateByQueryRethrottleRequest, options?: TransportRequestOptionsWithOutMeta): Promise export default async function UpdateByQueryRethrottleApi (this: That, params: T.UpdateByQueryRethrottleRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/watcher.ts b/src/api/api/watcher.ts index df5201232..7e795d62b 100644 --- a/src/api/api/watcher.ts +++ b/src/api/api/watcher.ts @@ -45,7 +45,7 @@ export default class Watcher { /** * Acknowledge a watch. Acknowledging a watch enables you to manually throttle the execution of the watch's actions. The acknowledgement state of an action is stored in the `status.actions..ack.state` structure. IMPORTANT: If the specified watch is currently being executed, this API will return an error The reason for this behavior is to prevent overwriting the watch status from a watch execution. Acknowledging an action throttles further executions of that action until its `ack.state` is reset to `awaits_successful_execution`. This happens when the condition of the watch is not met (the condition evaluates to false). - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/watcher-api-ack-watch.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-ack-watch | Elasticsearch API documentation} */ async ackWatch (this: That, params: T.WatcherAckWatchRequest, options?: TransportRequestOptionsWithOutMeta): Promise async ackWatch (this: That, params: T.WatcherAckWatchRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -95,7 +95,7 @@ export default class Watcher { /** * Activate a watch. A watch can be either active or inactive. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/watcher-api-activate-watch.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-activate-watch | Elasticsearch API documentation} */ async activateWatch (this: That, params: T.WatcherActivateWatchRequest, options?: TransportRequestOptionsWithOutMeta): Promise async activateWatch (this: That, params: T.WatcherActivateWatchRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -137,7 +137,7 @@ export default class Watcher { /** * Deactivate a watch. A watch can be either active or inactive. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/watcher-api-deactivate-watch.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-deactivate-watch | Elasticsearch API documentation} */ async deactivateWatch (this: That, params: T.WatcherDeactivateWatchRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deactivateWatch (this: That, params: T.WatcherDeactivateWatchRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -179,7 +179,7 @@ export default class Watcher { /** * Delete a watch. When the watch is removed, the document representing the watch in the `.watches` index is gone and it will never be run again. Deleting a watch does not delete any watch execution records related to this watch from the watch history. IMPORTANT: Deleting a watch must be done by using only this API. Do not delete the watch directly from the `.watches` index using the Elasticsearch delete document API When Elasticsearch security features are enabled, make sure no write privileges are granted to anyone for the `.watches` index. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/watcher-api-delete-watch.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-delete-watch | Elasticsearch API documentation} */ async deleteWatch (this: That, params: T.WatcherDeleteWatchRequest, options?: TransportRequestOptionsWithOutMeta): Promise async deleteWatch (this: That, params: T.WatcherDeleteWatchRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -221,7 +221,7 @@ export default class Watcher { /** * Run a watch. This API can be used to force execution of the watch outside of its triggering logic or to simulate the watch execution for debugging purposes. For testing and debugging purposes, you also have fine-grained control on how the watch runs. You can run the watch without running all of its actions or alternatively by simulating them. You can also force execution by ignoring the watch condition and control whether a watch record would be written to the watch history after it runs. You can use the run watch API to run watches that are not yet registered by specifying the watch definition inline. This serves as great tool for testing and debugging your watches prior to adding them to Watcher. When Elasticsearch security features are enabled on your cluster, watches are run with the privileges of the user that stored the watches. If your user is allowed to read index `a`, but not index `b`, then the exact same set of rules will apply during execution of a watch. When using the run watch API, the authorization data of the user that called the API will be used as a base, instead of the information who stored the watch. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/watcher-api-execute-watch.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-execute-watch | Elasticsearch API documentation} */ async executeWatch (this: That, params?: T.WatcherExecuteWatchRequest, options?: TransportRequestOptionsWithOutMeta): Promise async executeWatch (this: That, params?: T.WatcherExecuteWatchRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -276,7 +276,7 @@ export default class Watcher { /** * Get Watcher index settings. Get settings for the Watcher internal index (`.watches`). Only a subset of settings are shown, for example `index.auto_expand_replicas` and `index.number_of_replicas`. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/watcher-api-get-settings.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-get-settings | Elasticsearch API documentation} */ async getSettings (this: That, params?: T.WatcherGetSettingsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getSettings (this: That, params?: T.WatcherGetSettingsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -316,7 +316,7 @@ export default class Watcher { /** * Get a watch. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/watcher-api-get-watch.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-get-watch | Elasticsearch API documentation} */ async getWatch (this: That, params: T.WatcherGetWatchRequest, options?: TransportRequestOptionsWithOutMeta): Promise async getWatch (this: That, params: T.WatcherGetWatchRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -358,7 +358,7 @@ export default class Watcher { /** * Create or update a watch. When a watch is registered, a new document that represents the watch is added to the `.watches` index and its trigger is immediately registered with the relevant trigger engine. Typically for the `schedule` trigger, the scheduler is the trigger engine. IMPORTANT: You must use Kibana or this API to create a watch. Do not add a watch directly to the `.watches` index by using the Elasticsearch index API. If Elasticsearch security features are enabled, do not give users write privileges on the `.watches` index. When you add a watch you can also define its initial active state by setting the *active* parameter. When Elasticsearch security features are enabled, your watch can index or search only on indices for which the user that stored the watch has privileges. If the user is able to read index `a`, but not index `b`, the same will apply when the watch runs. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/watcher-api-put-watch.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-put-watch | Elasticsearch API documentation} */ async putWatch (this: That, params: T.WatcherPutWatchRequest, options?: TransportRequestOptionsWithOutMeta): Promise async putWatch (this: That, params: T.WatcherPutWatchRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -405,7 +405,7 @@ export default class Watcher { /** * Query watches. Get all registered watches in a paginated manner and optionally filter watches by a query. Note that only the `_id` and `metadata.*` fields are queryable or sortable. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/watcher-api-query-watches.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-query-watches | Elasticsearch API documentation} */ async queryWatches (this: That, params?: T.WatcherQueryWatchesRequest, options?: TransportRequestOptionsWithOutMeta): Promise async queryWatches (this: That, params?: T.WatcherQueryWatchesRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -450,7 +450,7 @@ export default class Watcher { /** * Start the watch service. Start the Watcher service if it is not already running. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/watcher-api-start.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-start | Elasticsearch API documentation} */ async start (this: That, params?: T.WatcherStartRequest, options?: TransportRequestOptionsWithOutMeta): Promise async start (this: That, params?: T.WatcherStartRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -490,7 +490,7 @@ export default class Watcher { /** * Get Watcher statistics. This API always returns basic metrics. You retrieve more metrics by using the metric parameter. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/watcher-api-stats.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-stats | Elasticsearch API documentation} */ async stats (this: That, params?: T.WatcherStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stats (this: That, params?: T.WatcherStatsRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -540,7 +540,7 @@ export default class Watcher { /** * Stop the watch service. Stop the Watcher service if it is running. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/watcher-api-stop.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-stop | Elasticsearch API documentation} */ async stop (this: That, params?: T.WatcherStopRequest, options?: TransportRequestOptionsWithOutMeta): Promise async stop (this: That, params?: T.WatcherStopRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -580,7 +580,7 @@ export default class Watcher { /** * Update Watcher index settings. Update settings for the Watcher internal index (`.watches`). Only a subset of settings can be modified. This includes `index.auto_expand_replicas` and `index.number_of_replicas`. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/watcher-api-update-settings.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-update-settings | Elasticsearch API documentation} */ async updateSettings (this: That, params?: T.WatcherUpdateSettingsRequest, options?: TransportRequestOptionsWithOutMeta): Promise async updateSettings (this: That, params?: T.WatcherUpdateSettingsRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/api/xpack.ts b/src/api/api/xpack.ts index 0082b65e2..9e6a66f7b 100644 --- a/src/api/api/xpack.ts +++ b/src/api/api/xpack.ts @@ -45,7 +45,7 @@ export default class Xpack { /** * Get information. The information provided by the API includes: * Build information including the build number and timestamp. * License information about the currently installed license. * Feature information for the features that are currently enabled and available under the current license. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/info-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-info | Elasticsearch API documentation} */ async info (this: That, params?: T.XpackInfoRequest, options?: TransportRequestOptionsWithOutMeta): Promise async info (this: That, params?: T.XpackInfoRequest, options?: TransportRequestOptionsWithMeta): Promise> @@ -85,7 +85,7 @@ export default class Xpack { /** * Get usage information. Get information about the features that are currently enabled and available under the current license. The API also provides some usage statistics. - * @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/usage-api.html | Elasticsearch API documentation} + * @see {@link https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-xpack | Elasticsearch API documentation} */ async usage (this: That, params?: T.XpackUsageRequest, options?: TransportRequestOptionsWithOutMeta): Promise async usage (this: That, params?: T.XpackUsageRequest, options?: TransportRequestOptionsWithMeta): Promise> diff --git a/src/api/types.ts b/src/api/types.ts index b2c5dc05d..03cc037eb 100644 --- a/src/api/types.ts +++ b/src/api/types.ts @@ -187,9 +187,9 @@ export interface CountRequest extends RequestBase { routing?: Routing /** The maximum number of documents to collect for each shard. If a query reaches this limit, Elasticsearch terminates the query early. Elasticsearch collects documents before sorting. IMPORTANT: Use with caution. Elasticsearch applies this parameter to each shard handling the request. When possible, let Elasticsearch perform early termination automatically. Avoid specifying this parameter for requests that target data streams with backing indices across multiple data tiers. */ terminate_after?: long - /** The query in Lucene query string syntax. */ + /** The query in Lucene query string syntax. This parameter cannot be used with a request body. */ q?: string - /** Defines the search definition using the Query DSL. The query is optional, and when not provided, it will use `match_all` to count all the docs. */ + /** Defines the search query using Query DSL. A request body query cannot be used with the `q` query string parameter. */ query?: QueryDslQueryContainer /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { index?: never, allow_no_indices?: never, analyzer?: never, analyze_wildcard?: never, default_operator?: never, df?: never, expand_wildcards?: never, ignore_throttled?: never, ignore_unavailable?: never, lenient?: never, min_score?: never, preference?: never, routing?: never, terminate_after?: never, q?: never, query?: never } @@ -363,11 +363,11 @@ export interface DeleteByQueryRethrottleRequest extends RequestBase { export type DeleteByQueryRethrottleResponse = TasksTaskListResponseBase export interface DeleteScriptRequest extends RequestBase { -/** Identifier for the stored script or search template. */ +/** The identifier for the stored script or search template. */ id: Id - /** Period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error. */ + /** The period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. */ master_timeout?: Duration - /** Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. */ + /** The period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. */ timeout?: Duration /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { id?: never, master_timeout?: never, timeout?: never } @@ -454,33 +454,33 @@ export interface ExplainExplanationDetail { } export interface ExplainRequest extends RequestBase { -/** Defines the document ID. */ +/** The document identifier. */ id: Id - /** Index names used to limit the request. Only a single index name can be provided to this parameter. */ + /** Index names that are used to limit the request. Only a single index name can be provided to this parameter. */ index: IndexName - /** Analyzer to use for the query string. This parameter can only be used when the `q` query string parameter is specified. */ + /** The analyzer to use for the query string. This parameter can be used only when the `q` query string parameter is specified. */ analyzer?: string - /** If `true`, wildcard and prefix queries are analyzed. */ + /** If `true`, wildcard and prefix queries are analyzed. This parameter can be used only when the `q` query string parameter is specified. */ analyze_wildcard?: boolean - /** The default operator for query string query: `AND` or `OR`. */ + /** The default operator for query string query: `AND` or `OR`. This parameter can be used only when the `q` query string parameter is specified. */ default_operator?: QueryDslOperator - /** Field to use as default where no field prefix is given in the query string. */ + /** The field to use as default where no field prefix is given in the query string. This parameter can be used only when the `q` query string parameter is specified. */ df?: string - /** If `true`, format-based query failures (such as providing text to a numeric field) in the query string will be ignored. */ + /** If `true`, format-based query failures (such as providing text to a numeric field) in the query string will be ignored. This parameter can be used only when the `q` query string parameter is specified. */ lenient?: boolean - /** Specifies the node or shard the operation should be performed on. Random by default. */ + /** The node or shard the operation should be performed on. It is random by default. */ preference?: string - /** Custom value used to route operations to a specific shard. */ + /** A custom value used to route operations to a specific shard. */ routing?: Routing - /** True or false to return the `_source` field or not, or a list of fields to return. */ + /** `True` or `false` to return the `_source` field or not or a list of fields to return. */ _source?: SearchSourceConfigParam - /** A comma-separated list of source fields to exclude from the response. */ + /** A comma-separated list of source fields to exclude from the response. You can also use this parameter to exclude fields from the subset specified in `_source_includes` query parameter. If the `_source` parameter is `false`, this parameter is ignored. */ _source_excludes?: Fields - /** A comma-separated list of source fields to include in the response. */ + /** A comma-separated list of source fields to include in the response. If this parameter is specified, only these source fields are returned. You can exclude fields from this subset using the `_source_excludes` query parameter. If the `_source` parameter is `false`, this parameter is ignored. */ _source_includes?: Fields /** A comma-separated list of stored fields to return in the response. */ stored_fields?: Fields - /** Query in the Lucene query string syntax. */ + /** The query in the Lucene query string syntax. */ q?: string /** Defines the search definition using the Query DSL. */ query?: QueryDslQueryContainer @@ -514,27 +514,27 @@ export interface FieldCapsFieldCapability { } export interface FieldCapsRequest extends RequestBase { -/** Comma-separated list of data streams, indices, and aliases used to limit the request. Supports wildcards (*). To target all data streams and indices, omit this parameter or use * or _all. */ +/** A comma-separated list of data streams, indices, and aliases used to limit the request. Supports wildcards (*). To target all data streams and indices, omit this parameter or use * or _all. */ index?: Indices /** If false, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targeting `foo*,bar*` returns an error if an index starts with foo but no index starts with bar. */ allow_no_indices?: boolean - /** Type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports comma-separated values, such as `open,hidden`. */ + /** The type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports comma-separated values, such as `open,hidden`. */ expand_wildcards?: ExpandWildcards /** If `true`, missing or closed indices are not included in the response. */ ignore_unavailable?: boolean /** If true, unmapped fields are included in the response. */ include_unmapped?: boolean - /** An optional set of filters: can include +metadata,-metadata,-nested,-multifield,-parent */ + /** A comma-separated list of filters to apply to the response. */ filters?: string - /** Only return results for fields that have one of the types in the list */ + /** A comma-separated list of field types to include. Any fields that do not match one of these types will be excluded from the results. It defaults to empty, meaning that all field types are returned. */ types?: string[] /** If false, empty fields are not included in the response. */ include_empty_fields?: boolean - /** List of fields to retrieve capabilities for. Wildcard (`*`) expressions are supported. */ + /** A list of fields to retrieve capabilities for. Wildcard (`*`) expressions are supported. */ fields?: Fields - /** Allows to filter indices if the provided query rewrites to match_none on every shard. */ + /** Filter indices if the provided query rewrites to `match_none` on every shard. IMPORTANT: The filtering is done on a best-effort basis, it uses index statistics and mappings to rewrite queries to `match_none` instead of fully running the request. For instance a range query over a date field can rewrite to `match_none` if all documents within a shard (including deleted documents) are outside of the provided range. However, not all queries can rewrite to `match_none` so this API may return an index even if the provided filter matches no document. */ index_filter?: QueryDslQueryContainer - /** Defines ad-hoc runtime fields in the request similar to the way it is done in search requests. These fields exist only as part of the query and take precedence over fields defined with the same name in the index mappings. */ + /** Define ad-hoc runtime fields in the request similar to the way it is done in search requests. These fields exist only as part of the query and take precedence over fields defined with the same name in the index mappings. */ runtime_mappings?: MappingRuntimeFields /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { index?: never, allow_no_indices?: never, expand_wildcards?: never, ignore_unavailable?: never, include_unmapped?: never, filters?: never, types?: never, include_empty_fields?: never, fields?: never, index_filter?: never, runtime_mappings?: never } @@ -596,9 +596,9 @@ export interface GetRequest extends RequestBase { export type GetResponse = GetGetResult export interface GetScriptRequest extends RequestBase { -/** Identifier for the stored script or search template. */ +/** The identifier for the stored script or search template. */ id: Id - /** Specify timeout for connection to master */ + /** The period to wait for the master node. If the master node is not available before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. */ master_timeout?: Duration /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { id?: never, master_timeout?: never } @@ -938,21 +938,21 @@ export interface InfoResponse { } export interface KnnSearchRequest extends RequestBase { -/** A comma-separated list of index names to search; use `_all` or to perform the operation on all indices */ +/** A comma-separated list of index names to search; use `_all` or to perform the operation on all indices. */ index: Indices - /** A comma-separated list of specific routing values */ + /** A comma-separated list of specific routing values. */ routing?: Routing - /** Indicates which source fields are returned for matching documents. These fields are returned in the hits._source property of the search response. */ + /** Indicates which source fields are returned for matching documents. These fields are returned in the `hits._source` property of the search response. */ _source?: SearchSourceConfig - /** The request returns doc values for field names matching these patterns in the hits.fields property of the response. Accepts wildcard (*) patterns. */ + /** The request returns doc values for field names matching these patterns in the `hits.fields` property of the response. It accepts wildcard (`*`) patterns. */ docvalue_fields?: (QueryDslFieldAndFormat | Field)[] - /** List of stored fields to return as part of a hit. If no fields are specified, no stored fields are included in the response. If this field is specified, the _source parameter defaults to false. You can pass _source: true to return both source fields and stored fields in the search response. */ + /** A list of stored fields to return as part of a hit. If no fields are specified, no stored fields are included in the response. If this field is specified, the `_source` parameter defaults to `false`. You can pass `_source: true` to return both source fields and stored fields in the search response. */ stored_fields?: Fields - /** The request returns values for field names matching these patterns in the hits.fields property of the response. Accepts wildcard (*) patterns. */ + /** The request returns values for field names matching these patterns in the `hits.fields` property of the response. It accepts wildcard (`*`) patterns. */ fields?: Fields - /** Query to filter the documents that can match. The kNN search will return the top `k` documents that also match this filter. The value can be a single query or a list of queries. If `filter` isn't provided, all documents are allowed to match. */ + /** A query to filter the documents that can match. The kNN search will return the top `k` documents that also match this filter. The value can be a single query or a list of queries. If `filter` isn't provided, all documents are allowed to match. */ filter?: QueryDslQueryContainer | QueryDslQueryContainer[] - /** kNN query to execute */ + /** The kNN query to run. */ knn: KnnSearchQuery /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { index?: never, routing?: never, _source?: never, docvalue_fields?: never, stored_fields?: never, fields?: never, filter?: never, knn?: never } @@ -1130,13 +1130,13 @@ export type MsearchResponse = MsearchMultiSearchItem | ErrorResponseBase export interface MsearchTemplateRequest extends RequestBase { -/** Comma-separated list of data streams, indices, and aliases to search. Supports wildcards (`*`). To search all data streams and indices, omit this parameter or use `*`. */ +/** A comma-separated list of data streams, indices, and aliases to search. It supports wildcards (`*`). To search all data streams and indices, omit this parameter or use `*`. */ index?: Indices /** If `true`, network round-trips are minimized for cross-cluster search requests. */ ccs_minimize_roundtrips?: boolean - /** Maximum number of concurrent searches the API can run. */ + /** The maximum number of concurrent searches the API can run. */ max_concurrent_searches?: long - /** The type of the search operation. Available options: `query_then_fetch`, `dfs_query_then_fetch`. */ + /** The type of the search operation. */ search_type?: SearchType /** If `true`, the response returns `hits.total` as an integer. If `false`, it returns `hits.total` as an object. */ rest_total_hits_as_int?: boolean @@ -1178,9 +1178,9 @@ export interface MtermvectorsOperation { } export interface MtermvectorsRequest extends RequestBase { -/** Name of the index that contains the documents. */ +/** The name of the index that contains the documents. */ index?: IndexName - /** Comma-separated list or wildcard expressions of fields to include in the statistics. Used as the default list unless a specific field list is provided in the `completion_fields` or `fielddata_fields` parameters. */ + /** A comma-separated list or wildcard expressions of fields to include in the statistics. It is used as the default list unless a specific field list is provided in the `completion_fields` or `fielddata_fields` parameters. */ fields?: Fields /** If `true`, the response includes the document count, sum of document frequencies, and sum of total term frequencies. */ field_statistics?: boolean @@ -1190,21 +1190,21 @@ export interface MtermvectorsRequest extends RequestBase { payloads?: boolean /** If `true`, the response includes term positions. */ positions?: boolean - /** Specifies the node or shard the operation should be performed on. Random by default. */ + /** The node or shard the operation should be performed on. It is random by default. */ preference?: string /** If true, the request is real-time as opposed to near-real-time. */ realtime?: boolean - /** Custom value used to route operations to a specific shard. */ + /** A custom value used to route operations to a specific shard. */ routing?: Routing /** If true, the response includes term frequency and document frequency. */ term_statistics?: boolean /** If `true`, returns the document version as part of a hit. */ version?: VersionNumber - /** Specific version type. */ + /** The version type. */ version_type?: VersionType - /** Array of existing or artificial documents. */ + /** An array of existing or artificial documents. */ docs?: MtermvectorsOperation[] - /** Simplified syntax to specify documents by their ID if they're in the same index. */ + /** A simplified syntax to specify documents by their ID if they're in the same index. */ ids?: Id[] /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { index?: never, fields?: never, field_statistics?: never, offsets?: never, payloads?: never, positions?: never, preference?: never, realtime?: never, routing?: never, term_statistics?: never, version?: never, version_type?: never, docs?: never, ids?: never } @@ -1264,15 +1264,15 @@ export interface PingRequest extends RequestBase { export type PingResponse = boolean export interface PutScriptRequest extends RequestBase { -/** Identifier for the stored script or search template. Must be unique within the cluster. */ +/** The identifier for the stored script or search template. It must be unique within the cluster. */ id: Id - /** Context in which the script or search template should run. To prevent errors, the API immediately compiles the script or template in this context. */ + /** The context in which the script or search template should run. To prevent errors, the API immediately compiles the script or template in this context. */ context?: Name - /** Period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error. */ + /** The period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. */ master_timeout?: Duration - /** Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. */ + /** The period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. */ timeout?: Duration - /** Contains the script or search template, its parameters, and its language. */ + /** The script or search template, its parameters, and its language. */ script: StoredScript /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { id?: never, context?: never, master_timeout?: never, timeout?: never, script?: never } @@ -1354,7 +1354,7 @@ export interface RankEvalRankEvalRequestItem { } export interface RankEvalRequest extends RequestBase { -/** Comma-separated list of data streams, indices, and index aliases used to limit the request. Wildcard (`*`) expressions are supported. To target all data streams and indices in a cluster, omit this parameter or use `_all` or `*`. */ +/** A comma-separated list of data streams, indices, and index aliases used to limit the request. Wildcard (`*`) expressions are supported. To target all data streams and indices in a cluster, omit this parameter or use `_all` or `*`. */ index?: Indices /** If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targeting `foo*,bar*` returns an error if an index starts with `foo` but no index starts with `bar`. */ allow_no_indices?: boolean @@ -1515,12 +1515,12 @@ export interface ReindexRethrottleResponse { } export interface RenderSearchTemplateRequest extends RequestBase { -/** ID of the search template to render. If no `source` is specified, this or the `id` request body parameter is required. */ +/** The ID of the search template to render. If no `source` is specified, this or the `id` request body parameter is required. */ id?: Id file?: string /** Key-value pairs used to replace Mustache variables in the template. The key is the variable name. The value is the variable value. */ params?: Record - /** An inline search template. Supports the same parameters as the search API's request body. These parameters also support Mustache variables. If no `id` or `` is specified, this parameter is required. */ + /** An inline search template. It supports the same parameters as the search API's request body. These parameters also support Mustache variables. If no `id` or `` is specified, this parameter is required. */ source?: string /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { id?: never, file?: never, params?: never, source?: never } @@ -1562,7 +1562,7 @@ export interface ScrollRequest extends RequestBase { scroll_id?: ScrollId /** If true, the API response’s hit.total property is returned as an integer. If false, the API response’s hit.total property is returned as an object. */ rest_total_hits_as_int?: boolean - /** Period to retain the search context for scrolling. */ + /** The period to retain the search context for scrolling. */ scroll?: Duration /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { scroll_id?: never, rest_total_hits_as_int?: never, scroll?: never } @@ -2307,33 +2307,33 @@ export interface SearchMvtRequest extends RequestBase { x: SearchMvtCoordinate /** Y coordinate for the vector tile to search */ y: SearchMvtCoordinate - /** Sub-aggregations for the geotile_grid. Supports the following aggregation types: - avg - cardinality - max - min - sum */ + /** Sub-aggregations for the geotile_grid. It supports the following aggregation types: - `avg` - `boxplot` - `cardinality` - `extended stats` - `max` - `median absolute deviation` - `min` - `percentile` - `percentile-rank` - `stats` - `sum` - `value count` The aggregation names can't start with `_mvt_`. The `_mvt_` prefix is reserved for internal aggregations. */ aggs?: Record - /** Size, in pixels, of a clipping buffer outside the tile. This allows renderers to avoid outline artifacts from geometries that extend past the extent of the tile. */ + /** The size, in pixels, of a clipping buffer outside the tile. This allows renderers to avoid outline artifacts from geometries that extend past the extent of the tile. */ buffer?: integer - /** 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. The aggregation runs on values that intersect the // tile with wrap_longitude set to false. The resulting bounding box may be larger than the vector tile. */ + /** 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. The aggregation runs on values that intersect the `//` tile with `wrap_longitude` set to `false`. The resulting bounding box may be larger than the vector tile. */ exact_bounds?: boolean - /** Size, in pixels, of a side of the tile. Vector tiles are square with equal sides. */ + /** The size, in pixels, of a side of the tile. Vector tiles are square with equal sides. */ extent?: integer - /** Fields to return in the `hits` layer. Supports wildcards (`*`). This parameter does not support fields with array values. Fields with array values may return inconsistent results. */ + /** The fields to return in the `hits` layer. It supports wildcards (`*`). This parameter does not support fields with array values. Fields with array values may return inconsistent results. */ fields?: Fields - /** Aggregation used to create a grid for the `field`. */ + /** The aggregation used to create a grid for the `field`. */ grid_agg?: SearchMvtGridAggregationType - /** Additional zoom levels available through the aggs layer. For example, if is 7 and grid_precision is 8, you can zoom in up to level 15. Accepts 0-8. If 0, results don’t include the aggs layer. */ + /** Additional zoom levels available through the aggs layer. For example, if `` is `7` and `grid_precision` is `8`, you can zoom in up to level 15. Accepts 0-8. If 0, results don't include the aggs layer. */ grid_precision?: integer - /** Determines the geometry type for features in the aggs layer. In the aggs layer, each feature represents a geotile_grid cell. If 'grid' each feature is a Polygon of the cells bounding box. If 'point' each feature is a Point that is the centroid of the cell. */ + /** Determines the geometry type for features in the aggs layer. In the aggs layer, each feature represents a `geotile_grid` cell. If `grid, each feature is a polygon of the cells bounding box. If `point`, each feature is a Point that is the centroid of the cell. */ grid_type?: SearchMvtGridType - /** Query DSL used to filter documents for the search. */ + /** The query DSL used to filter documents for the search. */ query?: QueryDslQueryContainer /** Defines one or more runtime fields in the search request. These fields take precedence over mapped fields with the same name. */ runtime_mappings?: MappingRuntimeFields - /** Maximum number of features to return in the hits layer. Accepts 0-10000. If 0, results don’t include the hits layer. */ + /** The maximum number of features to return in the hits layer. Accepts 0-10000. If 0, results don't include the hits layer. */ size?: integer - /** Sorts features in the hits layer. By default, the API calculates a bounding box for each feature. It sorts features based on this box’s diagonal length, from longest to shortest. */ + /** Sort the features in the hits layer. By default, the API calculates a bounding box for each feature. It sorts features based on this box's diagonal length, from longest to shortest. */ sort?: Sort - /** Number of hits matching the query to count accurately. If `true`, the exact number of hits is returned at the cost of some performance. If `false`, the response does not include the total number of hits matching the query. */ + /** The number of hits matching the query to count accurately. If `true`, the exact number of hits is returned at the cost of some performance. If `false`, the response does not include the total number of hits matching the query. */ track_total_hits?: SearchTrackHits - /** If `true`, the hits and aggs layers will contain additional point features representing suggested label positions for the original features. */ + /** If `true`, the hits and aggs layers will contain additional point features representing suggested label positions for the original features. * `Point` and `MultiPoint` features will have one of the points selected. * `Polygon` and `MultiPolygon` features will have a single point generated, either the centroid, if it is within the polygon, or another point within the polygon selected from the sorted triangle-tree. * `LineString` features will likewise provide a roughly central point selected from the triangle-tree. * The aggregation results will provide one central point for each aggregation bucket. All attributes from the original features will also be copied to the new label features. In addition, the new features will be distinguishable using the tag `_mvt_label_position`. */ with_labels?: boolean /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { index?: never, field?: never, zoom?: never, x?: never, y?: never, aggs?: never, buffer?: never, exact_bounds?: never, extent?: never, fields?: never, grid_agg?: never, grid_precision?: never, grid_type?: never, query?: never, runtime_mappings?: never, size?: never, sort?: never, track_total_hits?: never, with_labels?: never } @@ -2352,7 +2352,7 @@ export type SearchMvtGridType = 'grid' | 'point' | 'centroid' export type SearchMvtZoomLevel = integer export interface SearchShardsRequest extends RequestBase { -/** Returns the indices and shards that a search request would be executed against. */ +/** A comma-separated list of data streams, indices, and aliases to search. It supports wildcards (`*`). To search all data streams and indices, omit this parameter or use `*` or `_all`. */ index?: Indices /** If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targeting `foo*,bar*` returns an error if an index starts with `foo` but no index starts with `bar`. */ allow_no_indices?: boolean @@ -2362,11 +2362,11 @@ export interface SearchShardsRequest extends RequestBase { ignore_unavailable?: boolean /** If `true`, the request retrieves information from the local node only. */ local?: boolean - /** Period to wait for a connection to the master node. */ + /** The period to wait for a connection to the master node. If the master node is not available before the timeout expires, the request fails and returns an error. IT can also be set to `-1` to indicate that the request should never timeout. */ master_timeout?: Duration - /** Specifies the node or shard the operation should be performed on. Random by default. */ + /** The node or shard the operation should be performed on. It is random by default. */ preference?: string - /** Custom value used to route operations to a specific shard. */ + /** A custom value used to route operations to a specific shard. */ routing?: Routing /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { index?: never, allow_no_indices?: never, expand_wildcards?: never, ignore_unavailable?: never, local?: never, master_timeout?: never, preference?: never, routing?: never } @@ -2398,39 +2398,39 @@ export interface SearchShardsShardStoreIndex { } export interface SearchTemplateRequest extends RequestBase { -/** Comma-separated list of data streams, indices, and aliases to search. Supports wildcards (*). */ +/** A comma-separated list of data streams, indices, and aliases to search. It supports wildcards (`*`). */ index?: Indices /** If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targeting `foo*,bar*` returns an error if an index starts with `foo` but no index starts with `bar`. */ allow_no_indices?: boolean /** If `true`, network round-trips are minimized for cross-cluster search requests. */ ccs_minimize_roundtrips?: boolean - /** Type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports comma-separated values, such as `open,hidden`. Valid values are: `all`, `open`, `closed`, `hidden`, `none`. */ + /** The type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports comma-separated values, such as `open,hidden`. Valid values are: `all`, `open`, `closed`, `hidden`, `none`. */ expand_wildcards?: ExpandWildcards /** If `true`, specified concrete, expanded, or aliased indices are not included in the response when throttled. */ ignore_throttled?: boolean /** If `false`, the request returns an error if it targets a missing or closed index. */ ignore_unavailable?: boolean - /** Specifies the node or shard the operation should be performed on. Random by default. */ + /** The node or shard the operation should be performed on. It is random by default. */ preference?: string - /** Custom value used to route operations to a specific shard. */ + /** A custom value used to route operations to a specific shard. */ routing?: Routing /** Specifies how long a consistent view of the index should be maintained for scrolled search. */ scroll?: Duration /** The type of the search operation. */ search_type?: SearchType - /** If true, hits.total are rendered as an integer in the response. */ + /** If `true`, `hits.total` is rendered as an integer in the response. If `false`, it is rendered as an object. */ rest_total_hits_as_int?: boolean /** If `true`, the response prefixes aggregation and suggester names with their respective types. */ typed_keys?: boolean - /** If `true`, returns detailed information about score calculation as part of each hit. */ + /** If `true`, returns detailed information about score calculation as part of each hit. If you specify both this and the `explain` query parameter, the API uses only the query parameter. */ explain?: boolean - /** ID of the search template to use. If no source is specified, this parameter is required. */ + /** The ID of the search template to use. If no `source` is specified, this parameter is required. */ id?: Id /** Key-value pairs used to replace Mustache variables in the template. The key is the variable name. The value is the variable value. */ params?: Record /** If `true`, the query execution is profiled. */ profile?: boolean - /** An inline search template. Supports the same parameters as the search API's request body. Also supports Mustache variables. If no id is specified, this parameter is required. */ + /** An inline search template. Supports the same parameters as the search API's request body. It also supports Mustache variables. If no `id` is specified, this parameter is required. */ source?: string /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { index?: never, allow_no_indices?: never, ccs_minimize_roundtrips?: never, expand_wildcards?: never, ignore_throttled?: never, ignore_unavailable?: never, preference?: never, routing?: never, scroll?: never, search_type?: never, rest_total_hits_as_int?: never, typed_keys?: never, explain?: never, id?: never, params?: never, profile?: never, source?: never } @@ -2456,20 +2456,21 @@ export interface SearchTemplateResponse { } export interface TermsEnumRequest extends RequestBase { -/** Comma-separated list of data streams, indices, and index aliases to search. Wildcard (*) expressions are supported. */ +/** A comma-separated list of data streams, indices, and index aliases to search. Wildcard (`*`) expressions are supported. To search all data streams or indices, omit this parameter or use `*` or `_all`. */ index: IndexName /** The string to match at the start of indexed terms. If not provided, all terms in the field are considered. */ field: Field - /** How many matching terms to return. */ + /** The number of matching terms to return. */ size?: integer - /** The maximum length of time to spend collecting results. Defaults to "1s" (one second). If the timeout is exceeded the complete flag set to false in the response and the results may be partial or empty. */ + /** The maximum length of time to spend collecting results. If the timeout is exceeded the `complete` flag set to `false` in the response and the results may be partial or empty. */ timeout?: Duration - /** When true the provided search string is matched against index terms without case sensitivity. */ + /** When `true`, the provided search string is matched against index terms without case sensitivity. */ case_insensitive?: boolean - /** Allows to filter an index shard if the provided query rewrites to match_none. */ + /** Filter an index shard if the provided query rewrites to `match_none`. */ index_filter?: QueryDslQueryContainer - /** The string after which terms in the index should be returned. Allows for a form of pagination if the last result from one request is passed as the search_after parameter for a subsequent request. */ + /** The string to match at the start of indexed terms. If it is not provided, all terms in the field are considered. > info > The prefix string cannot be larger than the largest possible keyword value, which is Lucene's term byte-length limit of 32766. */ string?: string + /** The string after which terms in the index should be returned. It allows for a form of pagination if the last result from one request is passed as the `search_after` parameter for a subsequent request. */ search_after?: string /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { index?: never, field?: never, size?: never, timeout?: never, case_insensitive?: never, index_filter?: never, string?: never, search_after?: never } @@ -2500,13 +2501,13 @@ export interface TermvectorsFilter { } export interface TermvectorsRequest extends RequestBase { -/** Name of the index that contains the document. */ +/** The name of the index that contains the document. */ index: IndexName - /** Unique identifier of the document. */ + /** A unique identifier for the document. */ id?: Id - /** Comma-separated list or wildcard expressions of fields to include in the statistics. Used as the default list unless a specific field list is provided in the `completion_fields` or `fielddata_fields` parameters. */ + /** A comma-separated list or wildcard expressions of fields to include in the statistics. It is used as the default list unless a specific field list is provided in the `completion_fields` or `fielddata_fields` parameters. */ fields?: Fields - /** If `true`, the response includes the document count, sum of document frequencies, and sum of total term frequencies. */ + /** If `true`, the response includes: * The document count (how many documents contain this field). * The sum of document frequencies (the sum of document frequencies for all terms in this field). * The sum of total term frequencies (the sum of total term frequencies of each term in this field). */ field_statistics?: boolean /** If `true`, the response includes term offsets. */ offsets?: boolean @@ -2514,23 +2515,23 @@ export interface TermvectorsRequest extends RequestBase { payloads?: boolean /** If `true`, the response includes term positions. */ positions?: boolean - /** Specifies the node or shard the operation should be performed on. Random by default. */ + /** The node or shard the operation should be performed on. It is random by default. */ preference?: string /** If true, the request is real-time as opposed to near-real-time. */ realtime?: boolean - /** Custom value used to route operations to a specific shard. */ + /** A custom value that is used to route operations to a specific shard. */ routing?: Routing - /** If `true`, the response includes term frequency and document frequency. */ + /** If `true`, the response includes: * The total term frequency (how often a term occurs in all documents). * The document frequency (the number of documents containing the current term). By default these values are not returned since term statistics can have a serious performance impact. */ term_statistics?: boolean /** If `true`, returns the document version as part of a hit. */ version?: VersionNumber - /** Specific version type. */ + /** The version type. */ version_type?: VersionType /** An artificial document (a document not present in the index) for which you want to retrieve term vectors. */ doc?: TDocument - /** Filter terms based on their tf-idf scores. */ + /** Filter terms based on their tf-idf scores. This could be useful in order find out a good characteristic vector of a document. This feature works in a similar manner to the second phase of the More Like This Query. */ filter?: TermvectorsFilter - /** Overrides the default per-field analyzer. */ + /** Override the default per-field analyzer. This is useful in order to generate term vectors in any fashion, especially when using artificial documents. When providing an analyzer for a field that already stores term vectors, the term vectors will be regenerated. */ per_field_analyzer?: Record /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { index?: never, id?: never, fields?: never, field_statistics?: never, offsets?: never, payloads?: never, positions?: never, preference?: never, realtime?: never, routing?: never, term_statistics?: never, version?: never, version_type?: never, doc?: never, filter?: never, per_field_analyzer?: never } @@ -2897,7 +2898,7 @@ export interface ErrorResponseBase { status: integer } -export type EsqlColumns = ArrayBuffer +export type EsqlResult = ArrayBuffer export type ExpandWildcard = 'all' | 'open' | 'closed' | 'hidden' | 'none' @@ -9781,9 +9782,9 @@ export interface CcrFollowInfoResponse { } export interface CcrFollowStatsRequest extends RequestBase { -/** A comma-separated list of index patterns; use `_all` to perform the operation on all indices */ +/** A comma-delimited list of index patterns. */ index: Indices - /** Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. */ + /** The period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. */ timeout?: Duration /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { index?: never, timeout?: never } @@ -9829,9 +9830,9 @@ export interface CcrGetAutoFollowPatternAutoFollowPatternSummary { } export interface CcrGetAutoFollowPatternRequest extends RequestBase { -/** Specifies the auto-follow pattern collection that you want to retrieve. If you do not specify a name, the API returns information for all collections. */ +/** The auto-follow pattern collection that you want to retrieve. If you do not specify a name, the API returns information for all collections. */ name?: Name - /** Period to wait for a connection to the master node. */ + /** The period to wait for a connection to the master node. If the master node is not available before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. */ master_timeout?: Duration /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { name?: never, master_timeout?: never } @@ -9844,9 +9845,9 @@ export interface CcrGetAutoFollowPatternResponse { } export interface CcrPauseAutoFollowPatternRequest extends RequestBase { -/** The name of the auto follow pattern that should pause discovering new indices to follow. */ +/** The name of the auto-follow pattern to pause. */ name: Name - /** Period to wait for a connection to the master node. */ + /** The period to wait for a connection to the master node. If the master node is not available before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. */ master_timeout?: Duration /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { name?: never, master_timeout?: never } @@ -9857,9 +9858,9 @@ export interface CcrPauseAutoFollowPatternRequest extends RequestBase { export type CcrPauseAutoFollowPatternResponse = AcknowledgedResponseBase export interface CcrPauseFollowRequest extends RequestBase { -/** The name of the follower index that should pause following its leader index. */ +/** The name of the follower index. */ index: IndexName - /** Period to wait for a connection to the master node. */ + /** The period to wait for a connection to the master node. If the master node is not available before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. */ master_timeout?: Duration /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { index?: never, master_timeout?: never } @@ -9913,9 +9914,9 @@ export interface CcrPutAutoFollowPatternRequest extends RequestBase { export type CcrPutAutoFollowPatternResponse = AcknowledgedResponseBase export interface CcrResumeAutoFollowPatternRequest extends RequestBase { -/** The name of the auto follow pattern to resume discovering new indices to follow. */ +/** The name of the auto-follow pattern to resume. */ name: Name - /** Period to wait for a connection to the master node. */ + /** The period to wait for a connection to the master node. If the master node is not available before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. */ master_timeout?: Duration /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { name?: never, master_timeout?: never } @@ -9967,9 +9968,9 @@ export interface CcrStatsFollowStats { } export interface CcrStatsRequest extends RequestBase { -/** Period to wait for a connection to the master node. */ +/** The period to wait for a connection to the master node. If the master node is not available before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. */ master_timeout?: Duration - /** Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. */ + /** The period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. */ timeout?: Duration /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { master_timeout?: never, timeout?: never } @@ -9983,9 +9984,9 @@ export interface CcrStatsResponse { } export interface CcrUnfollowRequest extends RequestBase { -/** The name of the follower index that should be turned into a regular index. */ +/** The name of the follower index. */ index: IndexName - /** Period to wait for a connection to the master node. */ + /** The period to wait for a connection to the master node. If the master node is not available before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. */ master_timeout?: Duration /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { index?: never, master_timeout?: never } @@ -10004,6 +10005,7 @@ export interface ClusterComponentTemplateNode { template: ClusterComponentTemplateSummary version?: VersionNumber _meta?: Metadata + deprecated?: boolean } export interface ClusterComponentTemplateSummary { @@ -10421,6 +10423,7 @@ export interface ClusterRemoteInfoClusterRemoteProxyInfo { server_name: string num_proxy_sockets_connected: integer max_proxy_socket_connections: integer + cluster_credentials?: string } export interface ClusterRemoteInfoClusterRemoteSniffInfo { @@ -11791,7 +11794,9 @@ export interface EqlSearchRequest extends RequestBase { keep_alive?: Duration keep_on_completion?: boolean wait_for_completion_timeout?: Duration + /** Allow query execution also in case of shard failures. If true, the query will keep running and will return results based on the available shards. For sequences, the behavior can be further refined using allow_partial_sequence_results */ allow_partial_search_results?: boolean + /** This flag applies only to sequences and has effect only if allow_partial_search_results=true. If true, the sequence query will return results based on the available shards, ignoring the others. If false, the sequence query will return successfully, but will always have empty results. */ allow_partial_sequence_results?: boolean /** For basic queries, the maximum number of matching events to return. Defaults to 10 */ size?: uint @@ -11860,11 +11865,7 @@ export interface EsqlAsyncQueryRequest extends RequestBase { querystring?: { [key: string]: any } & { delimiter?: never, drop_null_columns?: never, format?: never, keep_alive?: never, keep_on_completion?: never, wait_for_completion_timeout?: never, columnar?: never, filter?: never, locale?: never, params?: never, profile?: never, query?: never, tables?: never } } -export interface EsqlAsyncQueryResponse { - columns?: EsqlColumns - id?: string - is_running: boolean -} +export type EsqlAsyncQueryResponse = EsqlResult export interface EsqlAsyncQueryDeleteRequest extends RequestBase { /** The unique identifier of the query. A query ID is provided in the ES|QL async query API response for a query that does not complete in the designated time. A query ID is also provided when the request was submitted with the `keep_on_completion` parameter set to `true`. */ @@ -11892,11 +11893,21 @@ export interface EsqlAsyncQueryGetRequest extends RequestBase { querystring?: { [key: string]: any } & { id?: never, drop_null_columns?: never, keep_alive?: never, wait_for_completion_timeout?: never } } -export interface EsqlAsyncQueryGetResponse { - columns?: EsqlColumns - is_running: boolean +export type EsqlAsyncQueryGetResponse = EsqlResult + +export interface EsqlAsyncQueryStopRequest extends RequestBase { +/** The unique identifier of the query. A query ID is provided in the ES|QL async query API response for a query that does not complete in the designated time. A query ID is also provided when the request was submitted with the `keep_on_completion` parameter set to `true`. */ + id: Id + /** Indicates whether columns that are entirely `null` will be removed from the `columns` and `values` portion of the results. If `true`, the response will include an extra section under the name `all_columns` which has the name of all the columns. */ + drop_null_columns?: boolean + /** All values in `body` will be added to the request body. */ + body?: string | { [key: string]: any } & { id?: never, drop_null_columns?: never } + /** All values in `querystring` will be added to the request querystring. */ + querystring?: { [key: string]: any } & { id?: never, drop_null_columns?: never } } +export type EsqlAsyncQueryStopResponse = EsqlResult + export interface EsqlQueryRequest extends RequestBase { /** A short version of the Accept header, e.g. json, yaml. */ format?: EsqlEsqlFormat @@ -11923,7 +11934,7 @@ export interface EsqlQueryRequest extends RequestBase { querystring?: { [key: string]: any } & { format?: never, delimiter?: never, drop_null_columns?: never, columnar?: never, filter?: never, locale?: never, params?: never, profile?: never, query?: never, tables?: never } } -export type EsqlQueryResponse = EsqlColumns +export type EsqlQueryResponse = EsqlResult export interface FeaturesFeature { name: string @@ -12982,7 +12993,7 @@ export interface IndicesSoftDeletes { retention_lease?: IndicesRetentionLease } -export type IndicesSourceMode = 'disabled' | 'stored' | 'synthetic' +export type IndicesSourceMode = 'DISABLED' | 'STORED' | 'SYNTHETIC' export interface IndicesStorage { type: IndicesStorageType @@ -13022,19 +13033,19 @@ export interface IndicesAddBlockIndicesBlockStatus { } export interface IndicesAddBlockRequest extends RequestBase { -/** A comma separated list of indices to add a block to */ +/** A comma-separated list or wildcard expression of index names used to limit the request. By default, you must explicitly name the indices you are adding blocks to. To allow the adding of blocks to indices with `_all`, `*`, or other wildcard expressions, change the `action.destructive_requires_name` setting to `false`. You can update this setting in the `elasticsearch.yml` file or by using the cluster update settings API. */ index: IndexName - /** The block to add (one of read, write, read_only or metadata) */ + /** The block type to add to the index. */ block: IndicesAddBlockIndicesBlockOptions - /** Whether to ignore if a wildcard indices expression resolves into no concrete indices. (This includes `_all` string or when no indices have been specified) */ + /** If `false`, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targeting `foo*,bar*` returns an error if an index starts with `foo` but no index starts with `bar`. */ allow_no_indices?: boolean - /** Whether to expand wildcard expression to concrete indices that are open, closed or both. */ + /** The type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. It supports comma-separated values, such as `open,hidden`. */ expand_wildcards?: ExpandWildcards - /** Whether specified concrete indices should be ignored when unavailable (missing or closed) */ + /** If `false`, the request returns an error if it targets a missing or closed index. */ ignore_unavailable?: boolean - /** Specify timeout for connection to master */ + /** The period to wait for the master node. If the master node is not available before the timeout expires, the request fails and returns an error. It can also be set to `-1` to indicate that the request should never timeout. */ master_timeout?: Duration - /** Explicit operation timeout */ + /** The period to wait for a response from all relevant nodes in the cluster after updating the cluster metadata. If no response is received before the timeout expires, the cluster metadata update still applies but the response will indicate that it was not completely acknowledged. It can also be set to `-1` to indicate that the request should never timeout. */ timeout?: Duration /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { index?: never, block?: never, allow_no_indices?: never, expand_wildcards?: never, ignore_unavailable?: never, master_timeout?: never, timeout?: never } @@ -14394,20 +14405,22 @@ export interface IndicesReloadSearchAnalyzersRequest extends RequestBase { export type IndicesReloadSearchAnalyzersResponse = IndicesReloadSearchAnalyzersReloadResult export interface IndicesResolveClusterRequest extends RequestBase { -/** Comma-separated name(s) or index pattern(s) of the indices, aliases, and data streams to resolve. Resources on remote clusters can be specified using the ``:`` syntax. */ - name: Names - /** If false, the request returns an error if any wildcard expression, index alias, or _all value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targeting foo*,bar* returns an error if an index starts with foo but no index starts with bar. */ +/** A comma-separated list of names or index patterns for the indices, aliases, and data streams to resolve. Resources on remote clusters can be specified using the ``:`` syntax. Index and cluster exclusions (e.g., `-cluster1:*`) are also supported. If no index expression is specified, information about all remote clusters configured on the local cluster is returned without doing any index matching */ + name?: Names + /** If false, the request returns an error if any wildcard expression, index alias, or `_all` value targets only missing or closed indices. This behavior applies even if the request targets other open indices. For example, a request targeting `foo*,bar*` returns an error if an index starts with `foo` but no index starts with `bar`. NOTE: This option is only supported when specifying an index expression. You will get an error if you specify index options to the `_resolve/cluster` API endpoint that takes no index expression. */ allow_no_indices?: boolean - /** Type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports comma-separated values, such as `open,hidden`. Valid values are: `all`, `open`, `closed`, `hidden`, `none`. */ + /** Type of index that wildcard patterns can match. If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams. Supports comma-separated values, such as `open,hidden`. Valid values are: `all`, `open`, `closed`, `hidden`, `none`. NOTE: This option is only supported when specifying an index expression. You will get an error if you specify index options to the `_resolve/cluster` API endpoint that takes no index expression. */ expand_wildcards?: ExpandWildcards - /** If true, concrete, expanded or aliased indices are ignored when frozen. Defaults to false. */ + /** If true, concrete, expanded, or aliased indices are ignored when frozen. NOTE: This option is only supported when specifying an index expression. You will get an error if you specify index options to the `_resolve/cluster` API endpoint that takes no index expression. */ ignore_throttled?: boolean - /** If false, the request returns an error if it targets a missing or closed index. Defaults to false. */ + /** If false, the request returns an error if it targets a missing or closed index. NOTE: This option is only supported when specifying an index expression. You will get an error if you specify index options to the `_resolve/cluster` API endpoint that takes no index expression. */ ignore_unavailable?: boolean + /** The maximum time to wait for remote clusters to respond. If a remote cluster does not respond within this timeout period, the API response will show the cluster as not connected and include an error message that the request timed out. The default timeout is unset and the query can take as long as the networking layer is configured to wait for remote clusters that are not responding (typically 30 seconds). */ + timeout?: Duration /** All values in `body` will be added to the request body. */ - body?: string | { [key: string]: any } & { name?: never, allow_no_indices?: never, expand_wildcards?: never, ignore_throttled?: never, ignore_unavailable?: never } + body?: string | { [key: string]: any } & { name?: never, allow_no_indices?: never, expand_wildcards?: never, ignore_throttled?: never, ignore_unavailable?: never, timeout?: never } /** All values in `querystring` will be added to the request querystring. */ - querystring?: { [key: string]: any } & { name?: never, allow_no_indices?: never, expand_wildcards?: never, ignore_throttled?: never, ignore_unavailable?: never } + querystring?: { [key: string]: any } & { name?: never, allow_no_indices?: never, expand_wildcards?: never, ignore_throttled?: never, ignore_unavailable?: never, timeout?: never } } export interface IndicesResolveClusterResolveClusterInfo { @@ -15066,11 +15079,11 @@ export interface InferenceTextEmbeddingResult { export interface InferenceDeleteRequest extends RequestBase { /** The task type */ task_type?: InferenceTaskType - /** The inference Id */ + /** The inference identifier. */ inference_id: Id - /** When true, the endpoint is not deleted, and a list of ingest processors which reference this endpoint is returned */ + /** When true, the endpoint is not deleted and a list of ingest processors which reference this endpoint is returned. */ dry_run?: boolean - /** When true, the inference endpoint is forcefully deleted even if it is still being used by ingest processors or semantic text fields */ + /** When true, the inference endpoint is forcefully deleted even if it is still being used by ingest processors or semantic text fields. */ force?: boolean /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { task_type?: never, inference_id?: never, dry_run?: never, force?: never } @@ -15096,17 +15109,17 @@ export interface InferenceGetResponse { } export interface InferenceInferenceRequest extends RequestBase { -/** The task type */ +/** The type of inference task that the model performs. */ task_type?: InferenceTaskType - /** The inference Id */ + /** The unique identifier for the inference endpoint. */ inference_id: Id - /** Specifies the amount of time to wait for the inference request to complete. */ + /** The amount of time to wait for the inference request to complete. */ timeout?: Duration - /** Query input, required for rerank task. Not required for other tasks. */ + /** The query input, which is required only for the `rerank` task. It is not required for other tasks. */ query?: string - /** Inference input. Either a string or an array of strings. */ + /** The text on which you want to perform the inference task. It can be a single string or an array. > info > Inference endpoints for the `completion` task type currently only support a single string as input. */ input: string | string[] - /** Optional task settings */ + /** Task settings for the individual inference request. These settings are specific to the task type you specified and override the task settings specified when initializing the service. */ task_settings?: InferenceTaskSettings /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { task_type?: never, inference_id?: never, timeout?: never, query?: never, input?: never, task_settings?: never } @@ -15759,9 +15772,9 @@ export interface IngestWeb { export interface IngestDeleteGeoipDatabaseRequest extends RequestBase { /** A comma-separated list of geoip database configurations to delete */ id: Ids - /** Period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error. */ + /** The period to wait for a connection to the master node. If no response is received before the timeout expires, the request fails and returns an error. */ master_timeout?: Duration - /** Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. */ + /** The period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. */ timeout?: Duration /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { id?: never, master_timeout?: never, timeout?: never } @@ -15839,7 +15852,7 @@ export interface IngestGetGeoipDatabaseDatabaseConfigurationMetadata { } export interface IngestGetGeoipDatabaseRequest extends RequestBase { -/** Comma-separated list of database configuration IDs to retrieve. Wildcard (`*`) expressions are supported. To get all database configurations, omit this parameter or use `*`. */ +/** A comma-separated list of database configuration IDs to retrieve. Wildcard (`*`) expressions are supported. To get all database configurations, omit this parameter or use `*`. */ id?: Ids /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { id?: never } @@ -15965,13 +15978,13 @@ export interface IngestPutPipelineRequest extends RequestBase { export type IngestPutPipelineResponse = AcknowledgedResponseBase export interface IngestSimulateRequest extends RequestBase { -/** Pipeline to test. If you don’t specify a `pipeline` in the request body, this parameter is required. */ +/** The pipeline to test. If you don't specify a `pipeline` in the request body, this parameter is required. */ id?: Id /** If `true`, the response includes output data for each processor in the executed pipeline. */ verbose?: boolean /** Sample documents to test in the pipeline. */ docs: IngestDocument[] - /** Pipeline to test. If you don’t specify the `pipeline` request path parameter, this parameter is required. If you specify both this and the request path parameter, the API only uses the request path parameter. */ + /** The pipeline to test. If you don't specify the `pipeline` request path parameter, this parameter is required. If you specify both this and the request path parameter, the API only uses the request path parameter. */ pipeline?: IngestPipeline /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { id?: never, verbose?: never, docs?: never, pipeline?: never } @@ -16001,9 +16014,9 @@ export type LicenseLicenseStatus = 'active' | 'valid' | 'invalid' | 'expired' export type LicenseLicenseType = 'missing' | 'trial' | 'basic' | 'standard' | 'dev' | 'silver' | 'gold' | 'platinum' | 'enterprise' export interface LicenseDeleteRequest extends RequestBase { -/** Period to wait for a connection to the master node. */ +/** The period to wait for a connection to the master node. */ master_timeout?: Duration - /** Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. */ + /** The period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. */ timeout?: Duration /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { master_timeout?: never, timeout?: never } @@ -16073,9 +16086,9 @@ export interface LicensePostAcknowledgement { export interface LicensePostRequest extends RequestBase { /** Specifies whether you acknowledge the license changes. */ acknowledge?: boolean - /** Period to wait for a connection to the master node. */ + /** The period to wait for a connection to the master node. */ master_timeout?: Duration - /** Period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. */ + /** The period to wait for a response. If no response is received before the timeout expires, the request fails and returns an error. */ timeout?: Duration license?: LicenseLicense /** A sequence of one or more JSON documents containing the license information. */ @@ -16216,6 +16229,8 @@ export interface MigrationDeprecationsResponse { data_streams: Record node_settings: MigrationDeprecationsDeprecation[] ml_settings: MigrationDeprecationsDeprecation[] + templates: Record + ilm_policies: Record } export interface MigrationGetFeatureUpgradeStatusMigrationFeature { @@ -20885,7 +20900,7 @@ export interface SearchApplicationSearchApplicationTemplate { } export interface SearchApplicationDeleteRequest extends RequestBase { -/** The name of the search application to delete */ +/** The name of the search application to delete. */ name: Name /** All values in `body` will be added to the request body. */ body?: string | { [key: string]: any } & { name?: never } @@ -23523,12 +23538,7 @@ export interface SnapshotRepositoryAnalyzeDetailsInfo { write_elapsed_nanos: DurationValue write_throttled: Duration write_throttled_nanos: DurationValue - writer_node: SnapshotRepositoryAnalyzeNodeInfo -} - -export interface SnapshotRepositoryAnalyzeNodeInfo { - id: Id - name: Name + writer_node: SnapshotRepositoryAnalyzeSnapshotNodeInfo } export interface SnapshotRepositoryAnalyzeReadBlobDetails { @@ -23538,7 +23548,7 @@ export interface SnapshotRepositoryAnalyzeReadBlobDetails { first_byte_time?: Duration first_byte_time_nanos: DurationValue found: boolean - node: SnapshotRepositoryAnalyzeNodeInfo + node: SnapshotRepositoryAnalyzeSnapshotNodeInfo throttled?: Duration throttled_nanos?: DurationValue } @@ -23594,7 +23604,7 @@ export interface SnapshotRepositoryAnalyzeResponse { blob_count: integer blob_path: string concurrency: integer - coordinating_node: SnapshotRepositoryAnalyzeNodeInfo + coordinating_node: SnapshotRepositoryAnalyzeSnapshotNodeInfo delete_elapsed: Duration delete_elapsed_nanos: DurationValue details: SnapshotRepositoryAnalyzeDetailsInfo @@ -23613,6 +23623,11 @@ export interface SnapshotRepositoryAnalyzeResponse { summary: SnapshotRepositoryAnalyzeSummaryInfo } +export interface SnapshotRepositoryAnalyzeSnapshotNodeInfo { + id: Id + name: Name +} + export interface SnapshotRepositoryAnalyzeSummaryInfo { read: SnapshotRepositoryAnalyzeReadSummaryInfo write: SnapshotRepositoryAnalyzeWriteSummaryInfo @@ -24843,15 +24858,15 @@ export type WatcherDay = 'sunday' | 'monday' | 'tuesday' | 'wednesday' | 'thursd export interface WatcherEmail { id?: Id - bcc?: string[] + bcc?: string | string[] body?: WatcherEmailBody - cc?: string[] + cc?: string | string[] from?: string priority?: WatcherEmailPriority - reply_to?: string[] + reply_to?: string | string[] sent_date?: DateTime subject: string - to: string[] + to: string | string[] attachments?: Record }