Purpose

Obtaining cocktail recipe cards for the menu

Request typeasynchronous/synchronous
Supported agent version, SH

WSA v 2.8.5.6 SH5 

PluggetSystemTypeStoreHouse


Request format

{
  "taskType": "ShAlcMenuPrepare",
  "params": {
    "async": {
      "objectId": number,
       "timeout": number
    },
    "sync": {
      "objectId": number,
       "timeout": number
    },
    "restaurantGuid": "string (guid)",
    "placeGuid": "string (guid)",
    "date": "string"
   }
}

Parameter

Type

Mandatory

Description

taskTypestring+Task type
async

Asynchronous method call (either synchronous or asynchronous)
sync

Synchronous method call (either synchronous or asynchronous)
timeoutint-Agent response timeout in seconds, default is 120 seconds
objectIdint+Restaurant code in the licensing system
restaurantGuidguid+Guid in SH Enterprise
placeGuidguid+Department: Guid in SH. To get a list of departments, use the WS ShGetStores request (the Departs procedure of the SH server)
dateDate-Date for calculation (if null – current date is used)


Response format


JSON

// Successful response
{
   "taskResponse":{
      "dishes":[
         {
            "guid": "string",
            "guidRk": "string",
            "name": "string",
            "ingredients": [
               {
                   "guid": "string",
                   "guidRk": "string",
                   "rid": number,
                   "name": "string",
                   "amount": number
               }
            ]
         }
      ]
   },
   "responseCommon":{
      "taskGuid":"string",
      "taskType":"ShAlcMenuPrepare",
      "objectId":"number"
   }
}
    
// Answer with error
{
  "responseCommon": {
    "taskGuid": "string",
    "taskType": "ShAlcMenuPrepare",
    "objectId": number
  },
  "error": {
    "wsError": {
      "code": "string",
      "desc": "string"
    },
    "agentError": {
      "code": "string",
      "desc": "string"
    }
  }
}

Parameter

Parameter type

Mandatory

Description

dishesarray
Array: List of dish-items that have the additional parameter "For external systems: EGAIS" set
|- guidguid
Item: GUID SH
|- guidRkguid
Item: GUID RK
|- namestring
Item name
|- ingredientsarray
Array: List of ingredients with the "alcoholic product" mark
   |- guidint

GUID SH of the ingredient – SH item (GUID Sh is different from GUID RK for the same item)

   |- guidRkint

Ingredient GUID RK – SH item

   |- ridint
Ingredient Rid
   |- namestring
Ingredient name
   |- amountdouble
Quantity of ingredient (in units for alcohol, default – Liter)