From street addresses to geographical coordinates (and vice versa) in just a second
The Geocoding Service is available for 196 countries, with high-precision mapping
All the knowledge you need
Here you can find some advice to consider to approach this API. If you prefer, we provide code samples, OAS3 documentation, the ability to try the API live via the Swagger UI or import the entire collection into Postman. We also offer a Sandbox environment where you can experiment with all kinds of requests completely free of charge.
Useful tips to start with
Geocoding
Get the token in the appropriate section before you start.
Use the the online tool or generate it via API. Set the expire date, a usefull name and now add a bunch of scopes to limit the possible actions your token can do.
Start Geocoding!
Choose if you want to start from an address and convert it to coordinates or the reverse.
- Oas file url https://console.openapi.com/oas/en/geocoding.openapi.json
- Fork or import with Postman
- Production domain geocoding.openapi.it
- Sandbox domain test.geocoding.openapi.it
- Production Scopes 2
-
Sandbox Scopes 2
- POST test.geocoding.openapi.it/geocode
- POST test.geocoding.openapi.it/reverse
Geocoding Api (1.0.0)
Geocoding Api Documentation
Retrieve informations about a place supplying address
Authorizations:
bearerAuth
Request Body schema: application/json
To improve success of results, please specify an address conforming to the following format: [street], [city] [postal code] [country]
address required | string |
Responses
Response Schema: application/json
success | string |
object |
Request samples
- Payload
- C + Libcurl
- Csharp + Restsharp
- Go + Native
- Java + Okhttp
- Java + Unirest
- Javascript + Jquery
- Javascript + Xhr
- Node + Native
- Node + Request
- Node + Unirest
- Objc + Nsurlsession
- Ocaml + Cohttp
- Php + Curl
- Php + Http1
- Php + Http2
- Python + Python3
- Python + Requests
- Ruby + Native
- Shell + Curl
- Shell + Httpie
- Shell + Wget
- Swift + Nsurlsession
Content type
application/json
{
- "address": "Via Cristoforo Colombo, Roma RM"
Response samples
- 200
Content type
application/json
{
- "success": "true",
- "elements": {
- "id": "v442c6653ee93a5733e8a9ea2f842cd5c250d2b6ab",
- "element": {
- "providedBy": "google_maps | openstreetmap",
- "latitude": 41.808916,
- "longitude": 12.4535602,
- "bounds": {
- "south": 41.7691104,
- "west": 12.3831487,
- "north": 41.8731993,
- "east": 12.4985637
- "streetNumber": "null",
- "streetName": "Via Cristoforo Colombo",
- "postalCode": "04019",
- "locality": "Roma",
- "subLocality": "null",
- "adminLevels": {
- "1": {
- "name": "Lazio",
- "code": "Lazio",
- "level": 1
- "2": {
- "name": "Citta Metropolitana di Roma",
- "code": "RM",
- "level": 2
- "3": {
- "name": "Roma",
- "code": "Roma",
- "level": 3
- "country": "Italy",
- "countryCode": "IT",
- "timezone": "null"
Get place information from ID or latitude/longitude
Authorizations:
bearerAuth
Request Body schema: application/json
Get place information from ID or latitude/longitude:
- To obtain infos via ID make sure to pass the following format:
{"type": "id", "id": "<id>"}
- To obtain infos via lat/long, make sure to provide the following format:
{"type": "coordinates", "lat": "<lat>", "long": "<long>"}
id | string |
type required | string |
lat | number <float> |
long | number <float> |
Responses
Response Schema: application/json
success | string |
object |
Request samples
- Payload
- C + Libcurl
- Csharp + Restsharp
- Go + Native
- Java + Okhttp
- Java + Unirest
- Javascript + Jquery
- Javascript + Xhr
- Node + Native
- Node + Request
- Node + Unirest
- Objc + Nsurlsession
- Ocaml + Cohttp
- Php + Curl
- Php + Http1
- Php + Http2
- Python + Python3
- Python + Requests
- Ruby + Native
- Shell + Curl
- Shell + Httpie
- Shell + Wget
- Swift + Nsurlsession
Content type
application/json
{
- "id": "v442c6653ee93a5733e8a9ea2f842cd5c250d2b6ab",
- "type": "id | coordinates",
- "lat": 41.289294,
- "long": 13.2349029
Response samples
- 200
Content type
application/json
{
- "success": "true",
- "elements": {
- "id": "v442c6653ee93a5733e8a9ea2f842cd5c250d2b6ab",
- "element": {
- "providedBy": "google_maps | openstreetmap",
- "latitude": 41.808916,
- "longitude": 12.4535602,
- "bounds": {
- "south": 41.7691104,
- "west": 12.3831487,
- "north": 41.8731993,
- "east": 12.4985637
- "streetNumber": "null",
- "streetName": "Via Cristoforo Colombo",
- "postalCode": "04019",
- "locality": "Roma",
- "subLocality": "null",
- "adminLevels": {
- "1": {
- "name": "Lazio",
- "code": "Lazio",
- "level": 1
- "2": {
- "name": "Citta Metropolitana di Roma",
- "code": "RM",
- "level": 2
- "3": {
- "name": "Roma",
- "code": "Roma",
- "level": 3
- "country": "Italy",
- "countryCode": "IT",
- "timezone": "null"