Browse Nearby Locations
curl --request GET \
--url https://api.{tenant}.getomneo.com/api/v3/locations/{location}/nearbyimport requests
url = "https://api.{tenant}.getomneo.com/api/v3/locations/{location}/nearby"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.{tenant}.getomneo.com/api/v3/locations/{location}/nearby', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.{tenant}.getomneo.com/api/v3/locations/{location}/nearby",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.{tenant}.getomneo.com/api/v3/locations/{location}/nearby"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.{tenant}.getomneo.com/api/v3/locations/{location}/nearby")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.{tenant}.getomneo.com/api/v3/locations/{location}/nearby")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"data": [
{
"id": 123,
"handle": "<string>",
"type": "<string>",
"name": "<string>",
"is_published": true,
"is_permanently_closed": true,
"distance_km": 123
}
],
"meta": {
"origin": {
"id": 123,
"has_coordinates": true
},
"skipped": [
{
"id": 123,
"handle": "<string>",
"type": "<string>",
"name": "<string>"
}
]
}
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>",
"errors": {}
}Location
Browse Nearby Locations
A GET to the /locations/{locationId}/nearby endpoint returns every other location in the tenant ordered by
great-circle distance from this location’s address, nearest first, with distance_km on each item.
Locations are included whatever their is_published, is_permanently_closed or type; narrow them with
filter[type] (one type or a comma-separated list) and filter[is_published] (1 or 0), and cap the list with
limit. A location whose address has no latitude and longitude (or 0,0) cannot be placed, so it is listed in
meta.skipped instead. When this location has no coordinates itself, data is empty,
meta.origin.has_coordinates is false and every other location is in meta.skipped.
GET
/
v3
/
locations
/
{location}
/
nearby
Browse Nearby Locations
curl --request GET \
--url https://api.{tenant}.getomneo.com/api/v3/locations/{location}/nearbyimport requests
url = "https://api.{tenant}.getomneo.com/api/v3/locations/{location}/nearby"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.{tenant}.getomneo.com/api/v3/locations/{location}/nearby', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.{tenant}.getomneo.com/api/v3/locations/{location}/nearby",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.{tenant}.getomneo.com/api/v3/locations/{location}/nearby"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.{tenant}.getomneo.com/api/v3/locations/{location}/nearby")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.{tenant}.getomneo.com/api/v3/locations/{location}/nearby")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"data": [
{
"id": 123,
"handle": "<string>",
"type": "<string>",
"name": "<string>",
"is_published": true,
"is_permanently_closed": true,
"distance_km": 123
}
],
"meta": {
"origin": {
"id": 123,
"has_coordinates": true
},
"skipped": [
{
"id": 123,
"handle": "<string>",
"type": "<string>",
"name": "<string>"
}
]
}
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>"
}{
"message": "<string>",
"errors": {}
}