elasticsearch 9.2.0__py3-none-any.whl → 9.3.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (125) hide show
  1. elasticsearch/_async/client/__init__.py +108 -85
  2. elasticsearch/_async/client/async_search.py +7 -6
  3. elasticsearch/_async/client/autoscaling.py +15 -4
  4. elasticsearch/_async/client/cat.py +203 -10
  5. elasticsearch/_async/client/ccr.py +10 -10
  6. elasticsearch/_async/client/cluster.py +98 -66
  7. elasticsearch/_async/client/connector.py +42 -41
  8. elasticsearch/_async/client/dangling_indices.py +8 -12
  9. elasticsearch/_async/client/enrich.py +10 -10
  10. elasticsearch/_async/client/eql.py +17 -16
  11. elasticsearch/_async/client/esql.py +173 -24
  12. elasticsearch/_async/client/features.py +6 -6
  13. elasticsearch/_async/client/fleet.py +8 -8
  14. elasticsearch/_async/client/graph.py +3 -3
  15. elasticsearch/_async/client/ilm.py +18 -18
  16. elasticsearch/_async/client/indices.py +564 -149
  17. elasticsearch/_async/client/inference.py +374 -64
  18. elasticsearch/_async/client/ingest.py +9 -9
  19. elasticsearch/_async/client/license.py +5 -7
  20. elasticsearch/_async/client/logstash.py +4 -4
  21. elasticsearch/_async/client/migration.py +6 -6
  22. elasticsearch/_async/client/ml.py +132 -88
  23. elasticsearch/_async/client/monitoring.py +4 -3
  24. elasticsearch/_async/client/nodes.py +182 -20
  25. elasticsearch/_async/client/project.py +13 -4
  26. elasticsearch/_async/client/query_rules.py +16 -16
  27. elasticsearch/_async/client/rollup.py +21 -21
  28. elasticsearch/_async/client/search_application.py +19 -19
  29. elasticsearch/_async/client/searchable_snapshots.py +10 -10
  30. elasticsearch/_async/client/security.py +34 -10
  31. elasticsearch/_async/client/shutdown.py +15 -4
  32. elasticsearch/_async/client/simulate.py +4 -4
  33. elasticsearch/_async/client/slm.py +17 -17
  34. elasticsearch/_async/client/snapshot.py +21 -21
  35. elasticsearch/_async/client/sql.py +17 -16
  36. elasticsearch/_async/client/streams.py +6 -7
  37. elasticsearch/_async/client/synonyms.py +10 -10
  38. elasticsearch/_async/client/tasks.py +8 -8
  39. elasticsearch/_async/client/text_structure.py +16 -12
  40. elasticsearch/_async/client/transform.py +51 -12
  41. elasticsearch/_async/client/utils.py +4 -2
  42. elasticsearch/_async/client/watcher.py +26 -26
  43. elasticsearch/_async/client/xpack.py +6 -5
  44. elasticsearch/_sync/client/__init__.py +110 -85
  45. elasticsearch/_sync/client/async_search.py +7 -6
  46. elasticsearch/_sync/client/autoscaling.py +15 -4
  47. elasticsearch/_sync/client/cat.py +203 -10
  48. elasticsearch/_sync/client/ccr.py +10 -10
  49. elasticsearch/_sync/client/cluster.py +98 -66
  50. elasticsearch/_sync/client/connector.py +42 -41
  51. elasticsearch/_sync/client/dangling_indices.py +8 -12
  52. elasticsearch/_sync/client/enrich.py +10 -10
  53. elasticsearch/_sync/client/eql.py +17 -16
  54. elasticsearch/_sync/client/esql.py +173 -24
  55. elasticsearch/_sync/client/features.py +6 -6
  56. elasticsearch/_sync/client/fleet.py +8 -8
  57. elasticsearch/_sync/client/graph.py +3 -3
  58. elasticsearch/_sync/client/ilm.py +18 -18
  59. elasticsearch/_sync/client/indices.py +564 -149
  60. elasticsearch/_sync/client/inference.py +374 -64
  61. elasticsearch/_sync/client/ingest.py +9 -9
  62. elasticsearch/_sync/client/license.py +5 -7
  63. elasticsearch/_sync/client/logstash.py +4 -4
  64. elasticsearch/_sync/client/migration.py +6 -6
  65. elasticsearch/_sync/client/ml.py +132 -88
  66. elasticsearch/_sync/client/monitoring.py +4 -3
  67. elasticsearch/_sync/client/nodes.py +182 -20
  68. elasticsearch/_sync/client/project.py +13 -4
  69. elasticsearch/_sync/client/project_routing.py +264 -0
  70. elasticsearch/_sync/client/query_rules.py +16 -16
  71. elasticsearch/_sync/client/rollup.py +21 -21
  72. elasticsearch/_sync/client/search_application.py +19 -19
  73. elasticsearch/_sync/client/searchable_snapshots.py +10 -10
  74. elasticsearch/_sync/client/security.py +34 -10
  75. elasticsearch/_sync/client/shutdown.py +15 -4
  76. elasticsearch/_sync/client/simulate.py +4 -4
  77. elasticsearch/_sync/client/slm.py +17 -17
  78. elasticsearch/_sync/client/snapshot.py +21 -21
  79. elasticsearch/_sync/client/sql.py +17 -16
  80. elasticsearch/_sync/client/streams.py +6 -7
  81. elasticsearch/_sync/client/synonyms.py +10 -10
  82. elasticsearch/_sync/client/tasks.py +8 -8
  83. elasticsearch/_sync/client/text_structure.py +16 -12
  84. elasticsearch/_sync/client/transform.py +51 -12
  85. elasticsearch/_sync/client/utils.py +16 -2
  86. elasticsearch/_sync/client/watcher.py +26 -26
  87. elasticsearch/_sync/client/xpack.py +6 -5
  88. elasticsearch/_version.py +2 -2
  89. elasticsearch/dsl/__init__.py +4 -0
  90. elasticsearch/dsl/_async/document.py +4 -5
  91. elasticsearch/dsl/_async/index.py +1 -1
  92. elasticsearch/dsl/_async/search.py +2 -3
  93. elasticsearch/dsl/_sync/document.py +4 -5
  94. elasticsearch/dsl/_sync/index.py +1 -1
  95. elasticsearch/dsl/_sync/search.py +2 -3
  96. elasticsearch/dsl/aggs.py +9 -9
  97. elasticsearch/dsl/async_connections.py +1 -2
  98. elasticsearch/dsl/connections.py +1 -2
  99. elasticsearch/dsl/document_base.py +1 -1
  100. elasticsearch/dsl/field.py +90 -6
  101. elasticsearch/dsl/pydantic.py +1 -1
  102. elasticsearch/dsl/query.py +25 -2
  103. elasticsearch/dsl/response/__init__.py +2 -0
  104. elasticsearch/dsl/serializer.py +1 -2
  105. elasticsearch/dsl/types.py +63 -8
  106. elasticsearch/dsl/utils.py +12 -4
  107. elasticsearch/esql/esql.py +1 -1
  108. elasticsearch/esql/functions.py +926 -252
  109. elasticsearch/helpers/__init__.py +2 -0
  110. elasticsearch/helpers/actions.py +21 -0
  111. elasticsearch/helpers/vectorstore/__init__.py +7 -7
  112. elasticsearch/helpers/vectorstore/_async/_utils.py +1 -1
  113. elasticsearch/helpers/vectorstore/_async/embedding_service.py +2 -2
  114. elasticsearch/helpers/vectorstore/_async/strategies.py +3 -3
  115. elasticsearch/helpers/vectorstore/_async/vectorstore.py +8 -5
  116. elasticsearch/helpers/vectorstore/_sync/_utils.py +1 -1
  117. elasticsearch/helpers/vectorstore/_sync/embedding_service.py +2 -2
  118. elasticsearch/helpers/vectorstore/_sync/strategies.py +3 -3
  119. elasticsearch/helpers/vectorstore/_sync/vectorstore.py +8 -5
  120. {elasticsearch-9.2.0.dist-info → elasticsearch-9.3.0.dist-info}/METADATA +2 -1
  121. elasticsearch-9.3.0.dist-info/RECORD +169 -0
  122. {elasticsearch-9.2.0.dist-info → elasticsearch-9.3.0.dist-info}/WHEEL +1 -1
  123. elasticsearch-9.2.0.dist-info/RECORD +0 -168
  124. {elasticsearch-9.2.0.dist-info → elasticsearch-9.3.0.dist-info}/licenses/LICENSE +0 -0
  125. {elasticsearch-9.2.0.dist-info → elasticsearch-9.3.0.dist-info}/licenses/NOTICE +0 -0
