Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

OpenRice Menu WebView

Base URL

Production: https://booking.hungryhub.com/ Staging: https://hh-openrice.netlify.app

Doc:

767852073-hungry-hub-web-view-for-selecting-restaurant-menus-spec-v1-1.docx

791970807-hungry-hub-web-view-for-selecting-restaurant-menus-spec-v1-2.docx

Select Menu (Phase 1)

Example URL for the WebView:

https://hh-openrice.netlify.app/openrice/select-menu?partner=openrice&restaurantid=34&adults=5&child=2&date=2023-05-13&time=18:30&ccy=HK$&ccyrate=0.228895&lang=en&callback=openrice%3A%2F%2Fbookingselectmenu%3Fpn%3Dhh

Display of the WebView: After selecting the desired menu and clicking Next, you will be redirected to a destination URL. An example of this URL is:

openrice://bookingselectmenu?pn=hh&data=%7B%22date%22%3A%222023-05-13%22%2C%22time%22%3A%2218%3A30%22%2C%22adult%22%3A5%2C%22child%22%3A0%2C%22ccy%22%3A%22HK%24%22%2C%22paynow%22%3A0%2C%22totalprice%22%3A3697%2C%22totalpricehk%22%3A846%2C%22menus%22%3A%5B%7B%22id%22%3A%2212666%22%2C%22name%22%3A%22Rang%20Mahal%20x%20Mexicano%20(Friday-Sunday)%22%2C%22qty%22%3A2%2C%22price%22%3A599%2C%22pricehk%22%3A137%2C%22links%22%3A%5B%22https%3A%2F%2Fimages.hhstaging.dev%2Fuploads%2Fhh_package%2Fpackage_menu%2Fimage%2F68160%2FAW_Hungry_hub-_Temporarily_open_11th_floor-01-01.jpg%22%2C%22https%3A%2F%2Fimages.hhstaging.dev%2Fuploads%2Fhh_package%2Fpackage_menu%2Fimage%2F67867%2F0001.jpg%22%2C%22https%3A%2F%2Fimages.hhstaging.dev%2Fuploads%2Fhh_package%2Fpackage_menu%2Fimage%2F67868%2F0002.jpg%22%2C%22https%3A%2F%2Fimages.hhstaging.dev%2Fuploads%2Fhh_package%2Fpackage_menu%2Fimage%2F67869%2F0003.jpg%22%2C%22https%3A%2F%2Fimages.hhstaging.dev%2Fuploads%2Fhh_package%2Fpackage_menu%2Fimage%2F67870%2F0004.jpg%22%5D%7D%2C%7B%22id%22%3A%2212724%22%2C%22name%22%3A%223000%20F%26B%20Credit%20%2B%20Free%20Room%20Night%22%2C%22qty%22%3A1%2C%22price%22%3A2499%2C%22pricehk%22%3A572%2C%22links%22%3A%5B%22https%3A%2F%2Fimages.hhstaging.dev%2Fuploads%2Fhh_package%2Fpackage_menu%2Fimage%2F73865%2Frembrandt_staycation.png%22%5D%7D%5D%7D

Decoded data:

{
  "date": "2023-05-13",
  "time": "18:30",
  "adult": 5,
  "child": 0,
  "ccy": "HK$",
  "paynow": 0,
  "totalprice": 3697,
  "totalpricehk": 846,
  "menus": [
    {
      "id": "12666",
      "name": "Rang Mahal x Mexicano (Friday-Sunday)",
      "qty": 2,
      "price": 599,
      "pricehk": 137,
      "links": [
        "<https://images.hhstaging.dev/uploads/hh_package/package_menu/image/68160/AW_Hungry_hub-_Temporarily_open_11th_floor-01-01.jpg>",
        "<https://images.hhstaging.dev/uploads/hh_package/package_menu/image/67867/0001.jpg>",
        "<https://images.hhstaging.dev/uploads/hh_package/package_menu/image/67868/0002.jpg>",
        "<https://images.hhstaging.dev/uploads/hh_package/package_menu/image/67869/0003.jpg>",
        "<https://images.hhstaging.dev/uploads/hh_package/package_menu/image/67870/0004.jpg>"
      ]
    },
    {
      "id": "12724",
      "name": "3000 F&B Credit + Free Room Night",
      "qty": 1,
      "price": 2499,
      "pricehk": 572,
      "links": [
        "<https://images.hhstaging.dev/uploads/hh_package/package_menu/image/73865/rembrandt_staycation.png>"
      ]
    }
  ]
}

Note:

A change for the link parameter: Since some menus might have more than one link, we will use links as an array instead of a string. Example links value:

[
		"<https://images.hungryhub.com/uploads/hh_package/package_menu/image/105444/Menu_April_Onwards_-_Sheet1_page-0001.jpg>",
		"<https://hungryhub.com/en/restaurant_packages/24669/menu.html?updated_at=hh_package%2Frestaurant_packages%2F24669-20230411091247000000>",
		"<https://hh-menu.hungryhub.com/layout?token=q6knmQ219HQ4Pr4kU2uqzY9wTN5-_Q4mHtSu5h4z1zY&price=true&restaurant_package_id=495&layout_id=1&recommended=>"
]

We have three types of menus, each with its own format:

  1. Normal image: Example link here.
  2. iMenuPro: Example link here.
  3. HHMenu: Example link here.

View Menu (Phase 2)

Example URL for the WebView:

<https://hh-openrice.netlify.app/openrice/view-menu?partner=openrice&restaurantid=34&lang=en&callback=openrice%3A%2F%2Fbookingflow%3Fpn%3Dhh>

Display of the WebView: After clicking Book Now button, you will be redirected to a destination URL (callback). An example of this URL is:

openrice://bookingflow?pn=hh

Others

Restaurant that possibly generate Callback URL that exceed 2000 chars:

<https://hh-openrice.netlify.app/openrice/select-menu?partner=openrice&restaurantid=997&adults=5&child=2&date=2023-05-13&time=18:30&ccy=HK$&ccyrate=0.228895&lang=en&callback=openrice%3A%2F%2Fbookingselectmenu%3Fpn%3Dhh>
<http://localhost:8080/openrice/select-menu?partner=openrice&restaurantid=997&adults=5&child=2&date=2023-05-13&time=18:30&ccy=HK$&ccyrate=0.228895&lang=en&callback=openrice%3A%2F%2Fbookingselectmenu%3Fpn%3Dhh>