Menus
List of all routes:
List All Menus
- GET https://nite-apigateway.herokuapp.com/nightClub/menus/ - List all menus from one night club
Requires token in header (Bearer token) from employee or manager.
Active Menu
GET https://nite-apigateway.herokuapp.com/nightClub/menus/active - Retrieve active menu from one night club
FOR CONSUMER: Requires token in header (Bearer token) from consumer. Sends info in query.params (idNightClub):
/menu/active?idNightClub=YYYY
FOR EMPLOYEE/MANAGER Requires token in header (Bearer token) from employee or manager. Info of night club is already in token!
Update Menu
- PUT https://nite-apigateway.herokuapp.com/nightClub/menus/{id} - Update a menu
Requires token from manager.
req.body = {
menu_name: String,
menu_status: Boolean,
menu_description: String,
menu_products: Array[{
product_name: String,
product_category: String,
product_price: Number,
product_id: String
}]
}
Set Active Menu
- PUT https://nite-apigateway.herokuapp.com/nightClub/menus/active - Set menu to active
Requires token from manager.
req.body = {
id : String
}
Create new Menu
- POST https://nite-apigateway.herokuapp.com/nightClub/menus/ - Create new menu
Requires token from manager.
req.body = {
menu_name: String,
menu_status: Boolean,
menu_description: String,
menu_products: Array[{
product_name: String,
product_category: String,
product_price: Number,
product_id: String
}]
}
Delete-Menu
- DELETE https://nite-apigateway.herokuapp.com/nightClub/menus/{id} - Deletes menu
Requires token from manager
List of all routes:
List All Menus
- GET https://nite-apigateway.herokuapp.com/nightClub/menus/ - List all menus from one night club
Requires token in header (Bearer token) from employee or manager.
Active Menu
GET https://nite-apigateway.herokuapp.com/nightClub/menus/active - Retrieve active menu from one night club
FOR CONSUMER: Requires token in header (Bearer token) from consumer. Sends info in query.params (idNightClub):
/menu/active?idNightClub=YYYY
FOR EMPLOYEE/MANAGER Requires token in header (Bearer token) from employee or manager. Info of night club is already in token!
Update Menu
- PUT https://nite-apigateway.herokuapp.com/nightClub/menus/{id} - Update a menu
Requires token from manager.
req.body = {
menu_name: String,
menu_status: Boolean,
menu_description: String,
menu_products: Array[{
product_name: String,
product_category: String,
product_price: Number,
product_id: String
}]
}
Set Active Menu
- PUT https://nite-apigateway.herokuapp.com/nightClub/menus/active - Set menu to active
Requires token from manager.
req.body = {
id : String
}
Create new Menu
- POST https://nite-apigateway.herokuapp.com/nightClub/menus/ - Create new menu
Requires token from manager.
req.body = {
menu_name: String,
menu_status: Boolean,
menu_description: String,
menu_products: Array[{
product_name: String,
product_category: String,
product_price: Number,
product_id: String
}]
}
Delete-Menu
- DELETE https://nite-apigateway.herokuapp.com/nightClub/menus/{id} - Deletes menu
Requires token from manager