@@ -89,8 +89,8 @@ class SqlClient(NamespacedClient):
89
89
  """
90
90
  .. raw:: html
91
91
 
92
- <p>Delete an async SQL search.
93
- Delete an async SQL search or a stored synchronous SQL search.
92
+ <p>Delete an async SQL search.</p>
93
+ <p>Delete an async SQL search or a stored synchronous SQL search.
94
94
  If the search is still running, the API cancels it.</p>
95
95
  <p>If the Elasticsearch security features are enabled, only the following users can use this API to delete a search:</p>
96
96
  <ul>
@@ -145,8 +145,8 @@ class SqlClient(NamespacedClient):
145
145
  """
146
146
  .. raw:: html
147
147
 
148
- <p>Get async SQL search results.
149
- Get the current status and available results for an async SQL search or stored synchronous SQL search.</p>
148
+ <p>Get async SQL search results.</p>
149
+ <p>Get the current status and available results for an async SQL search or stored synchronous SQL search.</p>
150
150
  <p>If the Elasticsearch security features are enabled, only the user who first submitted the SQL search can retrieve the search using this API.</p>
151
151
 
152
152
 
@@ -208,8 +208,8 @@ class SqlClient(NamespacedClient):
208
208
  """
209
209
  .. raw:: html
210
210
 
211
- <p>Get the async SQL search status.
212
- Get the current status of an async SQL search or a stored synchronous SQL search.</p>
211
+ <p>Get the async SQL search status.</p>
212
+ <p>Get the current status of an async SQL search or a stored synchronous SQL search.</p>
213
213
 
214
214
 
215
215
  `<https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-sql-get-async-status>`_
@@ -253,6 +253,7 @@ class SqlClient(NamespacedClient):
253
253
  "keep_on_completion",
254
254
  "page_timeout",
255
255
  "params",
256
+ "project_routing",
256
257
  "query",
257
258
  "request_timeout",
258
259
  "runtime_mappings",
@@ -298,8 +299,8 @@ class SqlClient(NamespacedClient):
298
299
  """
