OpenSearchServiceServerless / Client / update_index

update_index

OpenSearchServiceServerless.Client.update_index(**kwargs)

Updates an existing index in an OpenSearch Serverless collection. This operation allows you to modify the index schema, including adding new fields or changing field mappings. You can also enable automatic semantic enrichment ingestion and search. For more information, see About automatic semantic enrichment.

See also: AWS API Documentation

Request Syntax

response = client.update_index(
    id='string',
    indexName='string',
    indexSchema={...}|[...]|123|123.4|'string'|True|None
)
Parameters:
  • id (string) –

    [REQUIRED]

    The unique identifier of the collection containing the index to update.

  • indexName (string) –

    [REQUIRED]

    The name of the index to update.

  • indexSchema (document) – The updated JSON schema definition for the index, including field mappings and settings.

Return type:

dict

Returns:

Response Syntax

{}

Response Structure

  • (dict) –

Exceptions