Restaurant menu search Api

放肆的年华 提交于 2019-12-06 16:25:41

问题


I'm would like to develop an application which searches restaurants in a given location and also displays the restaurant's menu details.

Are there any existing APIs which I could reuse to develop such a restaurant search?


回答1:


yes you can use Yahoo local search API for this. see this link for more info.. http://developer.yahoo.com/search/local/V3/localSearch.html




回答2:


You can also try using the Locu API

Documentation: https://dev.locu.com/documentation/

The basic query that I used to get menu information of restaurants by location is shown below:

curl -X POST https://api.locu.com/v2/venue/search -d '{  
    "api_key" : "[insert api key]",  
    "fields" : [ "name", "menus" ],  
    "venue_queries" : 
        [    
            {      
                "location" : 
                    {
                        "locality" : ["insert city name"]
                    }   
            }  
        ]
}'

I then used http://curl.trillworks.com to convert my query into python (with the requests module) to actually perform the data pull. I hope this helps!



来源:https://stackoverflow.com/questions/6454795/restaurant-menu-search-api

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!