[Empty Clauses were deprecated][1]. Use `match_all` just like you do in your `query` clause.
{
"query": {"match_all": {}}
,"aggs": {
"price": {
"aggs": {
"tt": {
"terms": {
"field": "platformType"
}
}
},
"filter": {
"match_all": {}
}
}
}
}
[1]: https://github.com/elastic/elasticsearch/issues/17540
Using the above I get
`[term] malformed query, expected [END_OBJECT] but found [FIELD_NAME]`
This worked for me
Updated for Elasticsearch 5.6.4 +
{
"query": {
"bool": {
"must": [
{"term": {"shape": "round"}},
{"bool": {
"should": [
{"term": {"color": "red"}},
{"term": {"color": "blue"}}
]
}}
]
}
}
}