299
300
  .. raw:: html
300
301
 
301
- <p>Get SQL search results.
302
- Run an SQL request.</p>
302
+ <p>Get SQL search results.</p>
303
+ <p>Run an SQL request.</p>
303
304
 
304
305
 
305
306
  `<https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-sql-query>`_
@@ -333,10 +334,10 @@ class SqlClient(NamespacedClient):
333
334
  is no longer available. Subsequent scroll requests prolong the lifetime of
334
335
  the scroll cursor by the duration of `page_timeout` in the scroll request.
335
336
  :param params: The values for parameters in the query.
336
- :param project_routing: Specifies a subset of projects to target for the search
337
- using project metadata tags in a subset of Lucene query syntax. Allowed Lucene
338
- queries: the _alias tag and a single value (possibly wildcarded). Examples:
339
- _alias:my-project _alias:_origin _alias:*pr* Supported in serverless only.
337
+ :param project_routing: Specifies a subset of projects to target using project
338
+ metadata tags in a subset of Lucene query syntax. Allowed Lucene queries:
339
+ the _alias tag and a single value (possibly wildcarded). Examples: _alias:my-project
340
+ _alias:_origin _alias:*pr* Supported in serverless only.
340
341
  :param query: The SQL query to run.
341
342
  :param request_timeout: The timeout before the request fails.
342
343
  :param runtime_mappings: One or more runtime fields for the search request. These
@@ -362,8 +363,6 @@ class SqlClient(NamespacedClient):
362
363
  __query["human"] = human
363
364
  if pretty is not None:
364
365
  __query["pretty"] = pretty
365
- if project_routing is not None:
366
- __query["project_routing"] = project_routing
367
366
  if not __body:
368
367
  if allow_partial_search_results is not None:
369
368
  __body["allow_partial_search_results"] = allow_partial_search_results
@@ -389,6 +388,8 @@ class SqlClient(NamespacedClient):
389
388
  __body["page_timeout"] = page_timeout
390
389
  if params is not None:
391
390
  __body["params"] = params
391
+ if project_routing is not None:
392
+ __body["project_routing"] = project_routing
392
393
  if query is not None:
393
394
  __body["query"] = query
394
395
  if request_timeout is not None:
@@ -429,8 +430,8 @@ class SqlClient(NamespacedClient):
429
430
  """
430
431
  .. raw:: html
431
432
 
432
- <p>Translate SQL into Elasticsearch queries.
433
- Translate an SQL search into a search API request containing Query DSL.
433
+ <p>Translate SQL into Elasticsearch queries.</p>
434
+ <p>Translate an SQL search into a search API request containing Query DSL.
434
435
  It accepts the same request body parameters as the SQL search API, excluding <code>cursor</code>.</p>
435
436
 
436
437
 
@@ -15,7 +15,6 @@
15
15
  # specific language governing permissions and limitations
16
16
  # under the License.
17
17
 
18
-
19
18
  import typing as t
20
19
 
21
20
  from elastic_transport import ObjectApiResponse, TextApiResponse
@@ -23,15 +22,15 @@ from elastic_transport import ObjectApiResponse, TextApiResponse
23
22
  from ._base import NamespacedClient
24
23
  from .utils import (
25
24
  Stability,
25
+ _availability_warning,
26
26
  _rewrite_parameters,
27
- _stability_warning,
28
27
  )
29
28
 
30
29
 
31
30
  class StreamsClient(NamespacedClient):
32
31
 
33
32
  @_rewrite_parameters()
34
- @_stability_warning(Stability.EXPERIMENTAL)
33
+ @_availability_warning(Stability.EXPERIMENTAL)
35
34
  async def logs_disable(
36
35
  self,
37
36
  *,
@@ -72,7 +71,7 @@ class StreamsClient(NamespacedClient):
72
71
  __query["pretty"] = pretty
73
72
  if timeout is not None:
74
73
  __query["timeout"] = timeout
75
- __headers = {"accept": "application/json,text/plain"}
74
+ __headers = {"accept": "text/plain,application/json"}
76
75
  return await self.perform_request( # type: ignore[return-value]
77
76
  "POST",
78
77
  __path,
@@ -83,7 +82,7 @@ class StreamsClient(NamespacedClient):
83
82
  )
84
83
 
85
84
  @_rewrite_parameters()
86
- @_stability_warning(Stability.EXPERIMENTAL)
85
+ @_availability_warning(Stability.EXPERIMENTAL)
87
86
  async def logs_enable(
88
87
  self,
89
88
  *,
@@ -127,7 +126,7 @@ class StreamsClient(NamespacedClient):
127
126
  __query["pretty"] = pretty
128
127
  if timeout is not None:
129
128
  __query["timeout"] = timeout
130
- __headers = {"accept": "application/json,text/plain"}
129
+ __headers = {"accept": "text/plain,application/json"}
131
130
  return await self.perform_request( # type: ignore[return-value]
132
131
  "POST",
133
132
  __path,
@@ -138,7 +137,7 @@ class StreamsClient(NamespacedClient):
138
137
  )
139
138
 
140
139
  @_rewrite_parameters()
141
- @_stability_warning(Stability.EXPERIMENTAL)
140
+ @_availability_warning(Stability.EXPERIMENTAL)
142
141
  async def status(
143
142
  self,
144
143
  *,
@@ -95,8 +95,8 @@ class SynonymsClient(NamespacedClient):
95
95
  """
