[source, ruby]
----
response = client.search(
  index: 'sales',
  size: 0,
  body: {
    aggregations: {
      prices: {
        histogram: {
          field: 'price',
          interval: 50
        }
      }
    }
  }
)
puts response
----
