|
| 1 | +<p align="center"> |
| 2 | + <img src="https://github.com/elastic/elasticsearch-py/raw/main/docs/logo-elastic-glyph-color.svg" width="20%" alt="Elastic logo" /> |
| 3 | +</p> |
| 4 | + |
| 5 | +# Elasticsearch Python Client |
| 6 | + |
| 7 | +<p align="center"> |
| 8 | + <a href="https://pypi.org/project/elasticsearch"><img alt="PyPI Version" src="https://img.shields.io/pypi/v/elasticsearch" /></a> |
| 9 | + <a href="https://pypi.org/project/elasticsearch"><img alt="Python Versions" src="https://img.shields.io/pypi/pyversions/elasticsearch" /></a> |
| 10 | + <a href="https://anaconda.org/conda-forge/elasticsearch"><img alt="Conda Version" src="https://img.shields.io/conda/vn/conda-forge/elasticsearch" /></a> |
| 11 | + <a href="https://pepy.tech/project/elasticsearch?versions=*"><img alt="Downloads" src="https://static.pepy.tech/badge/elasticsearch" /></a> |
| 12 | +<br/> |
| 13 | + <a href="https://github.com/elastic/elasticsearch-py/actions/workflows/ci.yml?query=workflow%3ACI"><img alt="Build Status on GitHub" src="https://github.com/elastic/elasticsearch-py/workflows/CI/badge.svg" /></a> |
| 14 | + <a href="https://buildkite.com/elastic/elasticsearch-py-integration-tests"><img alt="Buildkite Status on Buildkite" src="https://badge.buildkite.com/68e22afcb2ea8f6dcc20834e3a5b5ab4431beee33d3bd751f3.svg" /></a> |
| 15 | + <a href="https://elasticsearch-py.readthedocs.io"><img alt="Documentation Status" src="https://readthedocs.org/projects/elasticsearch-py/badge/?version=latest" /></a><br> |
| 16 | +</p> |
| 17 | + |
| 18 | +*The official Python client for Elasticsearch.* |
| 19 | + |
| 20 | + |
| 21 | +## Features |
| 22 | + |
| 23 | +* Translating basic Python data types to and from JSON |
| 24 | +* Configurable automatic discovery of cluster nodes |
| 25 | +* Persistent connections |
| 26 | +* Load balancing (with pluggable selection strategy) across available nodes |
| 27 | +* Failed connection penalization (time based - failed connections won't be |
| 28 | + retried until a timeout is reached) |
| 29 | +* Support for TLS and HTTP authentication |
| 30 | +* Thread safety across requests |
| 31 | +* Pluggable architecture |
| 32 | +* Helper functions for idiomatically using APIs together |
| 33 | + |
| 34 | + |
| 35 | +## Installation |
| 36 | + |
| 37 | +[Download the latest version of Elasticsearch](https://www.elastic.co/downloads/elasticsearch) |
| 38 | +or |
| 39 | +[sign-up](https://cloud.elastic.co/registration?elektra=en-ess-sign-up-page) |
| 40 | +for a free trial of Elastic Cloud. |
| 41 | + |
| 42 | +Refer to the [Installation section](https://www.elastic.co/guide/en/elasticsearch/client/python-api/current/getting-started-python.html#_installation) |
| 43 | +of the getting started documentation. |
| 44 | + |
| 45 | + |
| 46 | +## Connecting |
| 47 | + |
| 48 | +Refer to the [Connecting section](https://www.elastic.co/guide/en/elasticsearch/client/python-api/current/getting-started-python.html#_connecting) |
| 49 | +of the getting started documentation. |
| 50 | + |
| 51 | + |
| 52 | +## Usage |
| 53 | +----- |
| 54 | + |
| 55 | +* [Creating an index](https://www.elastic.co/guide/en/elasticsearch/client/python-api/current/getting-started-python.html#_creating_an_index) |
| 56 | +* [Indexing a document](https://www.elastic.co/guide/en/elasticsearch/client/python-api/current/getting-started-python.html#_indexing_documents) |
| 57 | +* [Getting documents](https://www.elastic.co/guide/en/elasticsearch/client/python-api/current/getting-started-python.html#_getting_documents) |
| 58 | +* [Searching documents](https://www.elastic.co/guide/en/elasticsearch/client/python-api/current/getting-started-python.html#_searching_documents) |
| 59 | +* [Updating documents](https://www.elastic.co/guide/en/elasticsearch/client/python-api/current/getting-started-python.html#_updating_documents) |
| 60 | +* [Deleting documents](https://www.elastic.co/guide/en/elasticsearch/client/python-api/current/getting-started-python.html#_deleting_documents) |
| 61 | +* [Deleting an index](https://www.elastic.co/guide/en/elasticsearch/client/python-api/current/getting-started-python.html#_deleting_an_index) |
| 62 | + |
| 63 | + |
| 64 | +## Compatibility |
| 65 | + |
| 66 | +Language clients are forward compatible; meaning that the clients support |
| 67 | +communicating with greater or equal minor versions of Elasticsearch without |
| 68 | +breaking. It does not mean that the clients automatically support new features |
| 69 | +of newer Elasticsearch versions; it is only possible after a release of a new |
| 70 | +client version. For example, a 8.12 client version won't automatically support |
| 71 | +the new features of the 8.13 version of Elasticsearch, the 8.13 client version |
| 72 | +is required for that. Elasticsearch language clients are only backwards |
| 73 | +compatible with default distributions and without guarantees made. |
| 74 | + |
| 75 | +| Elasticsearch Version | Elasticsearch-Python Branch | Supported | |
| 76 | +| --------------------- | ------------------------ | --------- | |
| 77 | +| main | main | | |
| 78 | +| 8.x | 8.x | 8.x | |
| 79 | +| 7.x | 7.x | 7.17 | |
| 80 | + |
| 81 | + |
| 82 | +If you have a need to have multiple versions installed at the same time older |
| 83 | +versions are also released as ``elasticsearch7`` and ``elasticsearch8``. |
| 84 | + |
| 85 | + |
| 86 | +## Documentation |
| 87 | + |
| 88 | +Documentation for the client is [available on elastic.co] and [Read the Docs]. |
| 89 | + |
| 90 | +[available on elastic.co]: https://www.elastic.co/guide/en/elasticsearch/client/python-api/current/index.html |
| 91 | +[Read the Docs]: https://elasticsearch-py.readthedocs.io |
| 92 | + |
| 93 | + |
| 94 | +## Feedback 🗣️ |
| 95 | + |
| 96 | +The engineering team here at Elastic is looking for developers to participate in |
| 97 | +research and feedback sessions to learn more about how you use our Python client and |
| 98 | +what improvements we can make to their design and your workflow. If you're interested in |
| 99 | +sharing your insights into developer experience and language client design, please fill |
| 100 | +out this [short form]. Depending on the number of responses we get, we may either |
| 101 | +contact you for a 1:1 conversation or a focus group with other developers who use the |
| 102 | +same client. Thank you in advance - your feedback is crucial to improving the user |
| 103 | +experience for all Elasticsearch developers! |
| 104 | + |
| 105 | +[short form]: https://forms.gle/bYZwDQXijfhfwshn9 |
| 106 | + |
| 107 | +## License |
| 108 | + |
| 109 | +This software is licensed under the [Apache License 2.0](./LICENSE). See [NOTICE](./NOTICE). |
0 commit comments