96
96
  .. raw:: html
97
97
 
98
- <p>Delete a synonym rule.
99
- Delete a synonym rule from a synonym set.</p>
98
+ <p>Delete a synonym rule.</p>
99
+ <p>Delete a synonym rule from a synonym set.</p>
100
100
 
101
101
 
102
102
  `<https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-delete-synonym-rule>`_
@@ -204,8 +204,8 @@ class SynonymsClient(NamespacedClient):
204
204
  """
205
205
  .. raw:: html
206
206
 
207
- <p>Get a synonym rule.
208
- Get a synonym rule from a synonym set.</p>
207
+ <p>Get a synonym rule.</p>
208
+ <p>Get a synonym rule from a synonym set.</p>
209
209
 
210
210
 
211
211
  `<https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-get-synonym-rule>`_
@@ -257,8 +257,8 @@ class SynonymsClient(NamespacedClient):
257
257
  """
258
258
  .. raw:: html
259
259
 
260
- <p>Get all synonym sets.
261
- Get a summary of all defined synonym sets.</p>
260
+ <p>Get all synonym sets.</p>
261
+ <p>Get a summary of all defined synonym sets.</p>
262
262
 
263
263
 
264
264
  `<https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-synonyms-get-synonym>`_
@@ -311,8 +311,8 @@ class SynonymsClient(NamespacedClient):
311
311
  """
312
312
  .. raw:: html
313
313
 
314
- <p>Create or update a synonym set.
315
- Synonyms sets are limited to a maximum of 10,000 synonym rules per set.
314
+ <p>Create or update a synonym set.</p>
315
+ <p>Synonyms sets are limited to a maximum of 10,000 synonym rules per set.
316
316
  If you need to manage more synonym rules, you can create multiple synonym sets.</p>
317
317
  <p>When an existing synonyms set is updated, the search analyzers that use the synonyms set are reloaded automatically for all indices.
318
318
  This is equivalent to invoking the reload search analyzers API for all indices that use the synonyms set.</p>
@@ -378,8 +378,8 @@ class SynonymsClient(NamespacedClient):
378
378
  """
379
379
  .. raw:: html
380
380
 
381
- <p>Create or update a synonym rule.
382
- Create or update a synonym rule in a synonym set.</p>
381
+ <p>Create or update a synonym rule.</p>
382
+ <p>Create or update a synonym rule in a synonym set.</p>
383
383
  <p>If any of the synonym rules included is invalid, the API returns an error.</p>
384
384
  <p>When you update a synonym rule, all analyzers using the synonyms set will be reloaded automatically to reflect the new rule.</p>
385
385
 
@@ -23,16 +23,16 @@ from ._base import NamespacedClient
23
23
  from .utils import (
24
24
  SKIP_IN_PATH,
25
25
  Stability,
26
+ _availability_warning,
26
27
  _quote,
27
28
  _rewrite_parameters,
28
- _stability_warning,
29
29
  )
30
30
 
31
31
 
32
32
  class TasksClient(NamespacedClient):
33
33
 
34
34
  @_rewrite_parameters()
35
- @_stability_warning(Stability.EXPERIMENTAL)
35
+ @_availability_warning(Stability.EXPERIMENTAL)
36
36
  async def cancel(
37
37
  self,
38
38
  *,
@@ -106,7 +106,7 @@ class TasksClient(NamespacedClient):
106
106
  )
107
107
 
108
108
  @_rewrite_parameters()
