Skip to content

Auto-generated code for main #105

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 13, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions elasticsearch_serverless/_async/client/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2126,9 +2126,9 @@ async def info(
pretty: t.Optional[bool] = None,
) -> ObjectApiResponse[t.Any]:
"""
Get cluster info. Returns basic information about the cluster.
Get cluster info. Get basic build, version, and cluster information.

`<https://www.elastic.co/guide/en/elasticsearch/reference/master/index.html>`_
`<https://www.elastic.co/guide/en/elasticsearch/reference/master/rest-api-root.html>`_
"""
__path_parts: t.Dict[str, str] = {}
__path = "/"
Expand Down
38 changes: 19 additions & 19 deletions elasticsearch_serverless/_async/client/cluster.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,9 +38,8 @@ async def delete_component_template(
timeout: t.Optional[t.Union[str, t.Literal[-1], t.Literal[0]]] = None,
) -> ObjectApiResponse[t.Any]:
"""
Delete component templates. Deletes component templates. Component templates
are building blocks for constructing index templates that specify index mappings,
settings, and aliases.
Delete component templates. Component templates are building blocks for constructing
index templates that specify index mappings, settings, and aliases.

`<https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-component-template.html>`_

Expand Down Expand Up @@ -148,7 +147,7 @@ async def get_component_template(
pretty: t.Optional[bool] = None,
) -> ObjectApiResponse[t.Any]:
"""
Get component templates. Retrieves information about component templates.
Get component templates. Get information about component templates.

`<https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-component-template.html>`_

Expand Down Expand Up @@ -266,20 +265,21 @@ async def put_component_template(
body: t.Optional[t.Dict[str, t.Any]] = None,
) -> ObjectApiResponse[t.Any]:
"""
Create or update a component template. Creates or updates 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.
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.
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.

`<https://www.elastic.co/guide/en/elasticsearch/reference/master/indices-component-template.html>`_

Expand All @@ -302,8 +302,8 @@ async def put_component_template(
:param master_timeout: 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.
:param meta: Optional user metadata about the component template. May have any
contents. This map is not automatically generated by Elasticsearch. This
:param meta: Optional user metadata about the component template. It may have
any contents. This map is not automatically generated by Elasticsearch. This
information is stored in the cluster state, so keeping it short is preferable.
To unset `_meta`, replace the template without specifying this information.
:param version: Version number used to manage component templates externally.
Expand Down
16 changes: 16 additions & 0 deletions elasticsearch_serverless/_async/client/enrich.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ async def delete_policy(
error_trace: t.Optional[bool] = None,
filter_path: t.Optional[t.Union[str, t.Sequence[str]]] = None,
human: t.Optional[bool] = None,
master_timeout: t.Optional[t.Union[str, t.Literal[-1], t.Literal[0]]] = None,
pretty: t.Optional[bool] = None,
) -> ObjectApiResponse[t.Any]:
"""
Expand All @@ -41,6 +42,7 @@ async def delete_policy(
`<https://www.elastic.co/guide/en/elasticsearch/reference/master/delete-enrich-policy-api.html>`_

:param name: Enrich policy to delete.
:param master_timeout: Period to wait for a connection to the master node.
"""
if name in SKIP_IN_PATH:
raise ValueError("Empty value passed for parameter 'name'")
Expand All @@ -53,6 +55,8 @@ async def delete_policy(
__query["filter_path"] = filter_path
if human is not None:
__query["human"] = human
if master_timeout is not None:
__query["master_timeout"] = master_timeout
if pretty is not None:
__query["pretty"] = pretty
__headers = {"accept": "application/json"}
Expand All @@ -73,6 +77,7 @@ async def execute_policy(
error_trace: t.Optional[bool] = None,
filter_path: t.Optional[t.Union[str, t.Sequence[str]]] = None,
human: t.Optional[bool] = None,
master_timeout: t.Optional[t.Union[str, t.Literal[-1], t.Literal[0]]] = None,
pretty: t.Optional[bool] = None,
wait_for_completion: t.Optional[bool] = None,
) -> ObjectApiResponse[t.Any]:
Expand All @@ -82,6 +87,7 @@ async def execute_policy(
`<https://www.elastic.co/guide/en/elasticsearch/reference/master/execute-enrich-policy-api.html>`_

:param name: Enrich policy to execute.
:param master_timeout: Period to wait for a connection to the master node.
:param wait_for_completion: If `true`, the request blocks other enrich policy
execution requests until complete.
"""
Expand All @@ -96,6 +102,8 @@ async def execute_policy(
__query["filter_path"] = filter_path
if human is not None:
__query["human"] = human
if master_timeout is not None:
__query["master_timeout"] = master_timeout
if pretty is not None:
__query["pretty"] = pretty
if wait_for_completion is not None:
Expand All @@ -118,6 +126,7 @@ async def get_policy(
error_trace: t.Optional[bool] = None,
filter_path: t.Optional[t.Union[str, t.Sequence[str]]] = None,
human: t.Optional[bool] = None,
master_timeout: t.Optional[t.Union[str, t.Literal[-1], t.Literal[0]]] = None,
pretty: t.Optional[bool] = None,
) -> ObjectApiResponse[t.Any]:
"""
Expand All @@ -127,6 +136,7 @@ async def get_policy(

:param name: Comma-separated list of enrich policy names used to limit the request.
To return information for all enrich policies, omit this parameter.
:param master_timeout: Period to wait for a connection to the master node.
"""
__path_parts: t.Dict[str, str]
if name not in SKIP_IN_PATH:
Expand All @@ -142,6 +152,8 @@ async def get_policy(
__query["filter_path"] = filter_path
if human is not None:
__query["human"] = human
if master_timeout is not None:
__query["master_timeout"] = master_timeout
if pretty is not None:
__query["pretty"] = pretty
__headers = {"accept": "application/json"}
Expand All @@ -165,6 +177,7 @@ async def put_policy(
filter_path: t.Optional[t.Union[str, t.Sequence[str]]] = None,
geo_match: t.Optional[t.Mapping[str, t.Any]] = None,
human: t.Optional[bool] = None,
master_timeout: t.Optional[t.Union[str, t.Literal[-1], t.Literal[0]]] = None,
match: t.Optional[t.Mapping[str, t.Any]] = None,
pretty: t.Optional[bool] = None,
range: t.Optional[t.Mapping[str, t.Any]] = None,
Expand All @@ -178,6 +191,7 @@ async def put_policy(
:param name: Name of the enrich policy to create or update.
:param geo_match: Matches enrich data to incoming documents based on a `geo_shape`
query.
:param master_timeout: Period to wait for a connection to the master node.
:param match: Matches enrich data to incoming documents based on a `term` query.
:param range: Matches a number, date, or IP address in incoming documents to
a range in the enrich index based on a `term` query.
Expand All @@ -194,6 +208,8 @@ async def put_policy(
__query["filter_path"] = filter_path
if human is not None:
__query["human"] = human
if master_timeout is not None:
__query["master_timeout"] = master_timeout
if pretty is not None:
__query["pretty"] = pretty
if not __body:
Expand Down
Loading
Loading