Datasets
Hunch will periodically document datasets for different verticals, which can easily be used through our API.
Local Dataset
The Hunch API includes a large number of "local" results, such as restaurants, bars, and many other establishments and attractions. This data is the basis for the Hunch Local iPhone app and the Hunch Local website. You can easily use this data as well, taking advantage of the taste data we've already gathered.
To access local results in a particular region you can simply pass a bounding circle or bounding rectangle to most API calls. For example, your top 10 local recommendations in part of New York's East Village are given by the following call.
(This link will prompt you for your Hunch username and password.)
http://api.hunch.com/api/v1/get-recommendations/?limit=10&minlat=40.723835017067124&maxlat=40.72892482083397&minlng=-73.99518249472045&maxlng=-73.97715805014037
Often you will want to restrict your search to certain types of local result. To do so, you can restrict your search to one or more topics. Local data is contained in several API topics, all children of the cat_local topic, for example:
- Clothing Stores -
list_clothing-store - Coffee Shops -
list_coffee-shop - Grocery Stores -
list_grocery-store - Hotels -
list_hotel - Museums -
list_museum - Restaurants -
list_restaurant - Spas -
list_spa - ... and many more in the
cat_localtopic; see the list of API topics.
Thus we can restrict the above call to only coffee shop recommendations by adding a topic_ids parameter:
http://api.hunch.com/api/v1/get-recommendations/?limit=10&minlat=40.723835017067124&maxlat=40.72892482083397&minlng=-73.99518249472045&maxlng=-73.97715805014037&topic_ids=list_coffee-shop
You can pass these geographic and topic parameters not only to get-recommendations, but also to get-results for simply fetching un-personalized result data, get-similar-results for finding results similar to a particular result, get-activity for getting recent user activity in a set of results, and several other methods. Give them a try in the API console, and then build something cool!