Skip to content

Commit b29e11b

Browse files
Auto-generated API code
1 parent f0724ad commit b29e11b

File tree

6 files changed

+270
-211
lines changed

6 files changed

+270
-211
lines changed

docs/reference.asciidoc

Lines changed: 74 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -2321,18 +2321,6 @@ client.enrich.putPolicy({ name })
23212321
** *`match` (Optional, { enrich_fields, indices, match_field, query, name, elasticsearch_version })*: Matches enrich data to incoming documents based on a `term` query.
23222322
** *`range` (Optional, { enrich_fields, indices, match_field, query, name, elasticsearch_version })*: Matches a number, date, or IP address in incoming documents to a range in the enrich index based on a `term` query.
23232323

2324-
[discrete]
2325-
==== stats
2326-
Get enrich stats.
2327-
Returns enrich coordinator statistics and information about enrich policies that are currently executing.
2328-
2329-
{ref}/enrich-stats-api.html[Endpoint documentation]
2330-
[source,ts]
2331-
----
2332-
client.enrich.stats()
2333-
----
2334-
2335-
23362324
[discrete]
23372325
=== eql
23382326
[discrete]
@@ -2646,26 +2634,6 @@ If no response is received before the timeout expires, the request fails and ret
26462634
** *`timeout` (Optional, string | -1 | 0)*: Period to wait for a response.
26472635
If no response is received before the timeout expires, the request fails and returns an error.
26482636

2649-
[discrete]
2650-
==== delete_data_lifecycle
2651-
Delete data stream lifecycles.
2652-
Removes the data stream lifecycle from a data stream, rendering it not managed by the data stream lifecycle.
2653-
2654-
{ref}/data-streams-delete-lifecycle.html[Endpoint documentation]
2655-
[source,ts]
2656-
----
2657-
client.indices.deleteDataLifecycle({ name })
2658-
----
2659-
2660-
[discrete]
2661-
==== Arguments
2662-
2663-
* *Request (object):*
2664-
** *`name` (string | string[])*: A list of data streams of which the data stream lifecycle will be deleted; use `*` to get all data streams
2665-
** *`expand_wildcards` (Optional, Enum("all" | "open" | "closed" | "hidden" | "none") | Enum("all" | "open" | "closed" | "hidden" | "none")[])*: Whether wildcard expressions should get expanded to open or closed indices (default: open)
2666-
** *`master_timeout` (Optional, string | -1 | 0)*: Specify timeout for connection to master
2667-
** *`timeout` (Optional, string | -1 | 0)*: Explicit timestamp for the document
2668-
26692637
[discrete]
26702638
==== delete_data_stream
26712639
Delete data streams.
@@ -3129,7 +3097,7 @@ client.indices.putIndexTemplate({ name })
31293097
Component templates are merged in the order specified, meaning that the last component template specified has the highest precedence.
31303098
** *`template` (Optional, { aliases, mappings, settings, lifecycle })*: Template to be applied.
31313099
It may optionally include an `aliases`, `mappings`, or `settings` configuration.
3132-
** *`data_stream` (Optional, { hidden })*: If this object is included, the template is used to create data streams and their backing indices.
3100+
** *`data_stream` (Optional, { hidden, allow_custom_routing })*: If this object is included, the template is used to create data streams and their backing indices.
31333101
Supports an empty object.
31343102
Data streams require a matching index template with a `data_stream` object.
31353103
** *`priority` (Optional, number)*: Priority to determine index template precedence when a new data stream or index is created.
@@ -3241,39 +3209,6 @@ error.
32413209
** *`timeout` (Optional, string | -1 | 0)*: Period to wait for a response. If no response is received before the
32423210
timeout expires, the request fails and returns an error.
32433211

