Send bucket documets results

i trying to make aggregation for buckets
so i did

"aggs": {
"name": {
"terms": {
"field": "client.name"
}
}

  }

and the response is
key : name1
doc count
key name 2
doc count

i need different response i have the name and i have lat lon location on map.

i want to get in response :
name1
lat
lon
name 2
lat lon
name 3
lat lon.

now i want to have only the most recent lat lon per name .
i couldn't figure it out how to do it

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