109
- @_stability_warning(Stability.EXPERIMENTAL)
109
+ @_availability_warning(Stability.EXPERIMENTAL)
110
110
  async def get(
111
111
  self,
112
112
  *,
@@ -121,8 +121,8 @@ class TasksClient(NamespacedClient):
121
121
  """
122
122
  .. raw:: html
123
123
 
124
- <p>Get task information.
125
- Get information about a task currently running in the cluster.</p>
124
+ <p>Get task information.</p>
125
+ <p>Get information about a task currently running in the cluster.</p>
126
126
  <p>WARNING: The task management API is new and should still be considered a beta feature.
127
127
  The API may change in ways that are not backwards compatible.</p>
128
128
  <p>If the task identifier is not found, a 404 response code indicates that there are no resources that match the request.</p>
@@ -164,7 +164,7 @@ class TasksClient(NamespacedClient):
164
164
  )
165
165
 
166
166
  @_rewrite_parameters()
167
- @_stability_warning(Stability.EXPERIMENTAL)
167
+ @_availability_warning(Stability.EXPERIMENTAL)
168
168
  async def list(
169
169
  self,
170
170
  *,
@@ -185,8 +185,8 @@ class TasksClient(NamespacedClient):
185
185
  """
186
186
  .. raw:: html
187
187
 
188
- <p>Get all tasks.
189
- Get information about the tasks currently running on one or more nodes in the cluster.</p>
188
+ <p>Get all tasks.</p>
189
+ <p>Get information about the tasks currently running on one or more nodes in the cluster.</p>
190
190
  <p>WARNING: The task management API is new and should still be considered a beta feature.
191
191
  The API may change in ways that are not backwards compatible.</p>
192
192
  <p><strong>Identifying running tasks</strong></p>
@@ -31,7 +31,7 @@ class TextStructureClient(NamespacedClient):
31
31
  *,
32
32
  field: str,
33
33
  index: str,
34
- column_names: t.Optional[str] = None,
34
+ column_names: t.Optional[t.Union[str, t.Sequence[str]]] = None,
35
35
  delimiter: t.Optional[str] = None,
36
36
  documents_to_sample: t.Optional[int] = None,
37
37
  ecs_compatibility: t.Optional[t.Union[str, t.Literal["disabled", "v1"]]] = None,
@@ -55,8 +55,8 @@ class TextStructureClient(NamespacedClient):
55
55
  """
56
56
  .. raw:: html
57
57
 
58
- <p>Find the structure of a text field.
59
- Find the structure of a text field in an Elasticsearch index.</p>
58
+ <p>Find the structure of a text field.</p>
59
+ <p>Find the structure of a text field in an Elasticsearch index.</p>
60
60
  <p>This API provides a starting point for extracting further information from log messages already ingested into Elasticsearch.
61
61
  For example, if you have ingested data into a very simple index that has just <code>@timestamp</code> and message fields, you can use this API to see what common structure exists in the message field.</p>
62
62
  <p>The response from the API contains:</p>
@@ -217,7 +217,7 @@ class TextStructureClient(NamespacedClient):
217
217
  self,
218
218
  *,
219
219
  messages: t.Optional[t.Sequence[str]] = None,
220
- column_names: t.Optional[str] = None,
220
+ column_names: t.Optional[t.Union[str, t.Sequence[str]]] = None,
221
221
  delimiter: t.Optional[str] = None,
222
222
  ecs_compatibility: t.Optional[t.Union[str, t.Literal["disabled", "v1"]]] = None,
223
223
  error_trace: t.Optional[bool] = None,
@@ -241,8 +241,8 @@ class TextStructureClient(NamespacedClient):
241
241
  """
242
242
  .. raw:: html
243
243
 
244
- <p>Find the structure of text messages.
245
- Find the structure of a list of text messages.
244
+ <p>Find the structure of text messages.</p>
245
+ <p>Find the structure of a list of text messages.
246
246
  The messages must contain data that is suitable to be ingested into Elasticsearch.</p>
247
247
  <p>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.
248
248
  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.</p>
@@ -398,11 +398,15 @@ class TextStructureClient(NamespacedClient):
398
398
  text_files: t.Optional[t.Sequence[t.Any]] = None,
399
399
  body: t.Optional[t.Sequence[t.Any]] = None,
400
400
  charset: t.Optional[str] = None,
401
- column_names: t.Optional[str] = None,
401
+ column_names: t.Optional[t.Union[str, t.Sequence[str]]] = None,
402
402
  delimiter: t.Optional[str] = None,
403
403
  ecs_compatibility: t.Optional[str] = None,
404
404
  explain: t.Optional[bool] = None,
405
- format: t.Optional[str] = None,
405
+ format: t.Optional[
406
+ t.Union[
407
+ str, t.Literal["delimited", "ndjson", "semi_structured_text", "xml"]
408
+ ]
409
+ ] = None,
406
410
  grok_pattern: t.Optional[str] = None,
407
411
  has_header_row: t.Optional[bool] = None,
408
412
  line_merge_size_limit: t.Optional[int] = None,
@@ -416,8 +420,8 @@ class TextStructureClient(NamespacedClient):
416
420
  """
417
421
  .. raw:: html
418
422
 
419
- <p>Find the structure of a text file.
420
- The text file must contain data that is suitable to be ingested into Elasticsearch.</p>
423
+ <p>Find the structure of a text file.</p>
424
+ <p>The text file must contain data that is suitable to be ingested into Elasticsearch.</p>
421
425
  <p>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.
422
426
  Unlike other Elasticsearch endpoints, the data that is posted to this endpoint does not need to be UTF-8 encoded and in JSON format.
423
427
  It must, however, be text; binary text formats are not currently supported.
@@ -615,8 +619,8 @@ class TextStructureClient(NamespacedClient):
615
619
  """
616
620
  .. raw:: html
617
621
 
618
- <p>Test a Grok pattern.
619
- Test a Grok pattern on one or more lines of text.
622
+ <p>Test a Grok pattern.</p>
623
+ <p>Test a Grok pattern on one or more lines of text.
620
624
  The API indicates whether the lines match the pattern together with the offsets and lengths of the matched substrings.</p>
621
625
 
622
626
 
@@ -85,6 +85,45 @@ class TransformClient(NamespacedClient):
85
85
  path_parts=__path_parts,
86
86
  )