3244-
[discrete]
3245-
==== put_template
3246-
Create or update an index template.
3247-
Index templates define settings, mappings, and aliases that can be applied automatically to new indices.
3248-
3249-
{ref}/indices-templates-v1.html[Endpoint documentation]
3250-
[source,ts]
3251-
----
3252-
client.indices.putTemplate({ name })
3253-
----
3254-
3255-
[discrete]
3256-
==== Arguments
3257-
3258-
* *Request (object):*
3259-
** *`name` (string)*: The name of the template
3260-
** *`aliases` (Optional, Record<string, { filter, index_routing, is_hidden, is_write_index, routing, search_routing }>)*: Aliases for the index.
3261-
** *`index_patterns` (Optional, string | string[])*: Array of wildcard expressions used to match the names
3262-
of indices during creation.
3263-
** *`mappings` (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 })*: Mapping for fields in the index.
3264-
** *`order` (Optional, number)*: Order in which Elasticsearch applies this template if index
3265-
matches multiple templates.
3266-
3267-
Templates with lower 'order' values are merged first. Templates with higher
3268-
'order' values are merged later, overriding templates with lower values.
3269-
** *`settings` (Optional, { index, mode, routing_path, soft_deletes, sort, number_of_shards, number_of_replicas, number_of_routing_shards, check_on_startup, codec, routing_partition_size, load_fixed_bitset_filters_eagerly, hidden, auto_expand_replicas, merge, search, refresh_interval, max_result_window, max_inner_result_window, max_rescore_window, max_docvalue_fields_search, max_script_fields, max_ngram_diff, max_shingle_diff, blocks, max_refresh_listeners, analyze, highlight, max_terms_count, max_regex_length, routing, gc_deletes, default_pipeline, final_pipeline, lifecycle, provided_name, creation_date, creation_date_string, uuid, version, verified_before_close, format, max_slices_per_scroll, translog, query_string, priority, top_metrics_max_size, analysis, settings, time_series, queries, similarity, mapping, indexing.slowlog, indexing_pressure, store })*: Configuration options for the index.
3270-
** *`version` (Optional, number)*: Version number used to manage index templates externally. This number
3271-
is not automatically generated by Elasticsearch.
3272-
** *`create` (Optional, boolean)*: If true, this request cannot replace or update existing index templates.
3273-
** *`master_timeout` (Optional, string | -1 | 0)*: Period to wait for a connection to the master node. If no response is
3274-
received before the timeout expires, the request fails and returns an error.
3275-
** *`cause` (Optional, string)*
3276-
32773212
[discrete]
32783213
==== refresh
32793214
Refresh an index.
@@ -3409,7 +3344,7 @@ If set to `false`, then indices or data streams matching the template must alway
34093344
Component templates are merged in the order specified, meaning that the last component template specified has the highest precedence.
34103345
** *`template` (Optional, { aliases, mappings, settings, lifecycle })*: Template to be applied.
34113346
It may optionally include an `aliases`, `mappings`, or `settings` configuration.
3412-
** *`data_stream` (Optional, { hidden })*: If this object is included, the template is used to create data streams and their backing indices.
3347+
** *`data_stream` (Optional, { hidden, allow_custom_routing })*: If this object is included, the template is used to create data streams and their backing indices.
34133348
Supports an empty object.
34143349
Data streams require a matching index template with a `data_stream` object.
34153350
** *`priority` (Optional, number)*: Priority to determine index template precedence when a new data stream or index is created.
@@ -3643,8 +3578,8 @@ client.ingest.putPipeline({ id })
36433578
** *`id` (string)*: ID of the ingest pipeline to create or update.
36443579
** *`_meta` (Optional, Record<string, User-defined value>)*: Optional metadata about the ingest pipeline. May have any contents. This map is not automatically generated by Elasticsearch.
36453580
** *`description` (Optional, string)*: Description of the ingest pipeline.
3646-
** *`on_failure` (Optional, { append, attachment, bytes, circle, convert, csv, date, date_index_name, dissect, dot_expander, drop, enrich, fail, foreach, geo_grid, geoip, grok, gsub, html_strip, inference, join, json, kv, lowercase, pipeline, redact, remove, rename, reroute, script, set, set_security_user, sort, split, trim, uppercase, urldecode, uri_parts, user_agent }[])*: Processors to run immediately after a processor failure. Each processor supports a processor-level `on_failure` value. If a processor without an `on_failure` value fails, Elasticsearch uses this pipeline-level parameter as a fallback. The processors in this parameter run sequentially in the order specified. Elasticsearch will not attempt to run the pipeline's remaining processors.
3647-
** *`processors` (Optional, { append, attachment, bytes, circle, convert, csv, date, date_index_name, dissect, dot_expander, drop, enrich, fail, foreach, geo_grid, geoip, grok, gsub, html_strip, inference, join, json, kv, lowercase, pipeline, redact, remove, rename, reroute, script, set, set_security_user, sort, split, trim, uppercase, urldecode, uri_parts, user_agent }[])*: Processors used to perform transformations on documents before indexing. Processors run sequentially in the order specified.
3581+
** *`on_failure` (Optional, { append, attachment, bytes, circle, convert, csv, date, date_index_name, dissect, dot_expander, drop, enrich, fail, foreach, geo_grid, geoip, grok, gsub, html_strip, inference, join, json, kv, lowercase, pipeline, redact, remove, rename, reroute, script, set, set_security_user, sort, split, terminate, trim, uppercase, urldecode, uri_parts, user_agent }[])*: Processors to run immediately after a processor failure. Each processor supports a processor-level `on_failure` value. If a processor without an `on_failure` value fails, Elasticsearch uses this pipeline-level parameter as a fallback. The processors in this parameter run sequentially in the order specified. Elasticsearch will not attempt to run the pipeline's remaining processors.
3582+
** *`processors` (Optional, { append, attachment, bytes, circle, convert, csv, date, date_index_name, dissect, dot_expander, drop, enrich, fail, foreach, geo_grid, geoip, grok, gsub, html_strip, inference, join, json, kv, lowercase, pipeline, redact, remove, rename, reroute, script, set, set_security_user, sort, split, terminate, trim, uppercase, urldecode, uri_parts, user_agent }[])*: Processors used to perform transformations on documents before indexing. Processors run sequentially in the order specified.
36483583
** *`version` (Optional, number)*: Version number used by external systems to track ingest pipelines. This parameter is intended for external systems only. Elasticsearch does not use or validate pipeline version numbers.
36493584
** *`deprecated` (Optional, boolean)*: Marks this ingest pipeline as deprecated.
36503585
When a deprecated ingest pipeline is referenced as the default or final pipeline when creating or updating a non-deprecated index template, Elasticsearch will emit a deprecation warning.
@@ -5599,6 +5534,23 @@ client.security.createApiKey({ ... })
55995534
** *`metadata` (Optional, Record<string, User-defined value>)*: Arbitrary metadata that you want to associate with the API key. It supports nested data structure. Within the metadata object, keys beginning with `_` are reserved for system usage.
56005535
** *`refresh` (Optional, Enum(true | false | "wait_for"))*: If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes.
56015536

