1. Home
  2. Docs
  3. Open Trip Planner
  4. Getting Places

Getting Places

Start typing “Scripps C” into the Destination box and an Elasticsearch database will return possible destinations.

The request to Pelias look like this:

curl 'https://pelias.metroservices.io/v1/search?boundary.rect.max_lat=34.823193&boundary.rect.max_lon=-117.645604&boundary.rect.min_lat=32.75004&boundary.rect.min_lon=-118.951721&focus.point.lat=34.0528978&focus.point.lon=-118.2857686&ignoreLoadingBar=true&size=10&text=scripps%20college' \
-XGET \
-H 'Accept: application/json, text/plain, /' \
-H 'Accept-Encoding: br, gzip, deflate' \
-H 'Connection: keep-alive'

The reply

{
     "geocoding": {
         "version": "0.2",
         "attribution": "http://pelias.mapzen.com/v1/attribution",
         "query": {
             "text": "scripps college",
             "size": 10,
             "private": false,
             "focus.point.lat": 34.0528978,
             "focus.point.lon": -118.2857686,
             "boundary.rect.min_lat": 32.75004,
             "boundary.rect.max_lat": 34.823193,
             "boundary.rect.min_lon": -118.951721,
             "boundary.rect.max_lon": -117.645604,
             "lang": {
                 "name": "English",
                 "iso6391": "en",
                 "iso6393": "eng",
                 "defaulted": false
             },
             "querySize": 20
         },
         "engine": {
             "name": "Pelias",
             "author": "Mapzen",
             "version": "1.0"
         },
         "timestamp": 1569544024707
     },
     "type": "FeatureCollection",
     "features": [
         {
             "type": "Feature",
             "geometry": {
                 "type": "Point",
                 "coordinates": [
                     -117.71035,
                     34.10387
                 ]
             },
             "properties": {
                 "id": "5394015",
                 "gid": "geonames:venue:5394015",
                 "layer": "venue",
                 "source": "geonames",
                 "source_id": "5394015",
                 "name": "Scripps College",
                 "confidence": 0.957,
                 "distance": 53.411,
                 "accuracy": "point",
                 "country": "United States",
                 "country_gid": "whosonfirst:country:85633793",
                 "country_a": "USA",
                 "region": "California",
                 "region_gid": "whosonfirst:region:85688637",
                 "region_a": "CA",
                 "county": "Los Angeles County",
                 "county_gid": "whosonfirst:county:102086957",
                 "locality": "Claremont",
                 "locality_gid": "whosonfirst:locality:85923671",
                 "neighbourhood": "North Pomona",
                 "neighbourhood_gid": "whosonfirst:neighbourhood:85837921",
                 "label": "Scripps College, Claremont, CA, USA"
             }
         },
         {
             "type": "Feature",
             "geometry": {
                 "type": "Point",
                 "coordinates": [
                     -117.712471,
                     34.105087
                 ]
             },
             "properties": {
                 "id": "node:3835545349",
                 "gid": "openstreetmap:venue:node:3835545349",
                 "layer": "venue",
                 "source": "openstreetmap",
                 "source_id": "node:3835545349",
                 "name": "Scripps College Press",
                 "confidence": 0.89,
                 "distance": 53.231,
                 "accuracy": "point",
                 "country": "United States",
                 "country_gid": "whosonfirst:country:85633793",
                 "country_a": "USA",
                 "region": "California",
                 "region_gid": "whosonfirst:region:85688637",
                 "region_a": "CA",
                 "county": "Los Angeles County",
                 "county_gid": "whosonfirst:county:102086957",
                 "locality": "Claremont",
                 "locality_gid": "whosonfirst:locality:85923671",
                 "neighbourhood": "North Pomona",
                 "neighbourhood_gid": "whosonfirst:neighbourhood:85837921",
                 "label": "Scripps College Press, Claremont, CA, USA"
             }
         },
         {
             "type": "Feature",
             "geometry": {
                 "type": "Point",
                 "coordinates": [
                     -117.70816,
                     34.103843
                 ]
             },
             "properties": {
                 "id": "way:150583701",
                 "gid": "openstreetmap:venue:way:150583701",
                 "layer": "venue",
                 "source": "openstreetmap",
                 "source_id": "way:150583701",
                 "name": "Scripps Pool",
                 "confidence": 0.66,
                 "distance": 53.612,
                 "accuracy": "point",
                 "country": "United States",
                 "country_gid": "whosonfirst:country:85633793",
                 "country_a": "USA",
                 "region": "California",
                 "region_gid": "whosonfirst:region:85688637",
                 "region_a": "CA",
                 "county": "Los Angeles County",
                 "county_gid": "whosonfirst:county:102086957",
                 "locality": "Claremont",
                 "locality_gid": "whosonfirst:locality:85923671",
                 "label": "Scripps Pool, Claremont, CA, USA"
             },
             "bbox": [
                 -117.708293,
                 34.103655,
                 -117.707997,
                 34.103885
             ]
         },
         {
             "type": "Feature",
             "geometry": {
                 "type": "Point",
                 "coordinates": [
                     -117.73296,
                     34.116443
                 ]
             },
             "properties": {
                 "id": "us/ca/los_angeles:4149a18374f6137d",
                 "gid": "openaddresses:address:us/ca/los_angeles:4149a18374f6137d",
                 "layer": "address",
                 "source": "openaddresses",
                 "source_id": "us/ca/los_angeles:4149a18374f6137d",
                 "name": "964 Scripps Dr",
                 "housenumber": "964",
                 "street": "Scripps Dr",
                 "postalcode": "91711",
                 "confidence": 0.66,
                 "distance": 51.505,
                 "accuracy": "point",
                 "country": "United States",
                 "country_gid": "whosonfirst:country:85633793",
                 "country_a": "USA",
                 "region": "California",
                 "region_gid": "whosonfirst:region:85688637",
                 "region_a": "CA",
                 "county": "Los Angeles County",
                 "county_gid": "whosonfirst:county:102086957",
                 "locality": "Claremont",
                 "locality_gid": "whosonfirst:locality:85923671",
                 "neighbourhood": "North Pomona",
                 "neighbourhood_gid": "whosonfirst:neighbourhood:85837921",
                 "label": "964 Scripps Dr, Claremont, CA, USA"
             }
         },
         {
             "type": "Feature",
             "geometry": {
                 "type": "Point",
                 "coordinates": [
                     -117.731802,
                     34.116915
                 ]
             },
             "properties": {
                 "id": "us/ca/los_angeles:0711fc8c71423e86",
                 "gid": "openaddresses:address:us/ca/los_angeles:0711fc8c71423e86",
                 "layer": "address",
                 "source": "openaddresses",
                 "source_id": "us/ca/los_angeles:0711fc8c71423e86",
                 "name": "929 Scripps Dr",
                 "housenumber": "929",
                 "street": "Scripps Dr",
                 "postalcode": "91711",
                 "confidence": 0.66,
                 "distance": 51.618,
                 "accuracy": "point",
                 "country": "United States",
                 "country_gid": "whosonfirst:country:85633793",
                 "country_a": "USA",
                 "region": "California",
                 "region_gid": "whosonfirst:region:85688637",
                 "region_a": "CA",
                 "county": "Los Angeles County",
                 "county_gid": "whosonfirst:county:102086957",
                 "locality": "Claremont",
                 "locality_gid": "whosonfirst:locality:85923671",
                 "neighbourhood": "North Pomona",
                 "neighbourhood_gid": "whosonfirst:neighbourhood:85837921",
                 "label": "929 Scripps Dr, Claremont, CA, USA"
             }
         },
         {
             "type": "Feature",
             "geometry": {
                 "type": "Point",
                 "coordinates": [
                     -117.73137,
                     34.1164
                 ]
             },
             "properties": {
                 "id": "us/ca/los_angeles:ab50436f0cf15d7b",
                 "gid": "openaddresses:address:us/ca/los_angeles:ab50436f0cf15d7b",
                 "layer": "address",
                 "source": "openaddresses",
                 "source_id": "us/ca/los_angeles:ab50436f0cf15d7b",
                 "name": "916 Scripps Dr",
                 "housenumber": "916",
                 "street": "Scripps Dr",
                 "postalcode": "91711",
                 "confidence": 0.66,
                 "distance": 51.65,
                 "accuracy": "point",
                 "country": "United States",
                 "country_gid": "whosonfirst:country:85633793",
                 "country_a": "USA",
                 "region": "California",
                 "region_gid": "whosonfirst:region:85688637",
                 "region_a": "CA",
                 "county": "Los Angeles County",
                 "county_gid": "whosonfirst:county:102086957",
                 "locality": "Claremont",
                 "locality_gid": "whosonfirst:locality:85923671",
                 "neighbourhood": "North Pomona",
                 "neighbourhood_gid": "whosonfirst:neighbourhood:85837921",
                 "label": "916 Scripps Dr, Claremont, CA, USA"
             }
         },
         {
             "type": "Feature",
             "geometry": {
                 "type": "Point",
                 "coordinates": [
                     -117.734008,
                     34.117076
                 ]
             },
             "properties": {
                 "id": "us/ca/los_angeles:91fb29d81ed999d0",
                 "gid": "openaddresses:address:us/ca/los_angeles:91fb29d81ed999d0",
                 "layer": "address",
                 "source": "openaddresses",
                 "source_id": "us/ca/los_angeles:91fb29d81ed999d0",
                 "name": "1005 Scripps Dr",
                 "housenumber": "1005",
                 "street": "Scripps Dr",
                 "postalcode": "91711",
                 "confidence": 0.66,
                 "distance": 51.419,
                 "accuracy": "point",
                 "country": "United States",
                 "country_gid": "whosonfirst:country:85633793",
                 "country_a": "USA",
                 "region": "California",
                 "region_gid": "whosonfirst:region:85688637",
                 "region_a": "CA",
                 "county": "Los Angeles County",
                 "county_gid": "whosonfirst:county:102086957",
                 "locality": "Claremont",
                 "locality_gid": "whosonfirst:locality:85923671",
                 "neighbourhood": "North Pomona",
                 "neighbourhood_gid": "whosonfirst:neighbourhood:85837921",
                 "label": "1005 Scripps Dr, Claremont, CA, USA"
             }
         },
         {
             "type": "Feature",
             "geometry": {
                 "type": "Point",
                 "coordinates": [
                     -117.710167,
                     34.105136
                 ]
             },
             "properties": {
                 "id": "node:3835498805",
                 "gid": "openstreetmap:venue:node:3835498805",
                 "layer": "venue",
                 "source": "openstreetmap",
                 "source_id": "node:3835498805",
                 "name": "Scripps Graffiti Wall",
                 "confidence": 0.66,
                 "distance": 53.443,
                 "accuracy": "point",
                 "country": "United States",
                 "country_gid": "whosonfirst:country:85633793",
                 "country_a": "USA",
                 "region": "California",
                 "region_gid": "whosonfirst:region:85688637",
                 "region_a": "CA",
                 "county": "Los Angeles County",
                 "county_gid": "whosonfirst:county:102086957",
                 "locality": "Claremont",
                 "locality_gid": "whosonfirst:locality:85923671",
                 "label": "Scripps Graffiti Wall, Claremont, CA, USA"
             }
         },
         {
             "type": "Feature",
             "geometry": {
                 "type": "Point",
                 "coordinates": [
                     -117.710183,
                     34.104966
                 ]
             },
             "properties": {
                 "id": "node:3835500790",
                 "gid": "openstreetmap:venue:node:3835500790",
                 "layer": "venue",
                 "source": "openstreetmap",
                 "source_id": "node:3835500790",
                 "name": "Scripps Rose Garden",
                 "confidence": 0.66,
                 "distance": 53.439,
                 "accuracy": "point",
                 "country": "United States",
                 "country_gid": "whosonfirst:country:85633793",
                 "country_a": "USA",
                 "region": "California",
                 "region_gid": "whosonfirst:region:85688637",
                 "region_a": "CA",
                 "county": "Los Angeles County",
                 "county_gid": "whosonfirst:county:102086957",
                 "locality": "Claremont",
                 "locality_gid": "whosonfirst:locality:85923671",
                 "label": "Scripps Rose Garden, Claremont, CA, USA"
             }
         },
         {
             "type": "Feature",
             "geometry": {
                 "type": "Point",
                 "coordinates": [
                     -117.72559,
                     34.116332
                 ]
             },
             "properties": {
                 "id": "us/ca/los_angeles:388766e99ca7c57e",
                 "gid": "openaddresses:address:us/ca/los_angeles:388766e99ca7c57e",
                 "layer": "address",
                 "source": "openaddresses",
                 "source_id": "us/ca/los_angeles:388766e99ca7c57e",
                 "name": "656 Scripps Dr",
                 "housenumber": "656",
                 "street": "Scripps Dr",
                 "postalcode": "91711",
                 "confidence": 0.66,
                 "distance": 52.177,
                 "accuracy": "point",
                 "country": "United States",
                 "country_gid": "whosonfirst:country:85633793",
                 "country_a": "USA",
                 "region": "California",
                 "region_gid": "whosonfirst:region:85688637",
                 "region_a": "CA",
                 "county": "Los Angeles County",
                 "county_gid": "whosonfirst:county:102086957",
                 "locality": "Claremont",
                 "locality_gid": "whosonfirst:locality:85923671",
                 "neighbourhood": "North Pomona",
                 "neighbourhood_gid": "whosonfirst:neighbourhood:85837921",
                 "label": "656 Scripps Dr, Claremont, CA, USA"
             }
         }
     ],
     "bbox": [
         -117.734008,
         34.103655,
         -117.707997,
         34.117076
     ]
 }
Was this article helpful to you? Yes No

How can we help?

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.