87
87
 
88
+ @_rewrite_parameters()
89
+ async def get_node_stats(
90
+ self,
91
+ *,
92
+ error_trace: t.Optional[bool] = None,
93
+ filter_path: t.Optional[t.Union[str, t.Sequence[str]]] = None,
94
+ human: t.Optional[bool] = None,
95
+ pretty: t.Optional[bool] = None,
96
+ ) -> ObjectApiResponse[t.Any]:
97
+ """
98
+ .. raw:: html
99
+
100
+ <p>Get node stats.</p>
101
+ <p>Get per-node information about transform usage.</p>
102
+
103
+
104
+ `<https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-get-node-stats>`_
105
+ """
106
+ __path_parts: t.Dict[str, str] = {}
107
+ __path = "/_transform/_node_stats"
108
+ __query: t.Dict[str, t.Any] = {}
109
+ if error_trace is not None:
110
+ __query["error_trace"] = error_trace
111
+ if filter_path is not None:
112
+ __query["filter_path"] = filter_path
113
+ if human is not None:
114
+ __query["human"] = human
115
+ if pretty is not None:
116
+ __query["pretty"] = pretty
117
+ __headers = {"accept": "application/json"}
118
+ return await self.perform_request( # type: ignore[return-value]
119
+ "GET",
120
+ __path,
121
+ params=__query,
122
+ headers=__headers,
123
+ endpoint_id="transform.get_node_stats",
124
+ path_parts=__path_parts,
125
+ )
126
+
88
127
  @_rewrite_parameters(
89
128
  parameter_aliases={"from": "from_"},
90
129
  )
@@ -104,8 +143,8 @@ class TransformClient(NamespacedClient):
104
143
  """
105
144
  .. raw:: html
106
145
 
107
- <p>Get transforms.
108
- Get configuration information for transforms.</p>
146
+ <p>Get transforms.</p>
147
+ <p>Get configuration information for transforms.</p>
109
148
 
110
149
 
111
150
  `<https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-get-transform>`_
@@ -262,8 +301,8 @@ class TransformClient(NamespacedClient):
262
301
  """
263
302
  .. raw:: html
264
303
 
265
- <p>Preview a transform.
266
- Generates a preview of the results that you will get when you create a transform with the same configuration.</p>
304
+ <p>Preview a transform.</p>
305
+ <p>Generates a preview of the results that you will get when you create a transform with the same configuration.</p>
267
306
  <p>It returns a maximum of 100 results. The calculations are based on all the current data in the source index. It also
268
307
  generates a list of mappings and settings for the destination index. These values are determined based on the field
269
308
  types of the source index and the transform aggregations.</p>
@@ -386,8 +425,8 @@ class TransformClient(NamespacedClient):
386
425
  """
387
426
  .. raw:: html
388
427
 
389
- <p>Create a transform.
390
- Creates a transform.</p>
428
+ <p>Create a transform.</p>
429
+ <p>Creates a transform.</p>
391
430
  <p>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
392
431
  a data frame). The ID for each document in the data frame is generated from a hash of the entity, so there is a
393
432
  unique row per entity.</p>
@@ -616,8 +655,8 @@ class TransformClient(NamespacedClient):
616
655
  """
617
656
  .. raw:: html
618
657
 
619
- <p>Set upgrade_mode for transform indices.
620
- Sets a cluster wide upgrade_mode setting that prepares transform
658
+ <p>Set upgrade_mode for transform indices.</p>
659
+ <p>Sets a cluster wide upgrade_mode setting that prepares transform
621
660
  indices for an upgrade.
622
661
  When upgrading your cluster, in some circumstances you must restart your
623
662
  nodes and reindex your transform indices. In those circumstances,
@@ -749,8 +788,8 @@ class TransformClient(NamespacedClient):
749
788
  """
750
789
  .. raw:: html
751
790
 
752
- <p>Stop transforms.
753
- Stops one or more transforms.</p>
791
+ <p>Stop transforms.</p>
792
+ <p>Stops one or more transforms.</p>
754
793
 
755
794
 
756
795
  `<https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-stop-transform>`_
@@ -846,8 +885,8 @@ class TransformClient(NamespacedClient):
846
885
  """
847
886
  .. raw:: html
848
887
 
849
- <p>Update a transform.
850
- Updates certain properties of a transform.</p>
888
+ <p>Update a transform.</p>
889
+ <p>Updates certain properties of a transform.</p>
851
890
  <p>All updated properties except <code>description</code> do not take effect until after the transform starts the next checkpoint,
