apoc.spatial.geocodeOnce

Procedure APOC Core

apoc.spatial.geocodeOnce('address') YIELD location, latitude, longitude, description, osmData - look up geographic location of address from a geocoding service (the default one is OpenStreetMap)

Signature

apoc.spatial.geocodeOnce(location :: STRING?) :: (location :: MAP?, data :: MAP?, latitude :: FLOAT?, longitude :: FLOAT?, description :: STRING?)

Input parameters

Name Type Default

location

STRING?

null

Output parameters

Name Type

location

MAP?

data

MAP?

latitude

FLOAT?

longitude

FLOAT?

description

STRING?

Usage Examples

CALL apoc.spatial.geocodeOnce('21 rue Paul Bellamy 44000 NANTES FRANCE')
Table 1. Results
location data latitude longitude description

{description: "21, Rue Paul Bellamy, Talensac - Pont Morand, Hauts-Pavés - Saint-Félix, Nantes, Loire-Atlantique, Pays de la Loire, France métropolitaine, 44000, France", latitude: 47.2221667, longitude: -1.5566625}

{osm_type: "node", osm_id: 1730317979, licence: "Data © OpenStreetMap contributors, ODbL 1.0. https://osm.org/copyright", boundingbox: ["47.2221167", "47.2222167", "-1.5567125", "-1.5566125"], importance: 0.721, lon: "-1.5566625", display_name: "21, Rue Paul Bellamy, Talensac - Pont Morand, Hauts-Pavés - Saint-Félix, Nantes, Loire-Atlantique, Pays de la Loire, France métropolitaine, 44000, France", type: "house", class: "place", place_id: 17843897, lat: "47.2221667"}

47.2221667

-1.5566625

"21, Rue Paul Bellamy, Talensac - Pont Morand, Hauts-Pavés - Saint-Félix, Nantes, Loire-Atlantique, Pays de la Loire, France métropolitaine, 44000, France"