GET /api/transacciones/:id
Returns a single transaction by its numeric ID. The response includes the calculated monto_pendiente field.
Authentication: Required
Required role: Any authenticated user
Request
Headers
| Header | Value | Required |
|---|---|---|
| Authorization | Bearer <token> | Yes |
Path parameters
| Parameter | Type | Description |
|---|---|---|
| id | number | The transaction ID |
Response
Success (200)
Transaction ID.
Sequential registration number.
Transaction description.
Transaction type.
Service location.
Customer name.
Status:
pendiente, abierto, or cerrado.Kitchen status:
pendiente or terminado.Total amount as a decimal string.
Amount already paid as a decimal string.
Calculated outstanding amount (
monto_total - monto_pagado).Associated register ID.
ID of the user who created the transaction.
Creation date (
YYYY-MM-DD).Creation timestamp with timezone.
Full creation timestamp.
Last update timestamp.
Error responses
| Status | Description |
|---|---|
| 401 | Unauthorized |
| 404 | Transaction not found |