852
891
  thus there is data consistency in each checkpoint. To use this API, you must have <code>read</code> and <code>view_index_metadata</code>
853
892
  privileges for the source indices. You must also have <code>index</code> and <code>read</code> privileges for the destination index. When
@@ -21,11 +21,12 @@ from ..._sync.client.utils import (
21
21
  CLIENT_META_SERVICE,
22
22
  SKIP_IN_PATH,
23
23
  Stability,
24
+ Visibility,
25
+ _availability_warning,
24
26
  _base64_auth_header,
25
27
  _quote,
26
28
  _quote_query,
27
29
  _rewrite_parameters,
28
- _stability_warning,
29
30
  client_node_configs,
30
31
  is_requests_http_auth,
31
32
  is_requests_node_class,
@@ -40,9 +41,10 @@ __all__ = [
40
41
  "_TYPE_HOSTS",
41
42
  "SKIP_IN_PATH",
42
43
  "Stability",
44
+ "Visibility",
43
45
  "client_node_configs",
44
46
  "_rewrite_parameters",
45
- "_stability_warning",
47
+ "_availability_warning",
46
48
  "is_requests_http_auth",
47
49
  "is_requests_node_class",
48
50
  ]
@@ -39,8 +39,8 @@ class WatcherClient(NamespacedClient):
39
39
  """
40
40
  .. raw:: html
41
41
 
42
- <p>Acknowledge a watch.
43
- Acknowledging a watch enables you to manually throttle the execution of the watch's actions.</p>
42
+ <p>Acknowledge a watch.</p>
43
+ <p>Acknowledging a watch enables you to manually throttle the execution of the watch's actions.</p>
44
44
  <p>The acknowledgement state of an action is stored in the <code>status.actions.&lt;id&gt;.ack.state</code> structure.</p>
45
45
  <p>IMPORTANT: If the specified watch is currently being executed, this API will return an error
46
46
  The reason for this behavior is to prevent overwriting the watch status from a watch execution.</p>
@@ -101,8 +101,8 @@ class WatcherClient(NamespacedClient):
101
101
  """
102
102
  .. raw:: html
103
103
 
104
- <p>Activate a watch.
105
- A watch can be either active or inactive.</p>
104
+ <p>Activate a watch.</p>
105
+ <p>A watch can be either active or inactive.</p>
106
106
 
107
107
 
108
108
  `<https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-activate-watch>`_
@@ -145,8 +145,8 @@ class WatcherClient(NamespacedClient):
145
145
  """
146
146
  .. raw:: html
147
147
 
148
- <p>Deactivate a watch.
149
- A watch can be either active or inactive.</p>
148
+ <p>Deactivate a watch.</p>
149
+ <p>A watch can be either active or inactive.</p>
150
150
 
151
151
 
152
152
  `<https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-deactivate-watch>`_
@@ -189,8 +189,8 @@ class WatcherClient(NamespacedClient):
189
189
  """
190
190
  .. raw:: html
191
191
 
192
- <p>Delete a watch.
193
- When the watch is removed, the document representing the watch in the <code>.watches</code> index is gone and it will never be run again.</p>
192
+ <p>Delete a watch.</p>
193
+ <p>When the watch is removed, the document representing the watch in the <code>.watches</code> index is gone and it will never be run again.</p>
194
194
  <p>Deleting a watch does not delete any watch execution records related to this watch from the watch history.</p>
195
195
  <p>IMPORTANT: Deleting a watch must be done by using only this API.
196
196
  Do not delete the watch directly from the <code>.watches</code> index using the Elasticsearch delete document API
@@ -266,8 +266,8 @@ class WatcherClient(NamespacedClient):
266
266
  """
267
267
  .. raw:: html
268
268
 
269
- <p>Run a watch.
270
- 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.</p>
269
+ <p>Run a watch.</p>
270
+ <p>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.</p>
271
271
  <p>For testing and debugging purposes, you also have fine-grained control on how the watch runs.
272
272
  You can run the watch without running all of its actions or alternatively by simulating them.
273
273
  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.</p>
@@ -362,8 +362,8 @@ class WatcherClient(NamespacedClient):
362
362
  """
363
363
  .. raw:: html
364
364
 
365
- <p>Get Watcher index settings.
366
- Get settings for the Watcher internal index (<code>.watches</code>).
365
+ <p>Get Watcher index settings.</p>
366
+ <p>Get settings for the Watcher internal index (<code>.watches</code>).
367
367
  Only a subset of settings are shown, for example <code>index.auto_expand_replicas</code> and <code>index.number_of_replicas</code>.</p>
368
368
 
369
369
 
@@ -476,8 +476,8 @@ class WatcherClient(NamespacedClient):
476
476
  """
477
477
  .. raw:: html
478
478
 
479
- <p>Create or update a watch.
480
- When a watch is registered, a new document that represents the watch is added to the <code>.watches</code> index and its trigger is immediately registered with the relevant trigger engine.
479
+ <p>Create or update a watch.</p>
480
+ <p>When a watch is registered, a new document that represents the watch is added to the <code>.watches</code> index and its trigger is immediately registered with the relevant trigger engine.
481
481
  Typically for the <code>schedule</code> trigger, the scheduler is the trigger engine.</p>
482
482
  <p>IMPORTANT: You must use Kibana or this API to create a watch.
483
483
  Do not add a watch directly to the <code>.watches</code> index by using the Elasticsearch index API.
@@ -494,9 +494,9 @@ class WatcherClient(NamespacedClient):
494
494
  :param active: The initial state of the watch. The default value is `true`, which
495
495
  means the watch is active by default.
496
496
  :param condition: The condition that defines if the actions should be run.
497
- :param if_primary_term: only update the watch if the last operation that has
497
+ :param if_primary_term: Only update the watch if the last operation that has
498
498
  changed the watch has the specified primary term
499
- :param if_seq_no: only update the watch if the last operation that has changed
499
+ :param if_seq_no: Only update the watch if the last operation that has changed
500
500
  the watch has the specified sequence number
501
501
  :param input: The input that defines the input that loads the data for the watch.
502
502
  :param metadata: Metadata JSON that will be copied into the history entries.
@@ -591,8 +591,8 @@ class WatcherClient(NamespacedClient):
591
591
  """
592
592
  .. raw:: html
593
593
 
594
- <p>Query watches.
595
- Get all registered watches in a paginated manner and optionally filter watches by a query.</p>
594
+ <p>Query watches.</p>
595
+ <p>Get all registered watches in a paginated manner and optionally filter watches by a query.</p>
596
596
  <p>Note that only the <code>_id</code> and <code>metadata.*</code> fields are queryable or sortable.</p>
597
597
 
598
598
 
@@ -667,8 +667,8 @@ class WatcherClient(NamespacedClient):
667
667
  """
668
668
  .. raw:: html
669
669
 
670
- <p>Start the watch service.
671
- Start the Watcher service if it is not already running.</p>
670
+ <p>Start the watch service.</p>
671
+ <p>Start the Watcher service if it is not already running.</p>
672
672
 
673
673
 
674
674
  `<https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-start>`_
@@ -732,8 +732,8 @@ class WatcherClient(NamespacedClient):
732
732
  """
733
733
  .. raw:: html
734
734
 
735
- <p>Get Watcher statistics.
736
- This API always returns basic metrics.
735
+ <p>Get Watcher statistics.</p>
736
+ <p>This API always returns basic metrics.
737
737
  You retrieve more metrics by using the metric parameter.</p>
738
738
 
739
739
 
@@ -784,8 +784,8 @@ class WatcherClient(NamespacedClient):
784
784
  """
785
785
  .. raw:: html
786
786
 
787
- <p>Stop the watch service.
788
- Stop the Watcher service if it is running.</p>
787
+ <p>Stop the watch service.</p>
788
+ <p>Stop the Watcher service if it is running.</p>
789
789
 
790
790
 
791
791
  `<https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-stop>`_
@@ -840,8 +840,8 @@ class WatcherClient(NamespacedClient):
840
840
  """
841
841
  .. raw:: html
842
842
 
843
- <p>Update Watcher index settings.
844
- Update settings for the Watcher internal index (<code>.watches</code>).
843
+ <p>Update Watcher index settings.</p>
844
+ <p>Update settings for the Watcher internal index (<code>.watches</code>).
845
845
  Only a subset of settings can be modified.
846
846
  This includes <code>index.auto_expand_replicas</code>, <code>index.number_of_replicas</code>, <code>index.routing.allocation.exclude.*</code>,
847
847
  <code>index.routing.allocation.include.*</code> and <code>index.routing.allocation.require.*</code>.
@@ -45,8 +45,8 @@ class XPackClient(NamespacedClient):
45
45
  """
46
46
  .. raw:: html
47
47
 
48
- <p>Get information.
49
- The information provided by the API includes:</p>
48
+ <p>Get information.</p>
49
+ <p>The information provided by the API includes:</p>
50
50
  <ul>
51
51
  <li>Build information including the build number and timestamp.</li>
52
52
  <li>License information about the currently installed license.</li>
@@ -56,7 +56,8 @@ class XPackClient(NamespacedClient):
56
56
 
57
57
  `<https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-info>`_
58
58
 
59
- :param accept_enterprise: If this param is used it must be set to true
59
+ :param accept_enterprise: If used, this otherwise ignored parameter must be set
60
+ to true
60
61
  :param categories: A comma-separated list of the information categories to include
61
62
  in the response. For example, `build,license,features`.
62
63
  """
@@ -98,8 +99,8 @@ class XPackClient(NamespacedClient):
98
99
  """
99
100
  .. raw:: html
100
101
 
101
- <p>Get usage information.
102
- Get information about the features that are currently enabled and available under the current license.
102
+ <p>Get usage information.</p>
103
+ <p>Get information about the features that are currently enabled and available under the current license.
103
104
  The API also provides some usage statistics.</p>
104
105
 
105
106