PHPackages                             shyim/opensearch-php-dsl - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Search &amp; Filtering](/categories/search)
4. /
5. shyim/opensearch-php-dsl

ActiveLibrary[Search &amp; Filtering](/categories/search)

shyim/opensearch-php-dsl
========================

OpenSearch/Elasticsearch DSL library

1.1.4(2mo ago)175.9M↓14.9%9[3 issues](https://github.com/shyim/opensearch-php-dsl/issues)7MITPHPPHP &gt;=8.0CI failing

Since Jul 22Pushed 2mo ago2 watchersCompare

[ Source](https://github.com/shyim/opensearch-php-dsl)[ Packagist](https://packagist.org/packages/shyim/opensearch-php-dsl)[ Docs](https://github.com/shyim/opensearch-dsl)[ RSS](/packages/shyim-opensearch-php-dsl/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (10)Dependencies (8)Versions (14)Used By (7)

OpenSearch DSL
==============

[](#opensearch-dsl)

Introducing OpenSearch DSL library to provide objective query builder for [opensearch-php](https://github.com/opensearch-project/opensearch-php) client. You can easily build any Opensearch query and transform it to an array.

This is a fork of `ongr-io/ElasticsearchDSL`, which will be more regularly updated. Thanks for ongr-io for building this Library!

If you need any help, [Github issues](https://github.com/shyim/opensearch-dsl/issues) is the preferred and recommended way to ask support questions.

[![Test](https://github.com/shyim/opensearch-php-dsl/actions/workflows/test.yml/badge.svg)](https://github.com/shyim/opensearch-php-dsl/actions/workflows/test.yml)[![codecov](https://camo.githubusercontent.com/8467e4b9e3d1a09d0928653d693cb159fdd3c145a02c7032ca2f2828c58bb3d2/68747470733a2f2f636f6465636f762e696f2f67682f736879696d2f6f70656e7365617263682d7068702d64736c2f6272616e63682f6d61696e2f67726170682f62616467652e737667)](https://codecov.io/gh/shyim/opensearch-php-dsl)[![Latest Stable Version](https://camo.githubusercontent.com/a5e3b32e2907ef14954a4c8f014c8cfbbeff829fbe309f499f4d9254464696eb/68747470733a2f2f706f7365722e707567782e6f72672f736879696d2f6f70656e7365617263682d7068702d64736c2f762f737461626c65)](https://packagist.org/packages/shyim/opensearch-php-dsl)[![Total Downloads](https://camo.githubusercontent.com/0ef9756636792fd05c2003ef6727c205d7490ec5499e5bb59ecf274224261612/68747470733a2f2f706f7365722e707567782e6f72672f736879696d2f6f70656e7365617263682d7068702d64736c2f646f776e6c6f616473)](https://packagist.org/packages/shyim/opensearch-php-dsl)

Version matrix
--------------

[](#version-matrix)

OpenSearch versionOpenSearchDSL version&gt;= 1.0&gt;= 1.0&gt;= 2.0&gt;= 1.0Documentation
-------------

[](#documentation)

[The online documentation of the bundle is here](docs/index.md)

Try it!
-------

[](#try-it)

### Installation

[](#installation)

Install library with [composer](https://getcomposer.org):

```
$ composer require shyim/opensearch-php-dsl
```

> [elasticsearch-php](https://github.com/elastic/elasticsearch-php) client is defined in the composer requirements, no need to install it.

### Search

[](#search)

The library is standalone and is not coupled with any framework. You can use it in any PHP project, the only requirement is composer. Here's the example:

Create search:

```
