Auto-generated API code (#2734)
This commit is contained in:
@ -3782,7 +3782,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.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-post-voting-config-exclusions[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-cluster-post-voting-config-exclusions[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.cluster.deleteVotingConfigExclusions({ ... })
|
||||
@ -3968,7 +3968,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.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-cluster-post-voting-config-exclusions[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-cluster-post-voting-config-exclusions[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.cluster.postVotingConfigExclusions({ ... })
|
||||
@ -8042,6 +8042,42 @@ client.inference.get({ ... })
|
||||
** *`task_type` (Optional, Enum("sparse_embedding" | "text_embedding" | "rerank" | "completion" | "chat_completion"))*: The task type
|
||||
** *`inference_id` (Optional, string)*: The inference Id
|
||||
|
||||
[discrete]
|
||||
==== inference
|
||||
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.
|
||||
|
||||
For details about using this API with a service, such as Amazon Bedrock, Anthropic, or HuggingFace, refer to the service-specific documentation.
|
||||
|
||||
> 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.
|
||||
|
||||
{ref}/post-inference-api.html[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.inference.inference({ inference_id, input })
|
||||
----
|
||||
|
||||
[discrete]
|
||||
==== Arguments
|
||||
|
||||
* *Request (object):*
|
||||
** *`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" | "chat_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
|
||||
Create an inference endpoint.
|
||||
@ -9039,7 +9075,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.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-license-post[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-license-post[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.license.post({ ... })
|
||||
@ -11073,7 +11109,7 @@ restart the model deployment.
|
||||
==== update_data_frame_analytics
|
||||
Update a data frame analytics job.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-update-data-frame-analytics[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-ml-update-data-frame-analytics[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.ml.updateDataFrameAnalytics({ id })
|
||||
@ -11284,7 +11320,7 @@ snapshot will be deleted when the job is deleted.
|
||||
==== update_trained_model_deployment
|
||||
Update a trained model deployment.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-ml-update-trained-model-deployment[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-ml-update-trained-model-deployment[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.ml.updateTrainedModelDeployment({ model_id })
|
||||
@ -16030,7 +16066,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.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-update-transform[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-transform-update-transform[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.transform.updateTransform({ transform_id })
|
||||
@ -16077,7 +16113,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.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-transform-upgrade-transforms[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-transform-upgrade-transforms[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.transform.upgradeTransforms({ ... })
|
||||
@ -16106,7 +16142,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).
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-ack-watch[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-watcher-ack-watch[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.watcher.ackWatch({ watch_id })
|
||||
@ -16125,7 +16161,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.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-activate-watch[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-watcher-activate-watch[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.watcher.activateWatch({ watch_id })
|
||||
@ -16142,7 +16178,7 @@ client.watcher.activateWatch({ watch_id })
|
||||
Deactivate a watch.
|
||||
A watch can be either active or inactive.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-deactivate-watch[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-watcher-deactivate-watch[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.watcher.deactivateWatch({ watch_id })
|
||||
@ -16165,7 +16201,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.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-delete-watch[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-watcher-delete-watch[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.watcher.deleteWatch({ id })
|
||||
@ -16194,7 +16230,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.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-execute-watch[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-watcher-execute-watch[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.watcher.executeWatch({ ... })
|
||||
@ -16223,7 +16259,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`.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-get-settings[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-watcher-get-settings[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.watcher.getSettings({ ... })
|
||||
@ -16240,7 +16276,7 @@ If no response is received before the timeout expires, the request fails and ret
|
||||
==== get_watch
|
||||
Get a watch.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-get-watch[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-watcher-get-watch[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.watcher.getWatch({ id })
|
||||
@ -16267,7 +16303,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.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-put-watch[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-watcher-put-watch[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.watcher.putWatch({ id })
|
||||
@ -16302,7 +16338,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.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-query-watches[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-watcher-query-watches[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.watcher.queryWatches({ ... })
|
||||
@ -16325,7 +16361,7 @@ It must be non-negative.
|
||||
Start the watch service.
|
||||
Start the Watcher service if it is not already running.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-start[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-watcher-start[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.watcher.start({ ... })
|
||||
@ -16343,7 +16379,7 @@ Get Watcher statistics.
|
||||
This API always returns basic metrics.
|
||||
You retrieve more metrics by using the metric parameter.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-stats[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-watcher-stats[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.watcher.stats({ ... })
|
||||
@ -16361,7 +16397,7 @@ client.watcher.stats({ ... })
|
||||
Stop the watch service.
|
||||
Stop the Watcher service if it is running.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-stop[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-watcher-stop[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.watcher.stop({ ... })
|
||||
@ -16385,7 +16421,7 @@ This includes `index.auto_expand_replicas`, `index.number_of_replicas`, `index.r
|
||||
Modification of `index.routing.allocation.include._tier_preference` is an exception and is not allowed as the
|
||||
Watcher shards must always be in the `data_content` tier.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/operation/operation-watcher-update-settings[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/operation/operation-watcher-update-settings[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.watcher.updateSettings({ ... })
|
||||
@ -16435,7 +16471,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.
|
||||
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/group/endpoint-xpack[Endpoint documentation]
|
||||
https://www.elastic.co/docs/api/doc/elasticsearch/v8/group/endpoint-xpack[Endpoint documentation]
|
||||
[source,ts]
|
||||
----
|
||||
client.xpack.usage({ ... })
|
||||
|
||||
Reference in New Issue
Block a user