Documentation Index
Fetch the complete documentation index at: https://mintlify.com/akibanks/api-tienda-vinilos/llms.txt
Use this file to discover all available pages before exploring further.
GET /mis-compras returns the full purchase history for the authenticated user, ordered from newest to oldest. Each order includes its line items (the individual vinyl records purchased), a running total, the current order status, and partial shipping info — only city and state are exposed here; the full street address is kept private and is only accessible to admins via GET /admin/ventas/:id.
Endpoint details
| Method | GET |
| Path | /mis-compras |
| Auth | JWT required (Authorization: Bearer <token>) |
Request params
No query parameters or request body. The user is identified entirely from the JWT payload.Response
Returns a JSON array of order objects, newest first. An empty array ([]) is returned if the user has not yet placed any orders.
Unique ID of the purchase order.
Total amount charged for the order (as a JavaScript number, e.g.
29.99).Current order status. One of:
pendiente, pagada, enviada, entregada, cancelada.ISO 8601 datetime when the order was created (e.g.
"2024-11-03T20:15:00.000Z").City from the shipping address.
null if no shipping record is associated with the order.Line items — the individual vinyl records included in this order.
Example
Error responses
| Status | Condition | Error message |
|---|---|---|
401 | JWT is absent or malformed | "Token de autenticación requerido." |
401 | JWT is expired or invalid | "Token inválido o expirado. Vuelve a iniciar sesión." |
500 | Unexpected server or database error | "Error al obtener el historial de compras." |