Elastic-muto - Easy expressive search queries for Elasticsearch

Boolean would like to announce elastic-muto, a npm module for building elasticsearch queries using an easy and expressive syntax. The generated query can be customised as well!

Code Example

// Import the library
const muto = require('elastic-muto');

// muto.parse returns an elastic-builder BoolQuery object
const qry = muto.parse('["elasticsearch"] == "awesome" and ["unicorn"] exists');
  "bool": {
    "must": [
        "term": { "elasticsearch.keyword": "awesome" }
        "exists": { "field": "unicorn" }



Project home

API documentation


The parser was originally developed for parsing filter conditions for the GET score API of Boolean.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.