Zomato JSON响应

时间:2018-09-04 09:41:52

标签: json node.js api zomato-api

我有以下代码来从Zomato API获取JSON响应。

// Zomato 
function zomatoStart(){
  var client = zomato.createClient({
    userKey: apiKeyZmato
  });

  client.getGeocode({
    lat: latLocation, //latitude
    lon: longLocation, //longitude
    }, function(err, result){
        if(!err){
         var jsonContent = JSON.parse(result);
         console.log(jsonContent.nearby_restaurants[0]);
        }else {
          console.log(err);
        }
    });
}

我从中获得的JSON响应如下:

{ restaurant: 
   { R: { res_id: 16591979 },
     apikey: '3fd7e9f90961452a3ffc81ebc6b87513',
     id: '16591979',
     name: 'Wagaya',
     url: 'https://www.zomato.com/brisbane/wagaya-fortitude-valley?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1',
     location: 
      { address: 'Chinatown Mall, Level 1, 315 Brunswick Street, Fortitude Valley, Brisbane',
        locality: 'Chinatown Mall',
        city: 'Brisbane',
        city_id: 298,
        latitude: '-27.4585653042',
        longitude: '153.0339020491',
        zipcode: '4006',
        country_id: 14,
        locality_verbose: 'Chinatown Mall, Brisbane' },
     switch_to_order_menu: 0,
     cuisines: 'Japanese, Sushi',
     average_cost_for_two: 100,
     price_range: 4,
     currency: '$',
     offers: [],
     opentable_support: 0,
     is_zomato_book_res: 0,
     mezzo_provider: 'OTHER',
     is_book_form_web_view: 0,
     book_form_web_view_url: '',
     book_again_url: '',
     thumb: 'https://b.zmtcdn.com/data/res_imagery/16591979_RESTAURANT_f84903806912e0fb5ce5a7afc437c1af_c.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A',
     user_rating: 
      { aggregate_rating: '4.6',
        rating_text: 'Excellent',
        rating_color: '3F7E00',
        votes: '1411' },
     photos_url: 'https://www.zomato.com/brisbane/wagaya-fortitude-valley/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop',
     menu_url: 'https://www.zomato.com/brisbane/wagaya-fortitude-valley/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop',
     featured_image: 'https://b.zmtcdn.com/data/res_imagery/16591979_RESTAURANT_f84903806912e0fb5ce5a7afc437c1af_c.jpg',
     has_online_delivery: 0,
     is_delivering_now: 0,
     include_bogo_offers: true,
     deeplink: 'zomato://restaurant/16591979',
     is_table_reservation_supported: 0,
     has_table_booking: 0,
     events_url: 'https://www.zomato.com/brisbane/wagaya-fortitude-valley/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1' } }

我尝试了很多方法,但是无法到达JSON响应的“纬度”和“经度”区域,所以我总是得到“ TypeError:无法读取未定义的属性........”。哪条线可以帮助我达到目标?我以为会是这样,但是没有用。

jsonContent.nearby_restaurants [0] .restaurant [0] .location.latitude

下面是原始JSON

