Recipe detail
GET
https://api.prezo.es/public/v1/recipes/{recipe}
Modulo richiesto:Recipes
One recipe with its ingredients costed for one restaurant.
Parametri
Parametri del percorso
recipe
integerobbligatorio
Parametri di query
restaurantId
integerfacoltativo
Narrows to one restaurant.
Esempio di richiesta
import os
import requests
response = requests.get(
"https://api.prezo.es/public/v1/recipes/8842",
headers={
"Authorization": f"Bearer {os.environ['PREZO_API_KEY']}",
"Accept": "application/json",
},
)
print(response.json())Risposte
Successful response.
{
"data": {
"id": 8842,
"name": "Hamburguesa de la casa",
"type": "sale",
"portions": 1,
"yieldQuantity": "1.000",
"yieldUnit": "ud",
"targetFoodCostPercent": "30.00",
"posProducts": [
{
"integration": {
"id": 7,
"name": "Revo"
},
"code": "PLU-42",
"restaurantId": 1204
}
],
"restaurants": [
{
"restaurant": {
"id": 1204,
"name": "Local Gràcia"
},
"totalCost": "4.6100",
"foodCost": "3.4200",
"labourCost": "0.9000",
"fixedCost": "0.2500",
"materialCost": "0.0400",
"salePrice": "13.50",
"vatRate": "10.00",
"salePriceWithoutVat": "12.2727",
"foodCostPercent": "27.87",
"marginPercent": "62.44",
"suggestedSalePrice": "12.54"
}
],
"ingredients": [
{
"source": "master_product",
"sourceId": 20311,
"name": "CARNE PICADA DE TERNERA",
"unit": "kg",
"grossQuantity": "0.1800",
"netQuantity": "0.1700",
"wastePercent": "5.56",
"unitCost": "11.9000",
"cost": "2.1420"
},
{
"source": "recipe",
"sourceId": 8810,
"name": "Salsa de la casa",
"unit": "kg",
"grossQuantity": "0.0300",
"netQuantity": "0.0300",
"wastePercent": "0.00",
"unitCost": "6.4000",
"cost": "0.1920"
}
]
}
}