{"id":13412420,"url":"https://github.com/elastic/go-elasticsearch","last_synced_at":"2026-06-02T16:31:11.416Z","repository":{"id":38418750,"uuid":"86367047","full_name":"elastic/go-elasticsearch","owner":"elastic","description":"The official Go client for Elasticsearch","archived":false,"fork":false,"pushed_at":"2025-04-30T14:15:48.000Z","size":73920,"stargazers_count":5865,"open_issues_count":77,"forks_count":626,"subscribers_count":373,"default_branch":"main","last_synced_at":"2025-05-05T17:21:22.843Z","etag":null,"topics":["client","elasticsearch","go","golang"],"latest_commit_sha":null,"homepage":"https://github.com/elastic/go-elasticsearch#go-elasticsearch","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/elastic.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2017-03-27T17:56:15.000Z","updated_at":"2025-05-02T06:47:29.000Z","dependencies_parsed_at":"2023-10-13T07:11:54.198Z","dependency_job_id":"4afe716a-ff2a-46a3-b23e-8dc45b5a0475","html_url":"https://github.com/elastic/go-elasticsearch","commit_stats":{"total_commits":659,"total_committers":56,"mean_commits":"11.767857142857142","dds":"0.48861911987860396","last_synced_commit":"98a819bba0b05036f97be9a6edbf3c4683c03a5e"},"previous_names":["elastic/goelasticsearch","elastic/elasticsearch-go"],"tags_count":65,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elastic%2Fgo-elasticsearch","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elastic%2Fgo-elasticsearch/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elastic%2Fgo-elasticsearch/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/elastic%2Fgo-elasticsearch/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/elastic","download_url":"https://codeload.github.com/elastic/go-elasticsearch/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253833279,"owners_count":21971394,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["client","elasticsearch","go","golang"],"created_at":"2024-07-30T20:01:24.464Z","updated_at":"2026-05-11T12:03:18.364Z","avatar_url":"https://github.com/elastic.png","language":"Go","funding_links":[],"categories":["Go","开源类库","Middleware","数据库驱动程序","Database Drivers","Open source library","Data Management \u0026 Processing","数据搜索引擎","数据库驱动`连接和操作数据库工具`","Generators","NoSQL Databases","Clients \u0026 SDKs","Data Integration Frameworks","Repositories","数据库驱动","开发工具\u0026框架"],"sub_categories":["搜索推荐","检索及分析资料库","Search and Analytic Databases","Search Recommendations","Database \u0026 Cloud Management","资源传输下载","Advanced Console UIs","SQL 查询语句构建库"],"readme":"# go-elasticsearch\n\nThe official Go client for [Elasticsearch](https://www.elastic.co/products/elasticsearch).\n\n**[Download the latest version of Elasticsearch](https://www.elastic.co/downloads/elasticsearch)**\nor\n**[sign-up](https://cloud.elastic.co/registration?elektra=en-ess-sign-up-page)**\n**for a free trial of Elastic Cloud**.\n\n[![Go Reference](https://pkg.go.dev/badge/github.com/elastic/go-elasticsearch/v9.svg)](https://pkg.go.dev/github.com/elastic/go-elasticsearch/v9)\n[![Go Report Card](https://goreportcard.com/badge/github.com/elastic/go-elasticsearch)](https://goreportcard.com/report/github.com/elastic/go-elasticsearch)\n[![Build](https://github.com/elastic/go-elasticsearch/actions/workflows/build.yml/badge.svg?branch=main)](https://github.com/elastic/go-elasticsearch/actions/workflows/build.yml?query=branch%3Amain)\n[![Unit](https://github.com/elastic/go-elasticsearch/actions/workflows/test-unit.yml/badge.svg?branch=main)](https://github.com/elastic/go-elasticsearch/actions/workflows/test-unit.yml?query=branch%3Amain)\n[![Integration](https://github.com/elastic/go-elasticsearch/actions/workflows/test-integration.yml/badge.svg?branch=main)](https://github.com/elastic/go-elasticsearch/actions/workflows/test-integration.yml?query=branch%3Amain)\n[![API](https://github.com/elastic/go-elasticsearch/actions/workflows/test-api.yml/badge.svg?branch=main)](https://github.com/elastic/go-elasticsearch/actions/workflows/test-api.yml?query=branch%3Amain)\n[![Lint](https://github.com/elastic/go-elasticsearch/actions/workflows/lint.yml/badge.svg?branch=main\u0026event=push)](https://github.com/elastic/go-elasticsearch/actions/workflows/lint.yml)\n\n## Documentation\n\nFind the full reference documentation at [elastic.co](https://www.elastic.co/docs/reference/elasticsearch/clients/go):\n\n- [Getting started](https://www.elastic.co/docs/reference/elasticsearch/clients/go/getting-started)\n- [Configuration](https://www.elastic.co/docs/reference/elasticsearch/clients/go/configuration)\n- [Using the API](https://www.elastic.co/docs/reference/elasticsearch/clients/go/using-the-api) (low-level and typed)\n- [Typed API](https://www.elastic.co/docs/reference/elasticsearch/clients/go/typed-api) and [esdsl builders](https://www.elastic.co/docs/reference/elasticsearch/clients/go/typed-api/esdsl)\n- [Advanced topics](https://www.elastic.co/docs/reference/elasticsearch/clients/go/advanced) (interceptors, observability)\n\nThe Go package reference lives on [pkg.go.dev](https://pkg.go.dev/github.com/elastic/go-elasticsearch/v9).\n\n\u003c!-- ----------------------------------------------------------------------------------------------- --\u003e\n\n## Compatibility\n\n### Go\n\nStarting from version `8.12.0`, this library follows the Go language's [release policy](https://go.dev/doc/devel/release#policy). Each major Go release is supported until there are two newer major releases. For example, Go 1.5 was supported until the Go 1.7 release, and Go 1.6 was supported until the Go 1.8 release.\n\n### Elasticsearch\n\nLanguage clients are forward compatible; meaning that clients support communicating with greater or equal minor versions of Elasticsearch.\nElasticsearch language clients are only backward compatible with default distributions and without guarantees made.\n\nWhen using Go modules, include the version in the import path, and specify either an explicit version or a branch:\n\n    require github.com/elastic/go-elasticsearch/v9 v9.x.x\n    require github.com/elastic/go-elasticsearch/v8 v8.x.x\n\nIt's possible to use multiple versions of the client in a single project:\n\n    // go.mod\n    github.com/elastic/go-elasticsearch/v8 v8.18.0\n    github.com/elastic/go-elasticsearch/v9 v9.0.0\n\n    // main.go\n    import (\n      elasticsearch8 \"github.com/elastic/go-elasticsearch/v8\"\n      elasticsearch9 \"github.com/elastic/go-elasticsearch/v9\"\n    )\n    // ...\n    es8, _ := elasticsearch8.New()\n    es9, _ := elasticsearch9.New()\n\nThe `main` branch of the client is compatible with the current `master` branch of Elasticsearch.\n\n\u003c!-- ----------------------------------------------------------------------------------------------- --\u003e\n\n## Installation\n\nRefer to the [Installation](https://www.elastic.co/docs/reference/elasticsearch/clients/go/installation)\npage of the documentation.\n\n\u003c!-- ----------------------------------------------------------------------------------------------- --\u003e\n\n## Connecting\n\nRefer to the [Connecting](https://www.elastic.co/docs/reference/elasticsearch/clients/go/connecting)\npage of the documentation.\n\n## Operations\n\n- [Creating an index](https://www.elastic.co/docs/reference/elasticsearch/clients/go/using-the-api/crud-operations)\n- [Indexing documents](https://www.elastic.co/docs/reference/elasticsearch/clients/go/using-the-api/crud-operations)\n- [Getting documents](https://www.elastic.co/docs/reference/elasticsearch/clients/go/using-the-api/crud-operations)\n- [Searching documents](https://www.elastic.co/docs/reference/elasticsearch/clients/go/using-the-api/searching)\n- [Updating documents](https://www.elastic.co/docs/reference/elasticsearch/clients/go/using-the-api/crud-operations)\n- [Deleting documents](https://www.elastic.co/docs/reference/elasticsearch/clients/go/using-the-api/crud-operations)\n- [Deleting an index](https://www.elastic.co/docs/reference/elasticsearch/clients/go/using-the-api/crud-operations)\n\u003c!-- ----------------------------------------------------------------------------------------------- --\u003e\n\n## Helpers\n\nThe `esutil` package provides convenience helpers for working with the client. At the moment, it provides the `esutil.JSONReader()` and the [`esutil.BulkIndexer`](https://www.elastic.co/docs/reference/elasticsearch/clients/go/using-the-api/bulk-indexing) helpers.\n\n\u003c!-- ----------------------------------------------------------------------------------------------- --\u003e\n\n## Examples\n\nThe **[`_examples`](./_examples)** folder contains a number of recipes and comprehensive examples to get you started with the client,\nincluding configuration and customization of the client, using a custom certificate authority (CA) for security (TLS),\nmocking the transport for unit tests, embedding the client in a custom type, building queries, performing requests individually and in bulk, and parsing the responses.\n\n\u003c!-- ----------------------------------------------------------------------------------------------- --\u003e\n\n## License\n\nThis software is licensed under the [Apache 2 license](./LICENSE). See [NOTICE](./NOTICE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felastic%2Fgo-elasticsearch","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Felastic%2Fgo-elasticsearch","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Felastic%2Fgo-elasticsearch/lists"}