{"location":{"entity_type":"subzone","entity_id":98812,"title":"Brisbane CBD","latitude":"-27.4700750000","longitude":"153.0265130000","city_id":298,"city_name":"Brisbane","country_id":14,"country_name":"Australia"},"popularity":{"popularity":"5.00","nightlife_index":"4.49","nearby_res":["16591979","16594096","16613418","16590186","16595540","16590496","16591972","16592280","16591604"],"top_cuisines":["Cafe Food","Coffee and Tea","Modern Australian","Japanese","Sandwich"],"popularity_res":"100","nightlife_res":"10","subzone":"Brisbane CBD","subzone_id":98812,"city":"Brisbane"},"link":"https:\/\/www.zomato.com\/brisbane\/brisbane-cbd-restaurants","nearby_restaurants":[{"restaurant":{"R":{"res_id":16591979},"apikey":"3fd7e9f90961452a3ffc81ebc6b87513","id":"16591979","name":"Wagaya","url":"https:\/\/www.zomato.com\/brisbane\/wagaya-fortitude-valley?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1","location":{"address":"Chinatown Mall, Level 1, 315 Brunswick Street, Fortitude Valley, Brisbane","locality":"Chinatown Mall","city":"Brisbane","city_id":298,"latitude":"-27.4585653042","longitude":"153.0339020491","zipcode":"4006","country_id":14,"locality_verbose":"Chinatown Mall, Brisbane"},"switch_to_order_menu":0,"cuisines":"Japanese, Sushi","average_cost_for_two":100,"price_range":4,"currency":"$","offers":[],"opentable_support":0,"is_zomato_book_res":0,"mezzo_provider":"OTHER","is_book_form_web_view":0,"book_form_web_view_url":"","book_again_url":"","thumb":"https:\/\/b.zmtcdn.com\/data\/res_imagery\/16591979_RESTAURANT_f84903806912e0fb5ce5a7afc437c1af_c.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A","user_rating":{"aggregate_rating":"4.6","rating_text":"Excellent","rating_color":"3F7E00","votes":"1411"},"photos_url":"https:\/\/www.zomato.com\/brisbane\/wagaya-fortitude-valley\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop","menu_url":"https:\/\/www.zomato.com\/brisbane\/wagaya-fortitude-valley\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop","featured_image":"https:\/\/b.zmtcdn.com\/data\/res_imagery\/16591979_RESTAURANT_f84903806912e0fb5ce5a7afc437c1af_c.jpg","has_online_delivery":0,"is_delivering_now":0,"include_bogo_offers":true,"deeplink":"zomato:\/\/restaurant\/16591979","is_table_reservation_supported":0,"has_table_booking":0,"events_url":"https:\/\/www.zomato.com\/brisbane\/wagaya-fortitude-valley\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"}},{"restaurant":{"R":{"res_id":16594096},"apikey":"3fd7e9f90961452a3ffc81ebc6b87513","id":"16594096","name":"Miel Container","url":"https:\/\/www.zomato.com\/brisbane\/miel-container-brisbane-cbd?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1","location":{"address":"Corner Of Mary Street and Albert Street, Brisbane CBD, Brisbane","locality":"Brisbane CBD","city":"Brisbane","city_id":298,"latitude":"-27.4720173817","longitude":"153.0271288008","zipcode":"4000","country_id":14,"locality_verbose":"Brisbane CBD, Brisbane"},"switch_to_order_menu":0,"cuisines":"Burger","average_cost_for_two":45,"price_range":2,"currency":"$","offers":[],"opentable_support":0,"is_zomato_book_res":0,"mezzo_provider":"OTHER","is_book_form_web_view":0,"book_form_web_view_url":"","book_again_url":"","thumb":"https:\/\/b.zmtcdn.com\/data\/res_imagery\/16594096_CHAIN_fc3bfbd3250c1cbc120f53436e7dafb7.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A","user_rating":{"aggregate_rating":"4.8","rating_text":"Excellent","rating_color":"3F7E00","votes":"756"},"photos_url":"https:\/\/www.zomato.com\/brisbane\/miel-container-brisbane-cbd\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop","menu_url":"https:\/\/www.zomato.com\/brisbane\/miel-container-brisbane-cbd\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop","featured_image":"https:\/\/b.zmtcdn.com\/data\/res_imagery\/16594096_CHAIN_fc3bfbd3250c1cbc120f53436e7dafb7.jpg","has_online_delivery":0,"is_delivering_now":0,"include_bogo_offers":true,"deeplink":"zomato:\/\/restaurant\/16594096","is_table_reservation_supported":0,"has_table_booking":0,"events_url":"https:\/\/www.zomato.com\/brisbane\/miel-container-brisbane-cbd\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"}},{"restaurant":{"R":{"res_id":16613418},"apikey":"3fd7e9f90961452a3ffc81ebc6b87513","id":"16613418","name":"Oreily's","url":"https:\/\/www.zomato.com\/ballogie-qld\/oreilys-canungra?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1","location":{"address":"lamington national park road, Canungra","locality":"Ballogie","city":"Ballogie","city_id":2632,"latitude":"-27.4688800000","longitude":"153.0228270000","zipcode":"4275","country_id":14,"locality_verbose":"Ballogie, Ballogie"},"switch_to_order_menu":0,"cuisines":"Diner, Pizza","average_cost_for_two":20,"price_range":2,"currency":"$","offers":[],"opentable_support":0,"is_zomato_book_res":0,"mezzo_provider":"OTHER","is_book_form_web_view":0,"book_form_web_view_url":"","book_again_url":"","thumb":"","user_rating":{"aggregate_rating":"0","rating_text":"Not rated","rating_color":"CBCBC8","votes":"3"},"photos_url":"https:\/\/www.zomato.com\/ballogie-qld\/oreilys-canungra\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop","menu_url":"https:\/\/www.zomato.com\/ballogie-qld\/oreilys-canungra\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop","featured_image":"","has_online_delivery":0,"is_delivering_now":0,"include_bogo_offers":true,"deeplink":"zomato:\/\/restaurant\/16613418","is_table_reservation_supported":0,"has_table_booking":0,"events_url":"https:\/\/www.zomato.com\/ballogie-qld\/oreilys-canungra\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"}},{"restaurant":{"R":{"res_id":16590186},"apikey":"3fd7e9f90961452a3ffc81ebc6b87513","id":"16590186","name":"The Little Larder","url":"https:\/\/www.zomato.com\/brisbane\/the-little-larder-new-farm?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1","location":{"address":"76 Moray Street, New Farm, Brisbane","locality":"New Farm","city":"Brisbane","city_id":298,"latitude":"-27.4668775902","longitude":"153.0412295088","zipcode":"4005","country_id":14,"locality_verbose":"New Farm, Brisbane"},"switch_to_order_menu":0,"cuisines":"Cafe Food","average_cost_for_two":55,"price_range":2,"currency":"$","offers":[],"opentable_support":0,"is_zomato_book_res":0,"mezzo_provider":"OTHER","is_book_form_web_view":0,"book_form_web_view_url":"","book_again_url":"","thumb":"https:\/\/b.zmtcdn.com\/data\/pictures\/6\/16590186\/f032aa278c03ed8a4608a1b73680d4c0.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A","user_rating":{"aggregate_rating":"4.1","rating_text":"Very Good","rating_color":"5BA829","votes":"803"},"photos_url":"https:\/\/www.zomato.com\/brisbane\/the-little-larder-new-farm\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop","menu_url":"https:\/\/www.zomato.com\/brisbane\/the-little-larder-new-farm\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop","featured_image":"https:\/\/b.zmtcdn.com\/data\/pictures\/6\/16590186\/f032aa278c03ed8a4608a1b73680d4c0.jpg","has_online_delivery":0,"is_delivering_now":0,"include_bogo_offers":true,"deeplink":"zomato:\/\/restaurant\/16590186","is_table_reservation_supported":0,"has_table_booking":0,"events_url":"https:\/\/www.zomato.com\/brisbane\/the-little-larder-new-farm\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"}},{"restaurant":{"R":{"res_id":16595540},"apikey":"3fd7e9f90961452a3ffc81ebc6b87513","id":"16595540","name":"Julius Pizzeria","url":"https:\/\/www.zomato.com\/brisbane\/julius-pizzeria-south-brisbane?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1","location":{"address":"77 Grey Street, South Brisbane, Brisbane","locality":"South Brisbane","city":"Brisbane","city_id":298,"latitude":"-27.4738750608","longitude":"153.0180431530","zipcode":"4101","country_id":14,"locality_verbose":"South Brisbane, Brisbane"},"switch_to_order_menu":0,"cuisines":"Pizza, Italian","average_cost_for_two":80,"price_range":3,"currency":"$","offers":[],"opentable_support":0,"is_zomato_book_res":0,"mezzo_provider":"OTHER","is_book_form_web_view":0,"book_form_web_view_url":"","book_again_url":"","thumb":"https:\/\/b.zmtcdn.com\/data\/res_imagery\/16595540_RESTAURANT_257641802b0296a6ccb17abfe913776e_c.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A","user_rating":{"aggregate_rating":"4.9","rating_text":"Excellent","rating_color":"3F7E00","votes":"342"},"photos_url":"https:\/\/www.zomato.com\/brisbane\/julius-pizzeria-south-brisbane\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop","menu_url":"https:\/\/www.zomato.com\/brisbane\/julius-pizzeria-south-brisbane\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop","featured_image":"https:\/\/b.zmtcdn.com\/data\/res_imagery\/16595540_RESTAURANT_257641802b0296a6ccb17abfe913776e_c.jpg","has_online_delivery":0,"is_delivering_now":0,"include_bogo_offers":true,"deeplink":"zomato:\/\/restaurant\/16595540","is_table_reservation_supported":0,"has_table_booking":0,"events_url":"https:\/\/www.zomato.com\/brisbane\/julius-pizzeria-south-brisbane\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"}},{"restaurant":{"R":{"res_id":16590496},"apikey":"3fd7e9f90961452a3ffc81ebc6b87513","id":"16590496","name":"Verve Restaurant Bar Cider House","url":"https:\/\/www.zomato.com\/brisbane\/verve-restaurant-bar-cider-house-brisbane-cbd?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1","location":{"address":"109 Edward Street, Brisbane CBD, Brisbane","locality":"Brisbane CBD","city":"Brisbane","city_id":298,"latitude":"-27.4701864440","longitude":"153.0288980529","zipcode":"4001","country_id":14,"locality_verbose":"Brisbane CBD, Brisbane"},"switch_to_order_menu":0,"cuisines":"Italian, Pizza","average_cost_for_two":90,"price_range":3,"currency":"$","offers":[],"opentable_support":0,"is_zomato_book_res":0,"mezzo_provider":"OTHER","is_book_form_web_view":0,"book_form_web_view_url":"","book_again_url":"","thumb":"https:\/\/b.zmtcdn.com\/data\/res_imagery\/16590496_RESTAURANT_d2c6e460dfe43cf9872419e499d09c5a.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A","user_rating":{"aggregate_rating":"4.6","rating_text":"Excellent","rating_color":"3F7E00","votes":"965"},"photos_url":"https:\/\/www.zomato.com\/brisbane\/verve-restaurant-bar-cider-house-brisbane-cbd\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop","menu_url":"https:\/\/www.zomato.com\/brisbane\/verve-restaurant-bar-cider-house-brisbane-cbd\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop","featured_image":"https:\/\/b.zmtcdn.com\/data\/res_imagery\/16590496_RESTAURANT_d2c6e460dfe43cf9872419e499d09c5a.jpg","has_online_delivery":0,"is_delivering_now":0,"include_bogo_offers":true,"deeplink":"zomato:\/\/restaurant\/16590496","is_table_reservation_supported":0,"has_table_booking":0,"events_url":"https:\/\/www.zomato.com\/brisbane\/verve-restaurant-bar-cider-house-brisbane-cbd\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"}},{"restaurant":{"R":{"res_id":16591972},"apikey":"3fd7e9f90961452a3ffc81ebc6b87513","id":"16591972","name":"Malt Dining","url":"https:\/\/www.zomato.com\/brisbane\/malt-dining-brisbane-cbd?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1","location":{"address":"28 Market Street, Brisbane CBD, Brisbane","locality":"Brisbane CBD","city":"Brisbane","city_id":298,"latitude":"-27.4695192076","longitude":"153.0294358358","zipcode":"4000","country_id":14,"locality_verbose":"Brisbane CBD, Brisbane"},"switch_to_order_menu":0,"cuisines":"Modern Australian","average_cost_for_two":140,"price_range":4,"currency":"$","offers":[],"opentable_support":0,"is_zomato_book_res":0,"mezzo_provider":"DIMMI","is_book_form_web_view":0,"book_form_web_view_url":"","thumb":"https:\/\/b.zmtcdn.com\/data\/res_imagery\/16591972_RESTAURANT_bb12785af23666f2718b5d7e12c9a9bf.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A","user_rating":{"aggregate_rating":"4.6","rating_text":"Excellent","rating_color":"3F7E00","votes":"777"},"photos_url":"https:\/\/www.zomato.com\/brisbane\/malt-dining-brisbane-cbd\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop","menu_url":"https:\/\/www.zomato.com\/brisbane\/malt-dining-brisbane-cbd\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop","featured_image":"https:\/\/b.zmtcdn.com\/data\/res_imagery\/16591972_RESTAURANT_bb12785af23666f2718b5d7e12c9a9bf.jpg","medio_provider":"","has_online_delivery":0,"is_delivering_now":0,"include_bogo_offers":true,"deeplink":"zomato:\/\/restaurant\/16591972","is_table_reservation_supported":1,"has_table_booking":1,"book_url":"https:\/\/www.zomato.com\/brisbane\/malt-dining-brisbane-cbd\/book?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1","events_url":"https:\/\/www.zomato.com\/brisbane\/malt-dining-brisbane-cbd\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"}},{"restaurant":{"R":{"res_id":16592280},"apikey":"3fd7e9f90961452a3ffc81ebc6b87513","id":"16592280","name":"Maru Korean BBQ","url":"https:\/\/www.zomato.com\/brisbane\/maru-korean-bbq-brisbane-cbd?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1","location":{"address":"157 Elizabeth Street, Brisbane CBD, Brisbane","locality":"Brisbane CBD","city":"Brisbane","city_id":298,"latitude":"-27.4703619536","longitude":"153.0266862363","zipcode":"4000","country_id":14,"locality_verbose":"Brisbane CBD, Brisbane"},"switch_to_order_menu":0,"cuisines":"Korean BBQ","average_cost_for_two":70,"price_range":3,"currency":"$","offers":[],"opentable_support":0,"is_zomato_book_res":0,"mezzo_provider":"OTHER","is_book_form_web_view":0,"book_form_web_view_url":"","book_again_url":"","thumb":"https:\/\/b.zmtcdn.com\/data\/res_imagery\/16592280_RESTAURANT_b5b0b29ad344a66fe7b231a2310df243.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A","user_rating":{"aggregate_rating":"4.2","rating_text":"Very Good","rating_color":"5BA829","votes":"459"},"photos_url":"https:\/\/www.zomato.com\/brisbane\/maru-korean-bbq-brisbane-cbd\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop","menu_url":"https:\/\/www.zomato.com\/brisbane\/maru-korean-bbq-brisbane-cbd\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop","featured_image":"https:\/\/b.zmtcdn.com\/data\/res_imagery\/16592280_RESTAURANT_b5b0b29ad344a66fe7b231a2310df243.jpg","has_online_delivery":0,"is_delivering_now":0,"include_bogo_offers":true,"deeplink":"zomato:\/\/restaurant\/16592280","is_table_reservation_supported":0,"has_table_booking":0,"events_url":"https:\/\/www.zomato.com\/brisbane\/maru-korean-bbq-brisbane-cbd\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"}},{"restaurant":{"R":{"res_id":16591604},"apikey":"3fd7e9f90961452a3ffc81ebc6b87513","id":"16591604","name":"Sak\u00e9 Restaurant & Bar","url":"https:\/\/www.zomato.com\/brisbane\/sak\u00e9-restaurant-bar-brisbane-cbd?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1","location":{"address":"45 Eagle Street Pier, Brisbane CBD, Brisbane","locality":"Eagle Street Pier","city":"Brisbane","city_id":298,"latitude":"-27.4689676860","longitude":"153.0305147544","zipcode":"4000","country_id":14,"locality_verbose":"Eagle Street Pier, Brisbane"},"switch_to_order_menu":0,"cuisines":"Japanese, Sushi","average_cost_for_two":160,"price_range":4,"currency":"$","offers":[],"opentable_support":0,"is_zomato_book_res":0,"mezzo_provider":"DIMMI","is_book_form_web_view":0,"book_form_web_view_url":"","thumb":"https:\/\/b.zmtcdn.com\/data\/res_imagery\/16561824_CHAIN_91355653f1b0d88822f183a572cb5a56.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A","user_rating":{"aggregate_rating":"4.5","rating_text":"Excellent","rating_color":"3F7E00","votes":"909"},"photos_url":"https:\/\/www.zomato.com\/brisbane\/sak\u00e9-restaurant-bar-brisbane-cbd\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop","menu_url":"https:\/\/www.zomato.com\/brisbane\/sak\u00e9-restaurant-bar-brisbane-cbd\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop","featured_image":"https:\/\/b.zmtcdn.com\/data\/res_imagery\/16561824_CHAIN_91355653f1b0d88822f183a572cb5a56.jpg","medio_provider":"","has_online_delivery":0,"is_delivering_now":0,"include_bogo_offers":true,"deeplink":"zomato:\/\/restaurant\/16591604","is_table_reservation_supported":1,"has_table_booking":1,"book_url":"https:\/\/www.zomato.com\/brisbane\/sak\u00e9-restaurant-bar-brisbane-cbd\/book?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1","events_url":"https:\/\/www.zomato.com\/brisbane\/sak\u00e9-restaurant-bar-brisbane-cbd\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"}}]}