5537+
[discrete]
5538+
==== delete_role
5539+
Removes roles in the native realm.
5540+
5541+
{ref}/security-api-delete-role.html[Endpoint documentation]
5542+
[source,ts]
5543+
----
5544+
client.security.deleteRole({ name })
5545+
----
5546+
5547+
[discrete]
5548+
==== Arguments
5549+
5550+
* *Request (object):*
5551+
** *`name` (string)*: Role name
5552+
** *`refresh` (Optional, Enum(true | false | "wait_for"))*: If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes.
5553+
56025554
[discrete]
56035555
==== get_api_key
56045556
Get API key information.
@@ -5634,6 +5586,34 @@ descriptors and the owner user's role descriptors.
56345586
** *`active_only` (Optional, boolean)*: A boolean flag that can be used to query API keys that are currently active. An API key is considered active if it is neither invalidated, nor expired at query time. You can specify this together with other parameters such as `owner` or `name`. If `active_only` is false, the response will include both active and inactive (expired or invalidated) keys.
56355587
** *`with_profile_uid` (Optional, boolean)*: Determines whether to also retrieve the profile uid, for the API key owner principal, if it exists.
56365588

5589+
[discrete]
5590+
==== get_builtin_privileges
5591+
Retrieves the list of cluster privileges and index privileges that are available in this version of Elasticsearch.
5592+
5593+
{ref}/security-api-get-builtin-privileges.html[Endpoint documentation]
5594+
[source,ts]
5595+
----
5596+
client.security.getBuiltinPrivileges()
5597+
----
5598+
5599+
5600+
[discrete]
5601+
==== get_role
5602+
The role management APIs are generally the preferred way to manage roles, rather than using file-based role management.
5603+
The get roles API cannot retrieve roles that are defined in roles files.
5604+
5605+
{ref}/security-api-get-role.html[Endpoint documentation]
5606+
[source,ts]
5607+
----
5608+
client.security.getRole({ ... })
5609+
----
5610+
5611+
[discrete]
5612+
==== Arguments
5613+
5614+
* *Request (object):*
5615+
** *`name` (Optional, string | string[])*: The name of the role. You can specify multiple roles as a list. If you do not specify this parameter, the API returns information about all roles.
5616+
56375617
[discrete]
56385618
==== has_privileges
56395619
Check user privileges.
@@ -5687,6 +5667,31 @@ This parameter cannot be used with either `ids` or `name`, or when `owner` flag
56875667
** *`username` (Optional, string)*: The username of a user.
56885668
This parameter cannot be used with either `ids` or `name`, or when `owner` flag is set to `true`.
56895669

