curl --request GET \
--url https://api.justrouting.tech/geocode/v1/search \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.justrouting.tech/geocode/v1/search"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.justrouting.tech/geocode/v1/search', 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.justrouting.tech/geocode/v1/search",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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.justrouting.tech/geocode/v1/search"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.justrouting.tech/geocode/v1/search")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.justrouting.tech/geocode/v1/search")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"results": [
{
"datasource": {
"sourcename": "<string>",
"attribution": "<string>",
"license": "<string>",
"url": "<string>"
},
"name": "<string>",
"housenumber": "<string>",
"street": "<string>",
"suburb": "<string>",
"district": "<string>",
"postcode": "<string>",
"city": "<string>",
"county": "<string>",
"state": "<string>",
"country": "<string>",
"country_code": "<string>",
"lon": 123,
"lat": 123,
"formatted": "<string>",
"address_line1": "<string>",
"address_line2": "<string>",
"category": "<string>",
"result_type": "<string>",
"rank": {
"importance": 123,
"popularity": 123,
"confidence": 123,
"confidence_city_level": 123,
"confidence_street_level": 123,
"match_type": "<string>"
},
"timezone": {
"name": "<string>",
"offset_STD": "<string>",
"offset_DST": "<string>",
"offset_STD_seconds": 123,
"offset_DST_seconds": 123,
"abbreviation_STD": "<string>",
"abbreviation_DST": "<string>"
},
"plus_code": "<string>",
"place_id": "<string>",
"bbox": {
"lon1": 123,
"lat1": 123,
"lon2": 123,
"lat2": 123
},
"distance": 123
}
],
"query": {
"text": "<string>",
"parsed": {}
}
}{
"statusCode": 123,
"error": "<string>",
"message": "<string>"
}{
"error": "<string>"
}{
"code": "rate_limited",
"message": "<string>"
}{
"statusCode": 123,
"error": "<string>",
"message": "<string>"
}geocode
Find a place by name or address and get its coordinates
curl --request GET \
--url https://api.justrouting.tech/geocode/v1/search \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.justrouting.tech/geocode/v1/search"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.justrouting.tech/geocode/v1/search', 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.justrouting.tech/geocode/v1/search",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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.justrouting.tech/geocode/v1/search"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.justrouting.tech/geocode/v1/search")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.justrouting.tech/geocode/v1/search")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"results": [
{
"datasource": {
"sourcename": "<string>",
"attribution": "<string>",
"license": "<string>",
"url": "<string>"
},
"name": "<string>",
"housenumber": "<string>",
"street": "<string>",
"suburb": "<string>",
"district": "<string>",
"postcode": "<string>",
"city": "<string>",
"county": "<string>",
"state": "<string>",
"country": "<string>",
"country_code": "<string>",
"lon": 123,
"lat": 123,
"formatted": "<string>",
"address_line1": "<string>",
"address_line2": "<string>",
"category": "<string>",
"result_type": "<string>",
"rank": {
"importance": 123,
"popularity": 123,
"confidence": 123,
"confidence_city_level": 123,
"confidence_street_level": 123,
"match_type": "<string>"
},
"timezone": {
"name": "<string>",
"offset_STD": "<string>",
"offset_DST": "<string>",
"offset_STD_seconds": 123,
"offset_DST_seconds": 123,
"abbreviation_STD": "<string>",
"abbreviation_DST": "<string>"
},
"plus_code": "<string>",
"place_id": "<string>",
"bbox": {
"lon1": 123,
"lat1": 123,
"lon2": 123,
"lat2": 123
},
"distance": 123
}
],
"query": {
"text": "<string>",
"parsed": {}
}
}{
"statusCode": 123,
"error": "<string>",
"message": "<string>"
}{
"error": "<string>"
}{
"code": "rate_limited",
"message": "<string>"
}{
"statusCode": 123,
"error": "<string>",
"message": "<string>"
}Authorizations
API key created in the JustRouting dashboard.
Query Parameters
Free-form address to search, e.g. Marina Bay Sands, Singapore. Mutually exclusive with the structured fields.
Name of the place, e.g. Marina Bay Sands.
House or building number, e.g. 10.
Street name, e.g. Bayfront Avenue.
Postal code, e.g. 018956.
City or locality, e.g. Singapore.
State or region.
Country, e.g. Singapore — the strongest disambiguator for common, abbreviated, or misspelled names.
Maximum number of results to return.
Skip the first offset results before applying limit.
Restrict results, e.g. countrycode:sg; repeatable, all filters apply.
Steer results toward a location, e.g. proximity:103.8,1.3; adds a distance field to each result.
Restrict to a feature type, e.g. street or city.
Preferred language for results, e.g. en.
Response format; json is the only documented value.
