@@ -15,28 +15,35 @@ Parameters:
15
15
16
16
q = a string containing a US street address.
17
17
18
- Returns:
18
+ Returns a GeoJSON feature collection :
19
19
20
20
{
21
- 'address': '41 Decatur St 94103',
22
- 'results': [
23
- { 'number': '41',
24
- 'street': 'Decatur St',
25
- 'city': 'San Francisco',
26
- 'state': 'CA',
27
- 'zip': '94103',
28
- 'fips_county': '06075',
29
- 'lat': 37.772502,
30
- 'lon': -122.406032,
31
- 'precision': 'range',
32
- 'score': 0.812 }
33
- ]
21
+ "type": "FeatureCollection",
22
+ "features": [
23
+ {
24
+ "type": "Feature",
25
+ "properties": {
26
+ "number": "41",
27
+ "street": "Decatur St",
28
+ "city": "San Francisco",
29
+ "state": "CA",
30
+ "zip": "94103",
31
+ "fips_county": "06075",
32
+ "score": 1.0,
33
+ "precision":"range"
34
+ },
35
+ "geometry": {
36
+ "type": "Point",
37
+ "coordinates": [-122.406032, 37.772502]
38
+ }
39
+ }
40
+ ],
41
+ "address":"41 Decatur St, San Francisco CA 94103"
34
42
}
35
43
36
- The 'results' list in the returned JSON object contains zero or more addresses
37
- that most closely match the provided string, along with their interpolated
38
- coordinates. Each address result in the list contains the following key/value
39
- pairs:
44
+
45
+ Each address match in the feature collection contains some combination of the
46
+ following properties:
40
47
41
48
number
42
49
The building number of the address. When a building number is not
86
93
result, expressed as a float between 0 and 1. A higher score indicates
87
94
a closer match. Results with a score below 0.5 should be regarded with
88
95
care.
89
-
90
- lat / lon
91
- The approximate latitude and longitude of the geocoded address or
92
- intersection, given as floating point numbers.
93
-
0 commit comments