The Orders API is the core transaction layer of Restaurant Equis. Every order lifecycle — from the moment a customer places a request to the moment it is delivered — flows through these endpoints. Each order automatically creates an associatedDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/teofilobetancourt/Restaurant-Equis/llms.txt
Use this file to discover all available pages before exploring further.
factura (invoice) with a 16% IVA tax computation. All endpoints are available under both /api/ordenes and /api/pedidos; the two prefixes are fully equivalent aliases registered in the FastAPI router.
All endpoints described below are mirrored verbatim at
/api/pedidos/*. For example, POST /api/ordenes and POST /api/pedidos behave identically. Use whichever prefix fits your client naming conventions.List All Orders
num_ticket descending (most recent first). Pass ?estatus=activo to restrict results to orders in recibido or preparando states — useful for the kitchen dashboard view.
Query Parameters
When set to
activo, filters results to orders whose estado_orden is either recibido or preparando. Any other value (or omitting the parameter) returns all orders regardless of status.Response
Returns an array of order objects. Each object contains the following fields:Alias for
num_ticket. Included for frontend compatibility.The auto-incremented primary key and unique identifier for this order.
UTC timestamp of when the order was created, e.g.
"2024-03-15T14:32:00".Full name of the customer. Defaults to
"Cliente General" if the customer record is unavailable.National ID of the customer, e.g.
"V-12345678".Customer’s phone number.
Alias for
tipo_pedido. One of mesa, pickup, or delivery.Order fulfillment type. One of
mesa, pickup, or delivery.Alias for
id_mesa. Table number for dine-in orders; null otherwise.Table number for
mesa-type orders; null for pickup/delivery.Alias for
direccion_envio. Delivery address; null for non-delivery orders.Delivery address used when
tipo_pedido is delivery; null otherwise.Line items belonging to this order.
Sum of all line-item subtotals before tax.
Value-added tax computed as
subtotal × 0.16 (16%), rounded to 2 decimal places.Final amount due:
subtotal + iva, rounded to 2 decimal places.Capitalized display label for the order status, e.g.
"Recibido", "Preparando", "Listo", "Entregado".Lowercase machine-readable status. One of
recibido, preparando, listo, entregado.Get Single Order
404 if no order with that num_ticket exists.
Path Parameters
The unique ticket number of the order to retrieve.
Create Order
cedula_cliente is not yet in the database, creates the detalle_pedido (line items), and generates a linked factura with computed subtotal, impuesto (16% IVA), and total. Returns 201 Created with the full order response body.
Request Body
National ID of the customer, e.g.
"V-12345678". If no customer record exists for this ID, one is created automatically using the cliente_nombre, cliente_telefono, and direccion_envio values supplied.Full name of the customer. Used when auto-creating a new customer record. Alias:
nombre_cliente.Phone number of the customer. Used when auto-creating a new customer record. Alias:
telefono.Fulfillment type for the order. Accepted values:
mesa, pickup, delivery. Defaults to mesa if an unrecognised value is supplied. Alias: tipo.Table number. Required when
tipo_pedido is mesa; omit or set to null for pickup/delivery. Alias: mesa.Delivery address. Stored on the order only when
tipo_pedido is delivery; otherwise ignored. Alias: direccion.List of dishes to include in the order. Must contain at least one item. Alias:
detalles.Response
Returns201 Created with the full order object (same shape as the list response), including computed subtotal, iva, total, and an initial estado_orden of recibido.
Update Order Status
estado_orden, Estatus_Orden, or estatus — all are normalised to lowercase before matching. Returns a lightweight confirmation object.
Path Parameters
The ticket number of the order to update.
Request Body
New status for the order. Accepted values:
recibido, preparando, listo, entregado (case-insensitive). Aliases: Estatus_Orden, estatus.Response
Always
"ok" on success.The ticket number of the updated order, echoed back.
Cancel / Delete Order
factura → detalle_pedido → pedido. This operation is irreversible.
Path Parameters
The ticket number of the order to cancel and delete.
Response
Always
"deleted" on success.The ticket number of the deleted order, echoed back.