Menu Synchronization (Push Menu)
This section explains how the POS system can push menu updates to UEAT using the Open API. This is used when the POS wants to send partial or full menu changes proactively for prices or item names. Any other Menu changes must be done using the Menu Synch from the UEAT backoffice.
Flow Overview
The process involves:
- POS sends a PUT request with the updated menu payload.
- UEAT validates and assembles the menu response internally.
- UEAT acknowledges the update to the POS, including any errors if applicable.
Sequence Diagram
sequenceDiagram
participant Broker as UEAT
participant POS as POS
POS->>Broker: Send menu update (PUT)
Broker->>Broker: Assemble menu response
Broker-->>POS: Acknowledge with errors (if applicable)
Authentication
All requests must include a Bearer token provided by UEAT during onboarding.
See [[authentication]] for details.
Endpoint
PUT {UEAT Endpoint}
Authorization: Bearer {JWT_TOKEN}
Content-Type: application/json
Notes:
{UEAT Endpoint}will be provided during integration.- The
Bearer tokenis environment-specific (Non-Prod vs Prod). - Include the header
x-ueat-locationidfor location identification.
Request Payload
The payload should include the updated menu structure.
For this scope, updates are limited to price and name changes.
{
"Items": [
{
"Id": "burger_001",
"Name": "Classic Burger",
"Type": "Item",
"Prices": [
{
"Service": "Pickup",
"Price": 999
}
]
}
],
}
Response
UEAT returns an acknowledgment with status and optional errors:
Success
200 OK
Failure
Example for invalid location ID:
{
"errors": [
{
"code": "VALIDATION_ERROR",
"message": "locationID is unknown."
}
]
}
Postman Example
curl -X PUT "{UEAT Endpoint}" \
-H "Authorization: Bearer YOUR_JWT_TOKEN" \
-H "x-ueat-locationid: ueat_location_456" \
-H "Content-Type: application/json" \
-d '{
"items": [
{
"id": "coffee_001",
"name": "Black Coffee",
"type": "Item",
"prices": [
{
"service": "Pickup",
"price": 250
}
]
}
]
}
Best Practices
- Use partial updates for efficiency when only a subset of items changes.
- Validate references (e.g., item IDs) before sending.
- Log both request and response for troubleshooting.
- Ensure payload size remains minimal for faster processing.