Skip to content

Delete by query

Deleting documents that match a given query

POST /products/_delete_by_query
{
  "query": {
    "match_all": { }
  }
}

Ignoring (counting) version conflicts

The conflicts key may be added as a query parameter instead, i.e. ?conflicts=proceed.

POST /products/_delete_by_query
{
  "conflicts": "proceed",
  "query": {
    "match_all": { }
  }
}