Hi,
I have an index that contains geo_point
field. Is there a way to search in this field (for example filter the distance) by an IP address? For example something like this:
GET /my_locations/_search
{
"query": {
"bool": {
"must": {
"match_all": {}
},
"filter": {
"geo_distance": {
"distance": "200km",
"pin": "8.8.8.8"
}
}
}
}
}
So that the IP address would be automatically converted to lat
+ lon
just like during ingestion/indexing and only documents within this distance would be returned?
Thanks!