5670+
[discrete]
5671+
==== put_role
5672+
The role management APIs are generally the preferred way to manage roles, rather than using file-based role management.
5673+
The create or update roles API cannot update roles that are defined in roles files.
5674+
5675+
{ref}/security-api-put-role.html[Endpoint documentation]
5676+
[source,ts]
5677+
----
5678+
client.security.putRole({ name })
5679+
----
5680+
5681+
[discrete]
5682+
==== Arguments
5683+
5684+
* *Request (object):*
5685+
** *`name` (string)*: The name of the role that is being created or updated. On Elasticsearch Serverless, the role name must begin with a letter or digit and can only contain letters, digits and the characters '_', '-', and '.'. Each role must have a unique name, as this will serve as the identifier for that role.
5686+
** *`applications` (Optional, { application, privileges, resources }[])*: A list of application privilege entries.
5687+
** *`cluster` (Optional, Enum("all" | "cancel_task" | "create_snapshot" | "cross_cluster_replication" | "cross_cluster_search" | "delegate_pki" | "grant_api_key" | "manage" | "manage_api_key" | "manage_autoscaling" | "manage_behavioral_analytics" | "manage_ccr" | "manage_data_frame_transforms" | "manage_data_stream_global_retention" | "manage_enrich" | "manage_ilm" | "manage_index_templates" | "manage_inference" | "manage_ingest_pipelines" | "manage_logstash_pipelines" | "manage_ml" | "manage_oidc" | "manage_own_api_key" | "manage_pipeline" | "manage_rollup" | "manage_saml" | "manage_search_application" | "manage_search_query_rules" | "manage_search_synonyms" | "manage_security" | "manage_service_account" | "manage_slm" | "manage_token" | "manage_transform" | "manage_user_profile" | "manage_watcher" | "monitor" | "monitor_data_frame_transforms" | "monitor_data_stream_global_retention" | "monitor_enrich" | "monitor_inference" | "monitor_ml" | "monitor_rollup" | "monitor_snapshot" | "monitor_text_structure" | "monitor_transform" | "monitor_watcher" | "none" | "post_behavioral_analytics_event" | "read_ccr" | "read_fleet_secrets" | "read_ilm" | "read_pipeline" | "read_security" | "read_slm" | "transport_client" | "write_connector_secrets" | "write_fleet_secrets")[])*: A list of cluster privileges. These privileges define the cluster-level actions for users with this role.
5688+
** *`indices` (Optional, { field_security, names, privileges, query }[])*: A list of indices permissions entries.
5689+
** *`metadata` (Optional, Record<string, User-defined value>)*: Optional metadata. Within the metadata object, keys that begin with an underscore (`_`) are reserved for system use.
5690+
** *`run_as` (Optional, string[])*: A list of users that the owners of this role can impersonate. *Note*: in Serverless, the run-as feature is disabled. For API compatibility, you can still specify an empty `run_as` field, but a non-empty list will be rejected.
5691+
** *`description` (Optional, string)*: Optional description of the role descriptor
5692+
** *`transient_metadata` (Optional, Record<string, User-defined value>)*: Indicates roles that might be incompatible with the current cluster license, specifically roles with document and field level security. When the cluster license doesn’t allow certain features for a given role, this parameter is updated dynamically to list the incompatible features. If `enabled` is `false`, the role is ignored, but is still listed in the response from the authenticate API.
5693+
** *`refresh` (Optional, Enum(true | false | "wait_for"))*: If `true` (the default) then refresh the affected shards to make this operation visible to search, if `wait_for` then wait for a refresh to make this operation visible to search, if `false` then do nothing with refreshes.
5694+
56905695
[discrete]
56915696
==== query_api_keys
56925697
Query API keys.

src/api/api/enrich.ts

Lines changed: 0 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -191,34 +191,4 @@ export default class Enrich {
191191
}
192192
return await this.transport.request({ path, method, querystring, body, meta }, options)
193193
}
194-
195-
/**
196-
* Get enrich stats. Returns enrich coordinator statistics and information about enrich policies that are currently executing.
197-
* @see {@link https://www.elastic.co/guide/en/elasticsearch/reference/master/enrich-stats-api.html | Elasticsearch API documentation}
198-
*/
199-
async stats (this: That, params?: T.EnrichStatsRequest | TB.EnrichStatsRequest, options?: TransportRequestOptionsWithOutMeta): Promise<T.EnrichStatsResponse>
200-
async stats (this: That, params?: T.EnrichStatsRequest | TB.EnrichStatsRequest, options?: TransportRequestOptionsWithMeta): Promise<TransportResult<T.EnrichStatsResponse, unknown>>
201-
async stats (this: That, params?: T.EnrichStatsRequest | TB.EnrichStatsRequest, options?: TransportRequestOptions): Promise<T.EnrichStatsResponse>
202-
async stats (this: That, params?: T.EnrichStatsRequest | TB.EnrichStatsRequest, options?: TransportRequestOptions): Promise<any> {
203-
const acceptedPath: string[] = []
204-
const querystring: Record<string, any> = {}
205-
const body = undefined
206-
207-
params = params ?? {}
208-
for (const key in params) {
209-
if (acceptedPath.includes(key)) {
210-
continue
211-
} else if (key !== 'body') {
212-
// @ts-expect-error
213-
querystring[key] = params[key]
214-
}
215-
}
216-
217-
const method = 'GET'
218-
const path = '/_enrich/_stats'
219-
const meta: TransportRequestMetadata = {
220-
name: 'enrich.stats'
221-
}
222-
return await this.transport.request({ path, method, querystring, body, meta }, options)
223-
}
224194
}

0 commit comments

Comments
 (0)