---
type: api
title: Update field mappings
description: Add new fields to an existing data stream or index.
url: https://www.elastic.co/docs/api/doc/elasticsearch/v9/operation/operation-indices-put-mapping
resource: https://www.elastic.co/docs/api/doc/elasticsearch/v9/operation/operation-indices-put-mapping
products:
  - Elasticsearch
---

# Update field mappings

Authentication: required

## Paths

- `POST` (also `PUT`) `/{index}/_mapping`

#### Path parameters

- `index` (union string | string[]) — required
  A comma-separated list of index names the mapping should be added to (supports wildcards).
Use `_all` or omit to add the mapping on all indices.

## Description

Add new fields to an existing data stream or index.
You can use the update mapping API to:

- Add a new field to an existing index
- Update mappings for multiple indices in a single request
- Add new properties to an object field
- Enable multi-fields for an existing field
- Update supported mapping parameters
- Change a field's mapping using reindexing
- Rename a field using a field alias

Learn how to use the update mapping API with practical examples in the [Update mapping API examples](https://www.elastic.co/docs/manage-data/data-store/mapping/update-mappings-examples) guide.

[More about mapping parameters](https://www.elastic.co/docs/reference/elasticsearch/mapping-reference/mapping-parameters)

## Required privileges

- Index privileges: `manage`

## Query string parameters

- `allow_no_indices` (boolean · default: true) — optional
  A setting that does two separate checks on the index expression.
If `false`, the request returns an error (1) if any wildcard expression
(including `_all` and `*`) resolves to zero matching indices or (2) if the
complete set of resolved indices, aliases or data streams is empty after all
expressions are evaluated. If `true`, index expressions that resolve to no
indices are allowed and the request returns an empty result.
- `expand_wildcards` (union oneOf · default: open) — optional
  Type of index that wildcard patterns can match.
If the request can target data streams, this argument determines whether wildcard expressions match hidden data streams.
Supports comma-separated values, such as `open,hidden`.

Supported values include:
  - `all`: Match any data stream or index, including hidden ones.
  - `open`: Match open, non-hidden indices. Also matches any non-hidden data stream.
  - `closed`: Match closed, non-hidden indices. Also matches any non-hidden data stream. Data streams cannot be closed.
  - `hidden`: Match hidden data streams and hidden indices. Must be combined with `open`, `closed`, or `both`.
  - `none`: Wildcard expressions are not accepted.
  Values: `all`, `open`, `closed`, `hidden`, `none`
- `ignore_unavailable` (boolean · default: false) — optional
  If `false`, the request returns an error if it targets a concrete (non-wildcarded)
index, alias, or data stream that is missing, closed, or otherwise unavailable.
If `true`, unavailable concrete targets are silently ignored.
- `master_timeout` (string · default: 30s) — optional
  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.
- `timeout` (string · default: 30s) — optional
  Period to wait for a response.
If no response is received before the timeout expires, the request fails and returns an error.
- `write_index_only` (boolean · default: false) — optional
  If `true`, the mappings are applied only to the current write index for the target.

## Request body

`application/json`

- `date_detection` (boolean) — optional
  Controls whether dynamic date detection is enabled.
- `dynamic` (enum) — optional
  Controls whether new fields are added dynamically.
  Values: `strict`, `runtime`, `true`, `false`
- `dynamic_date_formats` (string[]) — optional
  If date detection is enabled then new string fields are checked
against 'dynamic_date_formats' and if the value matches then
a new date field is added instead of string.
- `dynamic_templates` (string to object[]) — optional
  Specify dynamic templates for the mapping.
- `_field_names` (object) — optional
  Control whether field names are enabled for the index.
  - `enabled` (boolean) — required
- `_meta` (object) — optional
  A mapping type can have custom meta data associated with it. These are
not used at all by Elasticsearch, but can be used to store
application-specific metadata.
- `numeric_detection` (boolean · default: false) — optional
  Automatically map strings into numeric data types for all fields.
- `properties` (map string to oneOf) — optional
  Mapping for a field. For new fields, this mapping can include:

- Field name
- Field data type
- Mapping parameters
  Map values (union oneOf)
  One of:
  - **type: binary** (`type: binary`)
    - `type` (enum) — required
      Values: `binary`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
  - **type: boolean** (`type: boolean`)
    - `type` (enum) — required
      Values: `boolean`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `fielddata` (object) — optional
      - `format` (enum) — required
        Values: `array`, `disabled`
    - `index` (boolean) — optional
    - `null_value` (boolean) — optional
    - `ignore_malformed` (boolean) — optional
    - `script` (string) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `time_series_dimension` (boolean) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
  - **type: {dynamic_type}** (`type: {dynamic_type}`)
    - `type` (enum) — required
      Values: `{dynamic_type}`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `enabled` (boolean) — optional
    - `null_value` (union oneOf) — optional
      One of: `number` or `string` or `boolean`
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `script` (string) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `ignore_malformed` (boolean) — optional
    - `time_series_metric` (enum) — optional
      Values: `gauge`, `counter`, `summary`, `histogram`, `position`
    - `time_series_dimension` (boolean) — optional
    - `analyzer` (string) — optional
    - `eager_global_ordinals` (boolean) — optional
    - `fielddata` (boolean) — optional
    - `fielddata_frequency_filter` (object) — optional
      - `max` (number) — required
      - `min` (number) — required
      - `min_segment_size` (number) — required
    - `index` (boolean) — optional
    - `index_options` (enum) — optional
      Values: `docs`, `freqs`, `positions`, `offsets`
    - `index_phrases` (boolean) — optional
    - `index_prefixes` (union oneOf) — optional — nullable
      - **TextIndexPrefixes**
        - `max_chars` (number) — optional
        - `min_chars` (number) — optional
      - **string**
    - `norms` (boolean) — optional
    - `position_increment_gap` (number) — optional
    - `search_analyzer` (string) — optional
    - `search_quote_analyzer` (string) — optional
    - `similarity` (union string) — optional — nullable
      One of: `string`
    - `term_vector` (enum) — optional
      Values: `no`, `yes`, `with_offsets`, `with_positions`, `with_positions_offsets`, `with_positions_offsets_payloads`, `with_positions_payloads`
    - `format` (string) — optional
    - `precision_step` (number) — optional
    - `locale` (string) — optional
    - `subobjects` (enum) — optional
      Values: `true`, `false`
  - **type: join** (`type: join`)
    - `type` (enum) — required
      Values: `join`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `relations` (map string to RelationName | RelationName[]) — optional
    - `eager_global_ordinals` (boolean) — optional
  - **type: keyword** (`type: keyword`)
    - `type` (enum) — required
      Values: `keyword`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `eager_global_ordinals` (boolean) — optional
    - `index` (boolean) — optional
    - `index_options` (enum) — optional
      Values: `docs`, `freqs`, `positions`, `offsets`
    - `script` (string) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `normalizer` (string) — optional
    - `norms` (boolean) — optional
    - `null_value` (string) — optional
    - `similarity` (union string) — optional — nullable
      One of: `string`
    - `split_queries_on_whitespace` (boolean) — optional
    - `time_series_dimension` (boolean) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
  - **type: match_only_text** (`type: match_only_text`)
    A variant of text that trades scoring and efficiency of positional queries for space efficiency. This field
effectively stores data the same way as a text field that only indexes documents (index_options: docs) and
disables norms (norms: false). Term queries perform as fast if not faster as on text fields, however queries
that need positions such as the match_phrase query perform slower as they need to look at the _source document
to verify whether a phrase matches. All queries return constant scores that are equal to 1.0.
    - `type` (enum) — required
      Values: `match_only_text`
    - `fields` (map string to oneOf) — optional — recursive
      Multi-fields allow the same string value to be indexed in multiple ways for different purposes, such as one
field for search and a multi-field for sorting and aggregations, or the same string value analyzed by different analyzers.
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `copy_to` (union oneOf) — optional
      Allows you to copy the values of multiple fields into a group
field, which can then be queried as a single field.
      One of: `string[]` or `string`
  - **type: percolator** (`type: percolator`)
    - `type` (enum) — required
      Values: `percolator`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
  - **type: rank_feature** (`type: rank_feature`)
    - `type` (enum) — required
      Values: `rank_feature`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `positive_score_impact` (boolean) — optional
  - **type: rank_features** (`type: rank_features`)
    - `type` (enum) — required
      Values: `rank_features`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `positive_score_impact` (boolean) — optional
  - **type: search_as_you_type** (`type: search_as_you_type`)
    - `type` (enum) — required
      Values: `search_as_you_type`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `analyzer` (string) — optional
    - `index` (boolean) — optional
    - `index_options` (enum) — optional
      Values: `docs`, `freqs`, `positions`, `offsets`
    - `max_shingle_size` (number) — optional
    - `norms` (boolean) — optional
    - `search_analyzer` (string) — optional
    - `search_quote_analyzer` (string) — optional
    - `similarity` (union string) — optional — nullable
      One of: `string`
    - `term_vector` (enum) — optional
      Values: `no`, `yes`, `with_offsets`, `with_positions`, `with_positions_offsets`, `with_positions_offsets_payloads`, `with_positions_payloads`
  - **type: text** (`type: text`)
    - `type` (enum) — required
      Values: `text`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `analyzer` (string) — optional
    - `boost` (number) — optional
    - `eager_global_ordinals` (boolean) — optional
    - `fielddata` (boolean) — optional
    - `fielddata_frequency_filter` (object) — optional
      - `max` (number) — required
      - `min` (number) — required
      - `min_segment_size` (number) — required
    - `index` (boolean) — optional
    - `index_options` (enum) — optional
      Values: `docs`, `freqs`, `positions`, `offsets`
    - `index_phrases` (boolean) — optional
    - `index_prefixes` (union oneOf) — optional — nullable
      - **TextIndexPrefixes**
        - `max_chars` (number) — optional
        - `min_chars` (number) — optional
      - **string**
    - `norms` (boolean) — optional
    - `position_increment_gap` (number) — optional
    - `search_analyzer` (string) — optional
    - `search_quote_analyzer` (string) — optional
    - `similarity` (union string) — optional — nullable
      One of: `string`
    - `term_vector` (enum) — optional
      Values: `no`, `yes`, `with_offsets`, `with_positions`, `with_positions_offsets`, `with_positions_offsets_payloads`, `with_positions_payloads`
  - **type: version** (`type: version`)
    - `type` (enum) — required
      Values: `version`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
  - **type: wildcard** (`type: wildcard`)
    - `type` (enum) — required
      Values: `wildcard`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `null_value` (string) — optional
  - **type: date_nanos** (`type: date_nanos`)
    - `type` (enum) — required
      Values: `date_nanos`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `format` (string) — optional
    - `ignore_malformed` (boolean) — optional
    - `index` (boolean) — optional
    - `script` (string) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `null_value` (union oneOf) — optional
      One of: `string` or `number`
    - `precision_step` (number) — optional
  - **type: date** (`type: date`)
    - `type` (enum) — required
      Values: `date`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `fielddata` (object) — optional
      - `format` (enum) — required
        Values: `array`, `disabled`
    - `format` (string) — optional
    - `ignore_malformed` (boolean) — optional
    - `index` (boolean) — optional
    - `script` (string) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `null_value` (union oneOf) — optional
      One of: `string` or `number`
    - `precision_step` (number) — optional
    - `locale` (string) — optional
  - **type: aggregate_metric_double** (`type: aggregate_metric_double`)
    - `type` (enum) — required
      Values: `aggregate_metric_double`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `default_metric` (string) — required
    - `ignore_malformed` (boolean) — optional
    - `metrics` (string[]) — required
    - `time_series_metric` (enum) — optional
      Values: `gauge`, `counter`, `summary`, `histogram`, `position`
  - **type: dense_vector** (`type: dense_vector`)
    - `type` (enum) — required
      Values: `dense_vector`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `dims` (number) — optional
      Number of vector dimensions. Can't exceed `4096`. If `dims` is not specified, it will be set to the length of
the first vector added to the field.
    - `element_type` (enum · default: float) — optional
      The data type used to encode vectors. The supported data types are `float` (default), `byte`, and `bit`.

Supported values include:
  - `bit`: Indexes a single bit per dimension. Useful for very high-dimensional vectors or models that specifically support
bit vectors.

NOTE: when using `bit`, the number of dimensions must be a multiple of `8` and must represent the number of bits.
  - `byte`: Indexes a 1-byte integer value per dimension.
  - `float`: Indexes a 4-byte floating-point value per dimension.
  - `bfloat16`: Indexes a 2-byte floating-point value per dimension.
      Values: `bit`, `byte`, `float`, `bfloat16`
    - `index` (boolean · default: true) — optional
      If `true`, you can search this field using the kNN search API.
    - `index_options` (object) — optional
      An optional section that configures the kNN indexing algorithm. The HNSW algorithm has two internal parameters
that influence how the data structure is built. These can be adjusted to improve the accuracy of results, at the
expense of slower indexing speed.

This parameter can only be specified when `index` is `true`.
      - `confidence_interval` (number) — optional — deprecated
        The confidence interval to use when quantizing the vectors. Can be any value between and including `0.90` and
`1.0` or exactly `0`. When the value is `0`, this indicates that dynamic quantiles should be calculated for
optimized quantization. When between `0.90` and `1.0`, this value restricts the values used when calculating
the quantization thresholds.

For example, a value of `0.95` will only use the middle `95%` of the values when calculating the quantization
thresholds (e.g. the highest and lowest `2.5%` of values will be ignored).

Defaults to `1/(dims + 1)` for `int8` quantized vectors and `0` for `int4` for dynamic quantile calculation.

Only applicable to `int8_hnsw`, `int4_hnsw`, `int8_flat`, and `int4_flat` index types.
      - `ef_construction` (number · default: 100) — optional
        The number of candidates to track while assembling the list of nearest neighbors for each new node.

Only applicable to `hnsw`, `int8_hnsw`, `bbq_hnsw`, and `int4_hnsw` index types.
      - `m` (number · default: 16) — optional
        The number of neighbors each node will be connected to in the HNSW graph.

Only applicable to `hnsw`, `int8_hnsw`, `bbq_hnsw`, and `int4_hnsw` index types.
      - `type` (enum) — required
        The type of kNN algorithm to use.

Supported values include:
  - `bbq_flat`: This utilizes a brute-force search algorithm in addition to automatically quantizing to binary vectors.
Only supports `element_type` of `float`.
  - `bbq_hnsw`: This utilizes the HNSW algorithm in addition to automatic binary quantization for scalable approximate kNN
search with `element_type` of `float`.

This can reduce the memory footprint by nearly 32x at the cost of some accuracy.
  - `bbq_disk`: This utilizes the DiskBBQ algorithm, a version of Inverted Vector File (IVF) that uses BBQ to quantize vectors.
Only supports `element_type` of `float`.

This not only significantly reduces memory usage, but also allows for indexing and searching of very large datasets that do not fit in memory.
Unlike HNSW, this index type loses performance gracefully as the index grows larger than memory.
  - `flat`: This utilizes a brute-force search algorithm for exact kNN search. This supports all `element_type` values.
  - `hnsw`: This utilizes the HNSW algorithm for scalable approximate kNN search. This supports all `element_type` values.
  - `int4_flat`: This utilizes a brute-force search algorithm in addition to automatically half-byte scalar quantization.
Only supports `element_type` of `float`.
  - `int4_hnsw`: This utilizes the HNSW algorithm in addition to automatically scalar quantization for scalable approximate kNN
search with `element_type` of `float`.

This can reduce the memory footprint by 8x at the cost of some accuracy.
  - `int8_flat`: This utilizes a brute-force search algorithm in addition to automatically scalar quantization. Only supports
`element_type` of `float`.
  - `int8_hnsw`: The default index type for `float` vectors. This utilizes the HNSW algorithm in addition to automatically scalar
quantization for scalable approximate kNN search with `element_type` of `float`.

This can reduce the memory footprint by 4x at the cost of some accuracy.
        Values: `bbq_flat`, `bbq_hnsw`, `bbq_disk`, `flat`, `hnsw`, `int4_flat`, `int4_hnsw`, `int8_flat`, `int8_hnsw`
      - `rescore_vector` (object) — optional
        The rescore vector options. This is only applicable to `bbq_disk`, `bbq_hnsw`, `int4_hnsw`, `int8_hnsw`, `bbq_flat`, `int4_flat`, and `int8_flat` index types.
        - `oversample` (number) — required
          The oversampling factor to use when searching for the nearest neighbor. This is only applicable to the quantized formats: `bbq_*`, `int4_*`, and `int8_*`.
When provided, `oversample * k` vectors will be gathered and then their scores will be re-computed with the original vectors.

valid values are between `1.0` and `10.0` (inclusive), or `0` exactly to disable oversampling.
      - `on_disk_rescore` (boolean · default: false) — optional
        `true` if vector rescoring should be done on-disk

Only applicable to `bbq_disk`, `bbq_hnsw`, `int4_hnsw`, `int8_hnsw`
      - `flat_index_threshold` (number · default: -1) — optional
        The segment document count threshold below which HNSW graph construction is skipped in favor of brute-force flat
search. `-1` (default) defers to format defaults: `300` for `bbq_hnsw`, `150` for `hnsw`, `int8_hnsw`, and
`int4_hnsw`. `0` always builds the graph. A positive value overrides the format default.

Only applicable to `hnsw`, `int8_hnsw`, `int4_hnsw`, `bbq_hnsw`, and `bbq_disk` index types.
      - `cluster_size` (number · default: 384) — optional
        Only applicable to `bbq_disk`. The number of vectors per cluster. Must be between 64 and 65536.
      - `default_visit_percentage` (number · default: 0) — optional
        Only applicable to `bbq_disk`. The percentage of clusters to visit during search. Must be between 0 and 100.
A value of 0 defaults to using `num_candidates` for calculating the visit percentage.
      - `bits` (number · default: 1) — optional
        Only applicable to `bbq_disk`. The number of bits per dimension for quantization encoding.
Valid values are `1`, `2`, `4`, or `7`. When no `rescore_vector` is explicitly set,
the default oversampling is automatically adjusted based on the bits value.
This setting can be changed without reindexing.
      - `precondition` (boolean · default: false) — optional
        Only applicable to `bbq_disk`. When `true`, transforms indexed vectors using a random orthogonal
projection before quantization, which can improve accuracy when vector components are not normally
distributed. Cannot be changed after the field is created.
      - `auto_calibrate` (boolean · default: false) — optional
        Only applicable to `bbq_disk`. When `true`, Elasticsearch automatically selects the optimal
quantization encoding, oversampling factor, and preconditioning for each merged segment based
on estimated recall characteristics. Cannot be changed after the field is created.
    - `similarity` (enum) — optional
      The vector similarity metric to use in kNN search.

Documents are ranked by their vector field's similarity to the query vector. The `_score` of each document will
be derived from the similarity, in a way that ensures scores are positive and that a larger score corresponds
to a higher ranking.

Defaults to `l2_norm` when `element_type` is `bit` otherwise defaults to `cosine`.

`bit` vectors only support `l2_norm` as their similarity metric.

This parameter can only be specified when `index` is `true`.

Supported values include:
  - `cosine`: Computes the cosine similarity. During indexing Elasticsearch automatically normalizes vectors with `cosine`
similarity to unit length. This allows to internally use `dot_product` for computing similarity, which is more
efficient. Original un-normalized vectors can be still accessed through scripts.

The document `_score` is computed as `(1 + cosine(query, vector)) / 2`.

The `cosine` similarity does not allow vectors with zero magnitude, since cosine is not defined in this case.
  - `dot_product`: Computes the dot product of two unit vectors. This option provides an optimized way to perform cosine similarity.
The constraints and computed score are defined by `element_type`.

When `element_type` is `float`, all vectors must be unit length, including both document and query vectors.

The document `_score` is computed as `(1 + dot_product(query, vector)) / 2`.

When `element_type` is `byte`, all vectors must have the same length including both document and query vectors or
results will be inaccurate.

The document `_score` is computed as `0.5 + (dot_product(query, vector) / (32768 * dims))` where `dims` is the
number of dimensions per vector.
  - `l2_norm`: Computes similarity based on the `L2` distance (also known as Euclidean distance) between the vectors.

The document `_score` is computed as `1 / (1 + l2_norm(query, vector)^2)`.

For `bit` vectors, instead of using `l2_norm`, the `hamming` distance between the vectors is used.

The `_score` transformation is `(numBits - hamming(a, b)) / numBits`.
  - `max_inner_product`: Computes the maximum inner product of two vectors. This is similar to `dot_product`, but doesn't require vectors
to be normalized. This means that each vector’s magnitude can significantly effect the score.

The document `_score` is adjusted to prevent negative values. For `max_inner_product` values `< 0`, the `_score`
is `1 / (1 + -1 * max_inner_product(query, vector))`. For non-negative `max_inner_product` results the `_score`
is calculated `max_inner_product(query, vector) + 1`.
      Values: `cosine`, `dot_product`, `l2_norm`, `max_inner_product`
  - **type: flattened** (`type: flattened`)
    - `type` (enum) — required
      Values: `flattened`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `boost` (number) — optional
    - `depth_limit` (number) — optional
    - `doc_values` (boolean) — optional
    - `eager_global_ordinals` (boolean) — optional
    - `index` (boolean) — optional
    - `index_options` (enum) — optional
      Values: `docs`, `freqs`, `positions`, `offsets`
    - `null_value` (string) — optional
    - `preserve_leaf_arrays` (enum) — optional
      How leaf arrays are represented in synthetic source.
When set to `lossy`, leaf arrays are sorted, de-nulled, and deduplicated in the returned synthetic source.
When set to `exact`, leaf arrays preserve order, nulls, and duplicates.
      Values: `lossy`, `exact`
    - `similarity` (string) — optional
    - `split_queries_on_whitespace` (boolean) — optional
    - `time_series_dimensions` (string[]) — optional
  - **type: nested** (`type: nested`)
    - `type` (enum) — required
      Values: `nested`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `enabled` (boolean) — optional
    - `include_in_parent` (boolean) — optional
    - `include_in_root` (boolean) — optional
  - **type: object** (`type: object`)
    - `type` (enum) — optional
      Values: `object`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `enabled` (boolean) — optional
    - `subobjects` (enum) — optional
      Values: `true`, `false`
  - **type: passthrough** (`type: passthrough`)
    - `type` (enum) — optional
      Values: `passthrough`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `enabled` (boolean) — optional
    - `priority` (number) — optional
    - `time_series_dimension` (boolean) — optional
  - **type: rank_vectors** (`type: rank_vectors`)
    Technical preview
    - `type` (enum) — required
      Values: `rank_vectors`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `element_type` (enum) — optional
      Values: `byte`, `float`, `bit`
    - `dims` (number) — optional
  - **type: semantic_text** (`type: semantic_text`)
    - `type` (enum) — required
      Values: `semantic_text`
    - `meta` (map string to string) — optional
    - `inference_id` (string · default: .jina-embeddings-v5-text-small) — optional
      Inference endpoint that will be used to generate embeddings for the field.
This parameter cannot be updated. Use the Create inference API to create the endpoint.
If `search_inference_id` is specified, the inference endpoint will only be used at index time.
If the `inference_id` is not specified, it will default to `.jina-embeddings-v5-text-small` if the cluster is authorized to use the Elastic Inference Service,
otherwise it will default to `.elser-2-elasticsearch`. The `.elser-2-elasticsearch` inference endpoint relies on a local ML node to run the ELSER model.
    - `search_inference_id` (string) — optional
      Inference endpoint that will be used to generate embeddings at query time.
You can update this parameter by using the Update mapping API. Use the Create inference API to create the endpoint.
If not specified, the inference endpoint defined by inference_id will be used at both index and query time.
    - `index_options` (object) — optional
      Settings for index_options that override any defaults used by semantic_text, for example
specific quantization settings.
      - `dense_vector` (object) — optional
        Same fields as `index_options` in `type: dense_vector`
      - `sparse_vector` (object) — optional
        - `prune` (boolean) — optional
          Whether to perform pruning, omitting the non-significant tokens from the query to improve query performance.
If prune is true but the pruning_config is not specified, pruning will occur but default values will be used.
Default: false
        - `pruning_config` (object) — optional
          Optional pruning configuration.
If enabled, this will omit non-significant tokens from the query in order to improve query performance.
This is only used if prune is set to true.
If prune is set to true but pruning_config is not specified, default values will be used.
          - `tokens_freq_ratio_threshold` (number · default: 5) — optional
            Tokens whose frequency is more than this threshold times the average frequency of all tokens in the specified field are considered outliers and pruned.
          - `tokens_weight_threshold` (number · default: 0.4) — optional
            Tokens whose weight is less than this threshold are considered nonsignificant and pruned.
          - `only_score_pruned_tokens` (boolean · default: false) — optional
            Whether to only score pruned tokens, vs only scoring kept tokens.
    - `chunking_settings` (union oneOf) — optional — nullable
      Settings for chunking text into smaller passages. If specified, these will override the
chunking settings sent in the inference endpoint associated with inference_id. If chunking settings are updated,
they will not be applied to existing documents until they are reindexed.
      - **ChunkingSettings**
        - `strategy` (string · default: sentence) — required
          The chunking strategy: `sentence`, `word`, `none` or `recursive`.

 * If `strategy` is set to `recursive`, you must also specify:

- `max_chunk_size`
- either `separators` or`separator_group`

Learn more about different chunking strategies in the linked documentation.
        - `max_chunk_size` (number · default: 250) — required
          The maximum size of a chunk in words.
This value cannot be lower than `20` (for `sentence` strategy) or `10` (for `word` strategy).
This value should not exceed the window size for the associated model.
        - `overlap` (number · default: 100) — optional
          The number of overlapping words for chunks.
It is applicable only to a `word` chunking strategy.
This value cannot be higher than half the `max_chunk_size` value.
        - `sentence_overlap` (number · default: 1) — optional
          The number of overlapping sentences for chunks.
It is applicable only for a `sentence` chunking strategy.
It can be either `1` or `0`.
        - `separator_group` (string) — optional
          Only applicable to the `recursive` strategy and required when using it.

Sets a predefined list of separators in the saved chunking settings based on the selected text type.
Values can be `markdown` or `plaintext`.

Using this parameter is an alternative to manually specifying a custom `separators` list.
        - `separators` (string[]) — optional
          Only applicable to the `recursive` strategy and required when using it.

A list of strings used as possible split points when chunking text.

Each string can be a plain string or a regular expression (regex) pattern.
The system tries each separator in order to split the text, starting from the first item in the list.

After splitting, it attempts to recombine smaller pieces into larger chunks that stay within
the `max_chunk_size` limit, to reduce the total number of chunks generated.
      - **string**
    - `fields` (map string to oneOf) — optional — recursive
      Multi-fields allow the same string value to be indexed in multiple ways for different purposes, such as one
field for search and a multi-field for sorting and aggregations, or the same string value analyzed by different analyzers.
  - **type: sparse_vector** (`type: sparse_vector`)
    - `type` (enum) — required
      Values: `sparse_vector`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `store` (boolean) — optional
    - `index_options` (object) — optional
      Additional index options for the sparse vector field that controls the
token pruning behavior of the sparse vector field.
      - `prune` (boolean) — optional
        Whether to perform pruning, omitting the non-significant tokens from the query to improve query performance.
If prune is true but the pruning_config is not specified, pruning will occur but default values will be used.
Default: false
      - `pruning_config` (object) — optional
        Optional pruning configuration.
If enabled, this will omit non-significant tokens from the query in order to improve query performance.
This is only used if prune is set to true.
If prune is set to true but pruning_config is not specified, default values will be used.
        - `tokens_freq_ratio_threshold` (number · default: 5) — optional
          Tokens whose frequency is more than this threshold times the average frequency of all tokens in the specified field are considered outliers and pruned.
        - `tokens_weight_threshold` (number · default: 0.4) — optional
          Tokens whose weight is less than this threshold are considered nonsignificant and pruned.
        - `only_score_pruned_tokens` (boolean · default: false) — optional
          Whether to only score pruned tokens, vs only scoring kept tokens.
  - **type: completion** (`type: completion`)
    - `type` (enum) — required
      Values: `completion`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `analyzer` (string) — optional
    - `contexts` (object[]) — optional
      - `name` (string) — required
      - `path` (string) — optional
      - `type` (string) — required
      - `precision` (number | string) — optional
    - `max_input_length` (number) — optional
    - `preserve_position_increments` (boolean) — optional
    - `preserve_separators` (boolean) — optional
    - `search_analyzer` (string) — optional
  - **type: constant_keyword** (`type: constant_keyword`)
    - `type` (enum) — required
      Values: `constant_keyword`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `value` (object) — optional
  - **type: counted_keyword** (`type: counted_keyword`)
    - `type` (enum) — required
      Values: `counted_keyword`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `index` (boolean) — optional
  - **type: alias** (`type: alias`)
    - `type` (enum) — required
      Values: `alias`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `path` (string) — optional
  - **type: histogram** (`type: histogram`)
    - `type` (enum) — required
      Values: `histogram`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `ignore_malformed` (boolean) — optional
    - `time_series_metric` (enum) — optional
      Values: `gauge`, `counter`, `summary`, `histogram`, `position`
  - **type: exponential_histogram** (`type: exponential_histogram`)
    - `type` (enum) — required
      Values: `exponential_histogram`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `time_series_metric` (enum) — optional
      Values: `gauge`, `counter`, `summary`, `histogram`, `position`
  - **type: ip** (`type: ip`)
    - `type` (enum) — required
      Values: `ip`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `index` (boolean) — optional
    - `ignore_malformed` (boolean) — optional
    - `null_value` (string) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `script` (string) — optional
    - `time_series_dimension` (boolean) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
  - **type: murmur3** (`type: murmur3`)
    - `type` (enum) — required
      Values: `murmur3`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
  - **type: token_count** (`type: token_count`)
    - `type` (enum) — required
      Values: `token_count`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `analyzer` (string) — optional
    - `boost` (number) — optional
    - `index` (boolean) — optional
    - `null_value` (number) — optional
    - `enable_position_increments` (boolean) — optional
  - **type: geo_point** (`type: geo_point`)
    - `type` (enum) — required
      Values: `geo_point`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `ignore_malformed` (boolean) — optional
    - `ignore_z_value` (boolean) — optional
    - `null_value` (union oneOf) — optional
      - **LatLonGeoLocation**
        - `lat` (number) — required
          Latitude
        - `lon` (number) — required
          Longitude
      - **GeoHashLocation**
        - `geohash` (string) — required
      - **[]number**
      - **string**
    - `index` (boolean) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `script` (string) — optional
    - `time_series_metric` (enum) — optional
      Values: `gauge`, `counter`, `position`
  - **type: geo_shape** (`type: geo_shape`)
    The `geo_shape` data type facilitates the indexing of and searching with arbitrary geo shapes such as rectangles
and polygons.
    - `type` (enum) — required
      Values: `geo_shape`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `coerce` (boolean) — optional
    - `ignore_malformed` (boolean) — optional
    - `ignore_z_value` (boolean) — optional
    - `index` (boolean) — optional
    - `orientation` (enum) — optional
      Values: `right`, `RIGHT`, `counterclockwise`, `ccw`, `left`, `LEFT`, `clockwise`, `cw`
    - `strategy` (enum) — optional
      Values: `recursive`, `term`
  - **type: point** (`type: point`)
    - `type` (enum) — required
      Values: `point`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `ignore_malformed` (boolean) — optional
    - `ignore_z_value` (boolean) — optional
    - `null_value` (string) — optional
  - **type: shape** (`type: shape`)
    The `shape` data type facilitates the indexing of and searching with arbitrary `x, y` cartesian shapes such as
rectangles and polygons.
    - `type` (enum) — required
      Values: `shape`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `coerce` (boolean) — optional
    - `ignore_malformed` (boolean) — optional
    - `ignore_z_value` (boolean) — optional
    - `orientation` (enum) — optional
      Values: `right`, `RIGHT`, `counterclockwise`, `ccw`, `left`, `LEFT`, `clockwise`, `cw`
  - **type: byte** (`type: byte`)
    - `type` (enum) — required
      Values: `byte`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `ignore_malformed` (boolean) — optional
    - `index` (boolean) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `script` (string) — optional
    - `time_series_metric` (enum) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
      Values: `gauge`, `counter`, `summary`, `histogram`, `position`
    - `time_series_dimension` (boolean · default: false) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
    - `null_value` (number) — optional
  - **type: double** (`type: double`)
    - `type` (enum) — required
      Values: `double`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `ignore_malformed` (boolean) — optional
    - `index` (boolean) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `script` (string) — optional
    - `time_series_metric` (enum) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
      Values: `gauge`, `counter`, `summary`, `histogram`, `position`
    - `time_series_dimension` (boolean · default: false) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
    - `null_value` (number) — optional
  - **type: float** (`type: float`)
    - `type` (enum) — required
      Values: `float`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `ignore_malformed` (boolean) — optional
    - `index` (boolean) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `script` (string) — optional
    - `time_series_metric` (enum) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
      Values: `gauge`, `counter`, `summary`, `histogram`, `position`
    - `time_series_dimension` (boolean · default: false) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
    - `null_value` (number) — optional
  - **type: half_float** (`type: half_float`)
    - `type` (enum) — required
      Values: `half_float`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `ignore_malformed` (boolean) — optional
    - `index` (boolean) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `script` (string) — optional
    - `time_series_metric` (enum) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
      Values: `gauge`, `counter`, `summary`, `histogram`, `position`
    - `time_series_dimension` (boolean · default: false) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
    - `null_value` (number) — optional
  - **type: integer** (`type: integer`)
    - `type` (enum) — required
      Values: `integer`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `ignore_malformed` (boolean) — optional
    - `index` (boolean) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `script` (string) — optional
    - `time_series_metric` (enum) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
      Values: `gauge`, `counter`, `summary`, `histogram`, `position`
    - `time_series_dimension` (boolean · default: false) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
    - `null_value` (number) — optional
  - **type: long** (`type: long`)
    - `type` (enum) — required
      Values: `long`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `ignore_malformed` (boolean) — optional
    - `index` (boolean) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `script` (string) — optional
    - `time_series_metric` (enum) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
      Values: `gauge`, `counter`, `summary`, `histogram`, `position`
    - `time_series_dimension` (boolean · default: false) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
    - `null_value` (number) — optional
  - **type: scaled_float** (`type: scaled_float`)
    - `type` (enum) — required
      Values: `scaled_float`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `ignore_malformed` (boolean) — optional
    - `index` (boolean) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `script` (string) — optional
    - `time_series_metric` (enum) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
      Values: `gauge`, `counter`, `summary`, `histogram`, `position`
    - `time_series_dimension` (boolean · default: false) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
    - `null_value` (number) — optional
    - `scaling_factor` (number) — optional
  - **type: short** (`type: short`)
    - `type` (enum) — required
      Values: `short`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `ignore_malformed` (boolean) — optional
    - `index` (boolean) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `script` (string) — optional
    - `time_series_metric` (enum) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
      Values: `gauge`, `counter`, `summary`, `histogram`, `position`
    - `time_series_dimension` (boolean · default: false) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
    - `null_value` (number) — optional
  - **type: unsigned_long** (`type: unsigned_long`)
    - `type` (enum) — required
      Values: `unsigned_long`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `ignore_malformed` (boolean) — optional
    - `index` (boolean) — optional
    - `on_script_error` (enum) — optional
      Values: `fail`, `continue`
    - `script` (string) — optional
    - `time_series_metric` (enum) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
      Values: `gauge`, `counter`, `summary`, `histogram`, `position`
    - `time_series_dimension` (boolean · default: false) — optional
      For internal use by Elastic only. Marks the field as a time series dimension. Defaults to false.
    - `null_value` (number) — optional
  - **type: date_range** (`type: date_range`)
    - `type` (enum) — required
      Values: `date_range`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `index` (boolean) — optional
    - `format` (string) — optional
  - **type: double_range** (`type: double_range`)
    - `type` (enum) — required
      Values: `double_range`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `index` (boolean) — optional
  - **type: float_range** (`type: float_range`)
    - `type` (enum) — required
      Values: `float_range`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `index` (boolean) — optional
  - **type: integer_range** (`type: integer_range`)
    - `type` (enum) — required
      Values: `integer_range`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `index` (boolean) — optional
  - **type: ip_range** (`type: ip_range`)
    - `type` (enum) — required
      Values: `ip_range`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `index` (boolean) — optional
  - **type: long_range** (`type: long_range`)
    - `type` (enum) — required
      Values: `long_range`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `boost` (number) — optional
    - `coerce` (boolean) — optional
    - `index` (boolean) — optional
  - **type: icu_collation_keyword** (`type: icu_collation_keyword`)
    - `type` (enum) — required
      Values: `icu_collation_keyword`
    - `meta` (map string to string) — optional
      Metadata about the field.
    - `properties` (map string to oneOf) — optional — recursive
    - `ignore_above` (number) — optional
    - `dynamic` (enum) — optional
      Values: `strict`, `runtime`, `true`, `false`
    - `fields` (map string to oneOf) — optional — recursive
    - `synthetic_source_keep` (enum) — optional
      

Supported values include:
  - `none`: Synthetic source diverges from the original source (default)
  - `arrays`: Arrays of the corresponding field or object preserve the original element ordering and duplicate elements.
The synthetic source fragment for such arrays is not guaranteed to match the original source exactly,
e.g. array [1, 2, [5], [[4, [3]]], 5] may appear as-is or in an equivalent format like [1, 2, 5, 4, 3, 5].
The exact format may change in the future, in an effort to reduce the storage overhead of this option.
  - `all`: The source for both singleton instances and arrays of the corresponding field or object gets recorded.
When applied to objects, the source of all sub-objects and sub-fields gets captured.
Furthermore, the original source of arrays gets captured and appears in synthetic source with no modifications.
      Values: `none`, `arrays`, `all`
    - `copy_to` (union oneOf) — optional
      One of: `string[]` or `string`
    - `store` (boolean) — optional
    - `doc_values` (union oneOf) — optional
      - **boolean**
      - **DocValuesConfig**
        Configuration object for doc values when sub-parameters are needed.
        - `multi_value` (boolean · default: true) — optional
          If `false`, the field is treated as single-valued, enabling optimized storage.
Only has an effect when columnar index mode is active.
        - `nullability` (boolean · default: true) — optional
          If `false`, every document must provide a non-null value for the field: a document that
omits the field, sets it to `null`, or supplies only null values (an empty array or an
all-null array) is rejected at index time.
A field that defines `null_value` is always exempt, since the configured default removes
the absence of a value.
Only has an effect when columnar index mode is active.
    - `norms` (boolean) — optional
    - `index_options` (enum) — optional
      Values: `docs`, `freqs`, `positions`, `offsets`
    - `index` (boolean) — optional
      Should the field be searchable?
    - `null_value` (string) — optional
      Accepts a string value which is substituted for any explicit null values. Defaults to null, which means the field is treated as missing.
    - `rules` (string) — optional
    - `language` (string) — optional
    - `country` (string) — optional
    - `variant` (string) — optional
    - `strength` (enum) — optional
      Values: `primary`, `secondary`, `tertiary`, `quaternary`, `identical`
    - `decomposition` (enum) — optional
      Values: `no`, `identical`
    - `alternate` (enum) — optional
      Values: `shifted`, `non-ignorable`
    - `case_level` (boolean) — optional
    - `case_first` (enum) — optional
      Values: `lower`, `upper`
    - `numeric` (boolean) — optional
    - `variable_top` (string) — optional
    - `hiragana_quaternary_mode` (boolean) — optional
- `_routing` (object) — optional
  Enable making a routing value required on indexed documents.
  - `required` (boolean) — required
- `_source` (object) — optional
  Control whether the _source field is enabled on the index.
  - `enabled` (boolean) — optional
  - `excludes` (string[]) — optional
  - `includes` (string[]) — optional
  - `mode` (enum) — optional
    

Supported values include:
  - `disabled`
  - `stored`
  - `columnar_stored`
  - `synthetic`: Instead of storing source documents on disk exactly as you send them,
 Elasticsearch can reconstruct source content on the fly upon retrieval.
    Values: `disabled`, `stored`, `columnar_stored`, `synthetic`
- `runtime` (object) — optional
  Mapping of runtime fields for the index.

## Response

`application/json`

- `acknowledged` (boolean)
  For a successful response, this value is always true. On failure, an exception is returned instead.
- `_shards` (object)
  - `failed` (number)
    The number of shards the operation or search attempted to run on but failed.
  - `successful` (number)
    The number of shards the operation or search succeeded on.
  - `total` (number)
    The number of shards the operation or search will run on overall.
  - `failures` (object[])
    - `index` (string)
    - `node` (string)
    - `reason` (object)
      - `type` (string)
        The type of error
      - `reason` (union string) — nullable
        A human-readable explanation of the error, in English.
        One of: `string`
      - `stack_trace` (string)
        The server stack trace. Present only if the `error_trace=true` parameter was sent with the request.
      - `caused_by` (object) — recursive
        Same fields as `reason` in `failures`
      - `root_cause` (object[]) — recursive
        Same fields as `reason` in `failures`
      - `suppressed` (object[]) — recursive
        Same fields as `reason` in `failures`
    - `shard` (number)
    - `status` (string)
    - `primary` (boolean)
  - `skipped` (number)
## Code examples

#### Console

```console
POST /my-index-000001/_mapping
{
  "properties": {
    "user": {
      "properties": {
        "name": {
          "type": "keyword"
        }
      }
    }
  }
}
```

#### JavaScript

```javascript
const response = await client.indices.putMapping({
  index: "my-index-000001",
  properties: {
    user: {
      properties: {
        name: {
          type: "keyword",
        },
      },
    },
  },
});
```

#### Python

```python
resp = client.indices.put_mapping(
    index="my-index-000001",
    properties={
        "user": {
            "properties": {
                "name": {
                    "type": "keyword"
                }
            }
        }
    },
)
```

#### curl

```curl
curl -X POST "$ELASTICSEARCH_URL/my-index-000001/_mapping" \
  -H "Authorization: ApiKey $ELASTIC_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "properties": {
      "user": {
        "properties": {
          "name": {
            "type": "keyword"
          }
        }
      }
    }
  }'
```

#### Java

```java
client.indices().putMapping(p -> p
    .index("my-index-000001")
    .properties("user", pr -> pr
        .object(o -> o
            .properties("name", pro -> pro
                .keyword(k -> k)
            )
        )
    )
);
```

#### C#

```c#
var response = await client.Indices
    .PutMappingAsync(indices: new[] { "my-index-000001" }, d1 => d1
        .Properties(d2 => d2
            .Object(x => x.User, d3 => d3
                .Properties(d4 => d4
                    .Keyword(x => x.Name)
                )
            )
        )
    );
```

#### PHP

```php
$resp = $client->indices()->putMapping([
    "index" => "my-index-000001",
    "body" => [
        "properties" => [
            "user" => [
                "properties" => [
                    "name" => [
                        "type" => "keyword",
                    ],
                ],
            ],
        ],
    ],
]);
```

#### Ruby

```ruby
response = client.indices.put_mapping(
  index: "my-index-000001",
  body: {
    "properties": {
      "user": {
        "properties": {
          "name": {
            "type": "keyword"
          }
        }
      }
    }
  }
)
```

## Response examples

#### 200

`application/json`

Generated from the API spec. Values are representative. Unions use the first variant; deeply nested or large bodies may omit fields.

```json
{
  "acknowledged": false,
  "_shards": {
    "failed": 0,
    "successful": 0,
    "total": 0,
    "failures": [
      {
        "index": "string",
        "node": "string",
        "reason": {
          "type": "string",
          "reason": "string",
          "stack_trace": "string",
          "caused_by": {
            "type": "string",
            "stack_trace": "string"
          },
          "root_cause": [],
          "suppressed": []
        },
        "shard": 0,
        "status": "string",
        "primary": false
      }
    ],
    "skipped": 0
  }
}
```

