Menu Order
Menu order schemas for restaurant and food service order management. Supports dine-in, takeout, and delivery order types.
Schema: MenuOrderSchema
Source: src/core/business-mgt/menu.order.schema.ts
MenuOrderItem​
Individual items within a menu order.
Schema: MenuOrderItemSchema
Attributes​
| Attribute | Type | Required | Default | Description |
|---|---|---|---|---|
id | string | — | — | Unique identifier for this order item |
menuOrderId | string | Yes | — | References parent MenuOrder |
menuItemId | string | Yes | — | References MenuItem from catalog |
itemName | string | Yes | — | Display name captured at order time |
quantity | number | Yes | — | Number of units ordered |
unitPrice | number | Yes | — | Price per unit at order time |
totalPrice | number | Yes | — | Total price for this line item |
specialInstructions | string | null | No | null | Customer's special preparation requests |
customizations | array | null | No | null | Item customizations with pricing |
status | enum | No | PENDING | Current preparation status. One of PENDING, CONFIRMED, PREPARING, READY, COMPLETED, or CANCELLED. |
preparationTime | number | null | No | null | Estimated prep time in minutes |
notes | string | null | No | null | Internal notes for staff |
Customization Object​
| Attribute | Type | Default | Description |
|---|---|---|---|
name | string | — | Customization option name |
value | string | — | Selected customization value |
additionalCost | number | 0 | Extra charge for this customization |
MenuOrder​
Complete menu order with items, customer, and pricing.
Attributes​
| Attribute | Type | Required | Default | Description |
|---|---|---|---|---|
id | string | — | — | Unique identifier for the order |
orderNumber | string | null | No | null | Human-readable order number |
type | enum | Yes | — | Order type. One of DINE_IN, TAKEOUT, or DELIVERY. |
status | enum | No | PENDING | Current order status. One of PENDING, CONFIRMED, PREPARING, READY, COMPLETED, or CANCELLED. |
items | array<MenuOrderItem> | Yes | — | Menu items in this order (min 1) |
customerId | string | Yes | — | References Customer |
customer | OrderCustomer | null | No | null | Populated customer information |
pricing | OrderPricing | Yes | — | Complete pricing breakdown |
paymentStatus | enum | No | PENDING | Payment processing status. One of PENDING, PAID, FAILED, or REFUNDED. |
paymentMethod | string | null | No | null | Payment method used |
paymentReference | string | null | No | null | External payment reference |
orderDate | number | Yes | — | Unix timestamp when order was placed |
requestedTime | number | null | No | null | Requested pickup/delivery time |
estimatedReadyTime | number | null | No | null | Kitchen estimate for completion |
actualReadyTime | number | null | No | null | Actual completion time |
specialInstructions | string | null | No | null | Order-level special instructions |
allergies | array<string> | null | No | null | Customer allergy information |
tableNumber | string | null | No | null | Table number for DINE_IN orders |
externalOrderId | string | null | No | null | External system order ID |
source | string | No | direct | Order source channel |
cancelReason | string | null | No | null | Reason for cancellation |
notes | string | null | No | null | Internal operational notes |
serviceConversationConfigId | string | null | No | null | AI service conversation config ID |
deliveryAddress | object | null | No | null | Delivery address for DELIVERY orders |
tip | number | null | No | null | Tip amount for the order |
createdAt | number | — | — | Unix timestamp when created |
updatedAt | number | — | — | Unix timestamp when last updated |
Example​
{
"id": "order_abc123",
"orderNumber": "#1234",
"type": "DINE_IN",
"status": "PREPARING",
"items": [
{
"id": "item_001",
"menuOrderId": "order_abc123",
"menuItemId": "menu_pizza",
"itemName": "Margherita Pizza",
"quantity": 2,
"unitPrice": 16.99,
"totalPrice": 33.98,
"specialInstructions": "Extra crispy",
"customizations": [
{
"name": "Extra Cheese",
"value": "Yes",
"additionalCost": 2.00
}
],
"status": "PREPARING"
}
],
"customerId": "cust_abc123",
"pricing": {
"subtotal": 37.98,
"tax": 3.04,
"tip": 7.00,
"total": 48.02,
"currency": "USD"
},
"paymentStatus": "PAID",
"tableNumber": "5",
"orderDate": 1709856000000,
"createdAt": 1709856000000,
"updatedAt": 1709856000000
}
Create / Update Schemas​
| Schema | Description | Omits |
|---|---|---|
CreateMenuOrderSchema | For creating new orders | id, createdAt, updatedAt, actualReadyTime, cancelReason, serviceConversationConfigId |
UpdateMenuOrderSchema | For partial updates | All fields optional except id |
UpdateMenuOrderStatusSchema | For quick status updates | Only id, status, estimatedReadyTime, actualReadyTime |