I’m spending time diving into 11 of the places data APIs to see how CityGrid stacks up, but also to learn the inner workings of all of them. CityGrid has a great attitude towards the space, and looks to play with all of them. This is another segment in that series.
In this segment I’m looking specifically at the API request structure for CityGrid, Google and Yelp. I recently built an interactive places API comparison tool, and to do so I had to harmonize the requests across all three APIs, and here is what I learned.
CityGrid offers two endpoints:
- What – A single keyword or phrase providing the topical filtering.
- Where – A textual search allowing you to search by cities, neighborhoods, zip codes, metro areas, addresses and intersections.
- Latitude / Longitude – A longitude / latitude based search that can use two points or bounding boxes.
You can further refine searches with a radius and sort by distance, alphabetically, highestrated, mostreviewed, top matches and offers.
Google, you can accomplish the same thing, but they go about it a little differently. Every search has two sides:
- What – A keyword filter to apply the topic your searching for.
- Where – A location which is two point or bounding box longitude and latitude.
At first glance it seems limiting, but you can use the Google Geocoding API to convert any textual location in a longitude and latitude location. Once you have geocoded your location, you can use the Places API to search for places, and apply a radius to limit or expand the search. I don’t see any sort criteria currently.
Yelp is similar to the CityGrid approach in that they provide three ways to provide the “where” for a places search:
- Term - A single keyword or phrase providing the topical filtering.
- Bounding Box – A four point latitude and longitude search for NE and SW lat /long.
- Geo Coordinates – A two point latitude and longitude search which includes accuracy and altitude settings.
- Textual – Location by neighborhood, address, or by city.
All three leading places API provide robust interfaces allowing you to find businesses and other places via an API through textual or latitude and longitude searches. Of course I’m biased because I work for CityGrid, but CityGrid seems the most robust in the amount of controls over your request. I’d put Yelp second, then Google. But Google is, in their own lable in Beta. So I’m sure there is more coming down the pipes.
Stay tuned for more in my places data API comparison, next up responses.