1 个答案:

答案 0 :(得分:1)

这是我在本地计算机上尝试过的方法,并且运行正常

let data =  {
  "location": {
    "entity_type": "subzone",
    "entity_id": 98812,
    "title": "Brisbane CBD",
    "latitude": "-27.4700750000",
    "longitude": "153.0265130000",
    "city_id": 298,
    "city_name": "Brisbane",
    "country_id": 14,
    "country_name": "Australia"
  },
  "popularity": {
    "popularity": "5.00",
    "nightlife_index": "4.49",
    "nearby_res": [
      "16591979",
      "16594096",
      "16613418",
      "16590186",
      "16595540",
      "16590496",
      "16591972",
      "16592280",
      "16591604"
    ],
    "top_cuisines": [
      "Cafe Food",
      "Coffee and Tea",
      "Modern Australian",
      "Japanese",
      "Sandwich"
    ],
    "popularity_res": "100",
    "nightlife_res": "10",
    "subzone": "Brisbane CBD",
    "subzone_id": 98812,
    "city": "Brisbane"
  },
  "link": "https:\/\/www.zomato.com\/brisbane\/brisbane-cbd-restaurants",
  "nearby_restaurants": [
    {
      "restaurant": {
        "R": {
          "res_id": 16591979
        },
        "apikey": "3fd7e9f90961452a3ffc81ebc6b87513",
        "id": "16591979",
        "name": "Wagaya",
        "url": "https:\/\/www.zomato.com\/brisbane\/wagaya-fortitude-valley?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1",
        "location": {
          "address": "Chinatown Mall, Level 1, 315 Brunswick Street, Fortitude Valley, Brisbane",
          "locality": "Chinatown Mall",
          "city": "Brisbane",
          "city_id": 298,
          "latitude": "-27.4585653042",
          "longitude": "153.0339020491",
          "zipcode": "4006",
          "country_id": 14,
          "locality_verbose": "Chinatown Mall, Brisbane"
        },
        "switch_to_order_menu": 0,
        "cuisines": "Japanese, Sushi",
        "average_cost_for_two": 100,
        "price_range": 4,
        "currency": "$",
        "offers": [

        ],
        "opentable_support": 0,
        "is_zomato_book_res": 0,
        "mezzo_provider": "OTHER",
        "is_book_form_web_view": 0,
        "book_form_web_view_url": "",
        "book_again_url": "",
        "thumb": "https:\/\/b.zmtcdn.com\/data\/res_imagery\/16591979_RESTAURANT_f84903806912e0fb5ce5a7afc437c1af_c.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A",
        "user_rating": {
          "aggregate_rating": "4.6",
          "rating_text": "Excellent",
          "rating_color": "3F7E00",
          "votes": "1411"
        },
        "photos_url": "https:\/\/www.zomato.com\/brisbane\/wagaya-fortitude-valley\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop",
        "menu_url": "https:\/\/www.zomato.com\/brisbane\/wagaya-fortitude-valley\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop",
        "featured_image": "https:\/\/b.zmtcdn.com\/data\/res_imagery\/16591979_RESTAURANT_f84903806912e0fb5ce5a7afc437c1af_c.jpg",
        "has_online_delivery": 0,
        "is_delivering_now": 0,
        "include_bogo_offers": true,
        "deeplink": "zomato:\/\/restaurant\/16591979",
        "is_table_reservation_supported": 0,
        "has_table_booking": 0,
        "events_url": "https:\/\/www.zomato.com\/brisbane\/wagaya-fortitude-valley\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"
      }
    },
    {
      "restaurant": {
        "R": {
          "res_id": 16594096
        },
        "apikey": "3fd7e9f90961452a3ffc81ebc6b87513",
        "id": "16594096",
        "name": "Miel Container",
        "url": "https:\/\/www.zomato.com\/brisbane\/miel-container-brisbane-cbd?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1",
        "location": {
          "address": "Corner Of Mary Street and Albert Street, Brisbane CBD, Brisbane",
          "locality": "Brisbane CBD",
          "city": "Brisbane",
          "city_id": 298,
          "latitude": "-27.4720173817",
          "longitude": "153.0271288008",
          "zipcode": "4000",
          "country_id": 14,
          "locality_verbose": "Brisbane CBD, Brisbane"
        },
        "switch_to_order_menu": 0,
        "cuisines": "Burger",
        "average_cost_for_two": 45,
        "price_range": 2,
        "currency": "$",
        "offers": [

        ],
        "opentable_support": 0,
        "is_zomato_book_res": 0,
        "mezzo_provider": "OTHER",
        "is_book_form_web_view": 0,
        "book_form_web_view_url": "",
        "book_again_url": "",
        "thumb": "https:\/\/b.zmtcdn.com\/data\/res_imagery\/16594096_CHAIN_fc3bfbd3250c1cbc120f53436e7dafb7.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A",
        "user_rating": {
          "aggregate_rating": "4.8",
          "rating_text": "Excellent",
          "rating_color": "3F7E00",
          "votes": "756"
        },
        "photos_url": "https:\/\/www.zomato.com\/brisbane\/miel-container-brisbane-cbd\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop",
        "menu_url": "https:\/\/www.zomato.com\/brisbane\/miel-container-brisbane-cbd\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop",
        "featured_image": "https:\/\/b.zmtcdn.com\/data\/res_imagery\/16594096_CHAIN_fc3bfbd3250c1cbc120f53436e7dafb7.jpg",
        "has_online_delivery": 0,
        "is_delivering_now": 0,
        "include_bogo_offers": true,
        "deeplink": "zomato:\/\/restaurant\/16594096",
        "is_table_reservation_supported": 0,
        "has_table_booking": 0,
        "events_url": "https:\/\/www.zomato.com\/brisbane\/miel-container-brisbane-cbd\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"
      }
    },
    {
      "restaurant": {
        "R": {
          "res_id": 16613418
        },
        "apikey": "3fd7e9f90961452a3ffc81ebc6b87513",
        "id": "16613418",
        "name": "Oreily's",
        "url": "https:\/\/www.zomato.com\/ballogie-qld\/oreilys-canungra?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1",
        "location": {
          "address": "lamington national park road, Canungra",
          "locality": "Ballogie",
          "city": "Ballogie",
          "city_id": 2632,
          "latitude": "-27.4688800000",
          "longitude": "153.0228270000",
          "zipcode": "4275",
          "country_id": 14,
          "locality_verbose": "Ballogie, Ballogie"
        },
        "switch_to_order_menu": 0,
        "cuisines": "Diner, Pizza",
        "average_cost_for_two": 20,
        "price_range": 2,
        "currency": "$",
        "offers": [

        ],
        "opentable_support": 0,
        "is_zomato_book_res": 0,
        "mezzo_provider": "OTHER",
        "is_book_form_web_view": 0,
        "book_form_web_view_url": "",
        "book_again_url": "",
        "thumb": "",
        "user_rating": {
          "aggregate_rating": "0",
          "rating_text": "Not rated",
          "rating_color": "CBCBC8",
          "votes": "3"
        },
        "photos_url": "https:\/\/www.zomato.com\/ballogie-qld\/oreilys-canungra\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop",
        "menu_url": "https:\/\/www.zomato.com\/ballogie-qld\/oreilys-canungra\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop",
        "featured_image": "",
        "has_online_delivery": 0,
        "is_delivering_now": 0,
        "include_bogo_offers": true,
        "deeplink": "zomato:\/\/restaurant\/16613418",
        "is_table_reservation_supported": 0,
        "has_table_booking": 0,
        "events_url": "https:\/\/www.zomato.com\/ballogie-qld\/oreilys-canungra\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"
      }
    },
    {
      "restaurant": {
        "R": {
          "res_id": 16590186
        },
        "apikey": "3fd7e9f90961452a3ffc81ebc6b87513",
        "id": "16590186",
        "name": "The Little Larder",
        "url": "https:\/\/www.zomato.com\/brisbane\/the-little-larder-new-farm?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1",
        "location": {
          "address": "76 Moray Street, New Farm, Brisbane",
          "locality": "New Farm",
          "city": "Brisbane",
          "city_id": 298,
          "latitude": "-27.4668775902",
          "longitude": "153.0412295088",
          "zipcode": "4005",
          "country_id": 14,
          "locality_verbose": "New Farm, Brisbane"
        },
        "switch_to_order_menu": 0,
        "cuisines": "Cafe Food",
        "average_cost_for_two": 55,
        "price_range": 2,
        "currency": "$",
        "offers": [

        ],
        "opentable_support": 0,
        "is_zomato_book_res": 0,
        "mezzo_provider": "OTHER",
        "is_book_form_web_view": 0,
        "book_form_web_view_url": "",
        "book_again_url": "",
        "thumb": "https:\/\/b.zmtcdn.com\/data\/pictures\/6\/16590186\/f032aa278c03ed8a4608a1b73680d4c0.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A",
        "user_rating": {
          "aggregate_rating": "4.1",
          "rating_text": "Very Good",
          "rating_color": "5BA829",
          "votes": "803"
        },
        "photos_url": "https:\/\/www.zomato.com\/brisbane\/the-little-larder-new-farm\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop",
        "menu_url": "https:\/\/www.zomato.com\/brisbane\/the-little-larder-new-farm\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop",
        "featured_image": "https:\/\/b.zmtcdn.com\/data\/pictures\/6\/16590186\/f032aa278c03ed8a4608a1b73680d4c0.jpg",
        "has_online_delivery": 0,
        "is_delivering_now": 0,
        "include_bogo_offers": true,
        "deeplink": "zomato:\/\/restaurant\/16590186",
        "is_table_reservation_supported": 0,
        "has_table_booking": 0,
        "events_url": "https:\/\/www.zomato.com\/brisbane\/the-little-larder-new-farm\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"
      }
    },
    {
      "restaurant": {
        "R": {
          "res_id": 16595540
        },
        "apikey": "3fd7e9f90961452a3ffc81ebc6b87513",
        "id": "16595540",
        "name": "Julius Pizzeria",
        "url": "https:\/\/www.zomato.com\/brisbane\/julius-pizzeria-south-brisbane?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1",
        "location": {
          "address": "77 Grey Street, South Brisbane, Brisbane",
          "locality": "South Brisbane",
          "city": "Brisbane",
          "city_id": 298,
          "latitude": "-27.4738750608",
          "longitude": "153.0180431530",
          "zipcode": "4101",
          "country_id": 14,
          "locality_verbose": "South Brisbane, Brisbane"
        },
        "switch_to_order_menu": 0,
        "cuisines": "Pizza, Italian",
        "average_cost_for_two": 80,
        "price_range": 3,
        "currency": "$",
        "offers": [

        ],
        "opentable_support": 0,
        "is_zomato_book_res": 0,
        "mezzo_provider": "OTHER",
        "is_book_form_web_view": 0,
        "book_form_web_view_url": "",
        "book_again_url": "",
        "thumb": "https:\/\/b.zmtcdn.com\/data\/res_imagery\/16595540_RESTAURANT_257641802b0296a6ccb17abfe913776e_c.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A",
        "user_rating": {
          "aggregate_rating": "4.9",
          "rating_text": "Excellent",
          "rating_color": "3F7E00",
          "votes": "342"
        },
        "photos_url": "https:\/\/www.zomato.com\/brisbane\/julius-pizzeria-south-brisbane\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop",
        "menu_url": "https:\/\/www.zomato.com\/brisbane\/julius-pizzeria-south-brisbane\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop",
        "featured_image": "https:\/\/b.zmtcdn.com\/data\/res_imagery\/16595540_RESTAURANT_257641802b0296a6ccb17abfe913776e_c.jpg",
        "has_online_delivery": 0,
        "is_delivering_now": 0,
        "include_bogo_offers": true,
        "deeplink": "zomato:\/\/restaurant\/16595540",
        "is_table_reservation_supported": 0,
        "has_table_booking": 0,
        "events_url": "https:\/\/www.zomato.com\/brisbane\/julius-pizzeria-south-brisbane\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"
      }
    },
    {
      "restaurant": {
        "R": {
          "res_id": 16590496
        },
        "apikey": "3fd7e9f90961452a3ffc81ebc6b87513",
        "id": "16590496",
        "name": "Verve Restaurant Bar Cider House",
        "url": "https:\/\/www.zomato.com\/brisbane\/verve-restaurant-bar-cider-house-brisbane-cbd?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1",
        "location": {
          "address": "109 Edward Street, Brisbane CBD, Brisbane",
          "locality": "Brisbane CBD",
          "city": "Brisbane",
          "city_id": 298,
          "latitude": "-27.4701864440",
          "longitude": "153.0288980529",
          "zipcode": "4001",
          "country_id": 14,
          "locality_verbose": "Brisbane CBD, Brisbane"
        },
        "switch_to_order_menu": 0,
        "cuisines": "Italian, Pizza",
        "average_cost_for_two": 90,
        "price_range": 3,
        "currency": "$",
        "offers": [

        ],
        "opentable_support": 0,
        "is_zomato_book_res": 0,
        "mezzo_provider": "OTHER",
        "is_book_form_web_view": 0,
        "book_form_web_view_url": "",
        "book_again_url": "",
        "thumb": "https:\/\/b.zmtcdn.com\/data\/res_imagery\/16590496_RESTAURANT_d2c6e460dfe43cf9872419e499d09c5a.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A",
        "user_rating": {
          "aggregate_rating": "4.6",
          "rating_text": "Excellent",
          "rating_color": "3F7E00",
          "votes": "965"
        },
        "photos_url": "https:\/\/www.zomato.com\/brisbane\/verve-restaurant-bar-cider-house-brisbane-cbd\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop",
        "menu_url": "https:\/\/www.zomato.com\/brisbane\/verve-restaurant-bar-cider-house-brisbane-cbd\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop",
        "featured_image": "https:\/\/b.zmtcdn.com\/data\/res_imagery\/16590496_RESTAURANT_d2c6e460dfe43cf9872419e499d09c5a.jpg",
        "has_online_delivery": 0,
        "is_delivering_now": 0,
        "include_bogo_offers": true,
        "deeplink": "zomato:\/\/restaurant\/16590496",
        "is_table_reservation_supported": 0,
        "has_table_booking": 0,
        "events_url": "https:\/\/www.zomato.com\/brisbane\/verve-restaurant-bar-cider-house-brisbane-cbd\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"
      }
    },
    {
      "restaurant": {
        "R": {
          "res_id": 16591972
        },
        "apikey": "3fd7e9f90961452a3ffc81ebc6b87513",
        "id": "16591972",
        "name": "Malt Dining",
        "url": "https:\/\/www.zomato.com\/brisbane\/malt-dining-brisbane-cbd?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1",
        "location": {
          "address": "28 Market Street, Brisbane CBD, Brisbane",
          "locality": "Brisbane CBD",
          "city": "Brisbane",
          "city_id": 298,
          "latitude": "-27.4695192076",
          "longitude": "153.0294358358",
          "zipcode": "4000",
          "country_id": 14,
          "locality_verbose": "Brisbane CBD, Brisbane"
        },
        "switch_to_order_menu": 0,
        "cuisines": "Modern Australian",
        "average_cost_for_two": 140,
        "price_range": 4,
        "currency": "$",
        "offers": [

        ],
        "opentable_support": 0,
        "is_zomato_book_res": 0,
        "mezzo_provider": "DIMMI",
        "is_book_form_web_view": 0,
        "book_form_web_view_url": "",
        "thumb": "https:\/\/b.zmtcdn.com\/data\/res_imagery\/16591972_RESTAURANT_bb12785af23666f2718b5d7e12c9a9bf.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A",
        "user_rating": {
          "aggregate_rating": "4.6",
          "rating_text": "Excellent",
          "rating_color": "3F7E00",
          "votes": "777"
        },
        "photos_url": "https:\/\/www.zomato.com\/brisbane\/malt-dining-brisbane-cbd\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop",
        "menu_url": "https:\/\/www.zomato.com\/brisbane\/malt-dining-brisbane-cbd\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop",
        "featured_image": "https:\/\/b.zmtcdn.com\/data\/res_imagery\/16591972_RESTAURANT_bb12785af23666f2718b5d7e12c9a9bf.jpg",
        "medio_provider": "",
        "has_online_delivery": 0,
        "is_delivering_now": 0,
        "include_bogo_offers": true,
        "deeplink": "zomato:\/\/restaurant\/16591972",
        "is_table_reservation_supported": 1,
        "has_table_booking": 1,
        "book_url": "https:\/\/www.zomato.com\/brisbane\/malt-dining-brisbane-cbd\/book?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1",
        "events_url": "https:\/\/www.zomato.com\/brisbane\/malt-dining-brisbane-cbd\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"
      }
    },
    {
      "restaurant": {
        "R": {
          "res_id": 16592280
        },
        "apikey": "3fd7e9f90961452a3ffc81ebc6b87513",
        "id": "16592280",
        "name": "Maru Korean BBQ",
        "url": "https:\/\/www.zomato.com\/brisbane\/maru-korean-bbq-brisbane-cbd?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1",
        "location": {
          "address": "157 Elizabeth Street, Brisbane CBD, Brisbane",
          "locality": "Brisbane CBD",
          "city": "Brisbane",
          "city_id": 298,
          "latitude": "-27.4703619536",
          "longitude": "153.0266862363",
          "zipcode": "4000",
          "country_id": 14,
          "locality_verbose": "Brisbane CBD, Brisbane"
        },
        "switch_to_order_menu": 0,
        "cuisines": "Korean BBQ",
        "average_cost_for_two": 70,
        "price_range": 3,
        "currency": "$",
        "offers": [

        ],
        "opentable_support": 0,
        "is_zomato_book_res": 0,
        "mezzo_provider": "OTHER",
        "is_book_form_web_view": 0,
        "book_form_web_view_url": "",
        "book_again_url": "",
        "thumb": "https:\/\/b.zmtcdn.com\/data\/res_imagery\/16592280_RESTAURANT_b5b0b29ad344a66fe7b231a2310df243.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A",
        "user_rating": {
          "aggregate_rating": "4.2",
          "rating_text": "Very Good",
          "rating_color": "5BA829",
          "votes": "459"
        },
        "photos_url": "https:\/\/www.zomato.com\/brisbane\/maru-korean-bbq-brisbane-cbd\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop",
        "menu_url": "https:\/\/www.zomato.com\/brisbane\/maru-korean-bbq-brisbane-cbd\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop",
        "featured_image": "https:\/\/b.zmtcdn.com\/data\/res_imagery\/16592280_RESTAURANT_b5b0b29ad344a66fe7b231a2310df243.jpg",
        "has_online_delivery": 0,
        "is_delivering_now": 0,
        "include_bogo_offers": true,
        "deeplink": "zomato:\/\/restaurant\/16592280",
        "is_table_reservation_supported": 0,
        "has_table_booking": 0,
        "events_url": "https:\/\/www.zomato.com\/brisbane\/maru-korean-bbq-brisbane-cbd\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"
      }
    },
    {
      "restaurant": {
        "R": {
          "res_id": 16591604
        },
        "apikey": "3fd7e9f90961452a3ffc81ebc6b87513",
        "id": "16591604",
        "name": "Sak\u00e9 Restaurant & Bar",
        "url": "https:\/\/www.zomato.com\/brisbane\/sak\u00e9-restaurant-bar-brisbane-cbd?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1",
        "location": {
          "address": "45 Eagle Street Pier, Brisbane CBD, Brisbane",
          "locality": "Eagle Street Pier",
          "city": "Brisbane",
          "city_id": 298,
          "latitude": "-27.4689676860",
          "longitude": "153.0305147544",
          "zipcode": "4000",
          "country_id": 14,
          "locality_verbose": "Eagle Street Pier, Brisbane"
        },
        "switch_to_order_menu": 0,
        "cuisines": "Japanese, Sushi",
        "average_cost_for_two": 160,
        "price_range": 4,
        "currency": "$",
        "offers": [

        ],
        "opentable_support": 0,
        "is_zomato_book_res": 0,
        "mezzo_provider": "DIMMI",
        "is_book_form_web_view": 0,
        "book_form_web_view_url": "",
        "thumb": "https:\/\/b.zmtcdn.com\/data\/res_imagery\/16561824_CHAIN_91355653f1b0d88822f183a572cb5a56.jpg?fit=around%7C200%3A200&crop=200%3A200%3B%2A%2C%2A",
        "user_rating": {
          "aggregate_rating": "4.5",
          "rating_text": "Excellent",
          "rating_color": "3F7E00",
          "votes": "909"
        },
        "photos_url": "https:\/\/www.zomato.com\/brisbane\/sak\u00e9-restaurant-bar-brisbane-cbd\/photos?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1#tabtop",
        "menu_url": "https:\/\/www.zomato.com\/brisbane\/sak\u00e9-restaurant-bar-brisbane-cbd\/menu?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1&openSwipeBox=menu&showMinimal=1#tabtop",
        "featured_image": "https:\/\/b.zmtcdn.com\/data\/res_imagery\/16561824_CHAIN_91355653f1b0d88822f183a572cb5a56.jpg",
        "medio_provider": "",
        "has_online_delivery": 0,
        "is_delivering_now": 0,
        "include_bogo_offers": true,
        "deeplink": "zomato:\/\/restaurant\/16591604",
        "is_table_reservation_supported": 1,
        "has_table_booking": 1,
        "book_url": "https:\/\/www.zomato.com\/brisbane\/sak\u00e9-restaurant-bar-brisbane-cbd\/book?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1",
        "events_url": "https:\/\/www.zomato.com\/brisbane\/sak\u00e9-restaurant-bar-brisbane-cbd\/events#tabtop?utm_source=api_basic_user&utm_medium=api&utm_campaign=v2.1"
      }
    }
  ]
}


data.nearby_restaurants.map((d, i) => {
  if(d.restaurant){
    console.log("Latitude", d.restaurant.location.latitude);
    console.log("Longitude", d.restaurant.location.longitude);
  }
});