title: Searching boolean keys within nested object in Elasticsearch
body: <p>I have <code>user</code> object and it has nested object <code>status</code> which has few boolean flags. I need to search all the users which has that boolean flag. For example search all users which has <code>flag1</code> status set. I am able to search with name and phone values</p>
  
  <p>Data structure:</p>
  
  <pre><code>user : {
    name: ABC,
    phone: 1234567890,
    status: {
      flag1: true,
      flag9: true
    }
  }
  </code></pre>