# What changed in elasticsearch

> 30 changes in elasticsearch 9 from its official release notes, upgrade guides and advisories: 1 deprecations, 1 security, 21 new APIs and options. Each one cited. Sources checked 2026-10-21. HTML: https://unstale.sh/pypi/elasticsearch/

To see which of these apply to a repository, run `npx @unstale/cli init` in it.

## elasticsearch 9

### Security

- Index names are sanitized in the ES|QL query builder. (9.4.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.4.1)

### Deprecations

- Deprecates `confidence_interval` because Lucene 10.4 computes it automatically. (9.5.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.1)

### New APIs and options

- Adds an API to delete a data source. (9.5.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.1)
- Adds an API to get a data source. (9.5.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.1)
- Adds an API to put a data source. (9.5.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.1)
- doc_values now accepts a DocValuesConfig object on all field types. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
- Adds the DocValuesConfig type for configuring doc_values on all field types. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
- Adds the encryption.reset API. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
- Adds the preserve_leaf_arrays attribute to the Flattened field. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
- Adds the route_slice parameter to the indices.validate_query API. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
- Adds the routing parameter to the indices.validate_query API. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
- Adds the inference.delete_region_policy API. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
- Adds the inference.get_region_policy API. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
- Adds the inference.put_region_policy API. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
- Adds the stats parameter to the search API. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
- Adds the search_after parameter to the synonyms.get_synonym API. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
- Adds the append parameter to the synonyms.put_synonym API. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
- Adds the project_routing parameter to the terms_enum API. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
- Adds the basic parameter to the transform.get_transform_stats API. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
- The QueryVectorBuilder type gains an embedding attribute. (9.4.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.4.1)
- The InnerHits type gains a field attribute. (9.4.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.4.1)
- The DenseVectorIndexOptions type gains a flat_index_threshold attribute. (9.4.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.4.1)
- Retries can use an optional backoff delay strategy. (9.4.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.4.1)

### Behavior and default changes

- Changes the `inference_id` default to `.jina-embeddings-v5-text-small` when the Elastic Inference Service is available. (9.5.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.1)

### Fixes and other changes

- Includes the missing `auto_calibrate` property. (9.5.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.1)
- Includes the missing `bits` property. (9.5.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.1)
- Includes the missing `cluster_size` property. (9.5.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.1)
- Includes the missing `default_visit_percentage` property. (9.5.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.1)
- Includes the missing `precondition` property. (9.5.1) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.1)
- Forwards opaque_id in async_scan. (9.5.0) — [release notes](https://github.com/elastic/elasticsearch-py/releases/tag/v9.5.0)
