Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/JulietaEM/EdgeTimer/llms.txt

Use this file to discover all available pages before exploring further.

The /citas endpoint returns all appointments associated with a given profile. Pass role and profileId to scope results to the correct user. Use the optional view and estado parameters to narrow the list — for example, the home screen only shows upcoming confirmed appointments, while the agenda shows the full history.

Base URL

https://edgetimer-backend.onrender.com

Request

GET /citas

Query parameters

role
string
required
The role of the requesting user. Must be "cliente" or "barbero".
profileId
string
required
The profile ID of the requesting user. Used to filter appointments that belong to this profile.
view
string
Optional display context. Accepted values: "home" or "agenda". Affects which appointments are returned based on the screen context.
estado
string
Filter results by appointment status. Accepted values: "pendiente", "confirmada", "realizada", "cancelada", "rechazada".

Response

Returns an array of Cita objects matching the query.

Cita object

id
string
Unique identifier for the appointment.
cliente
object
The client associated with this appointment.
barbero
object
The barber assigned to this appointment.
slotId
string | null
The ID of the availability slot this appointment was booked from. null if the appointment was created via solicitar rather than reservar.
procedimientos
array
List of procedures scheduled for this appointment.
costoTotal
number
Sum of the prices of all procedures in the appointment.
inicioAt
string
ISO 8601 timestamp for the appointment start time.
finAt
string
ISO 8601 timestamp for the appointment end time.
fecha
string
Appointment date in YYYY-MM-DD format.
horaInicio
string
Appointment start time in HH:MM format.
horaFin
string
Appointment end time in HH:MM format.
estado
string
Current status of the appointment. One of: "pendiente", "confirmada", "realizada", "cancelada", "rechazada".
estadoLabel
string
Human-readable label for the current status, suitable for display in the UI.
notas
string
Notes attached to the appointment by the client at the time of booking.
puedeModificar
boolean
Whether the appointment can still be rescheduled or cancelled. true when the appointment is at least one day away.
calificacion
object | null
Rating left by the client after the appointment is completed. null if the appointment has not been rated.

Example

curl --request GET \
  --url 'https://edgetimer-backend.onrender.com/citas?role=cliente&profileId=abc123&view=agenda&estado=confirmada'
Example response
[
  {
    "id": "cita-001",
    "cliente": {
      "id": "abc123",
      "nombre": "Ana López",
      "foto": null
    },
    "barbero": {
      "id": "barber-007",
      "nombre": "Carlos Mendoza",
      "foto": "https://example.com/fotos/carlos.jpg",
      "promedioCalificacion": 4.8
    },
    "slotId": null,
    "procedimientos": [
      {
        "id": "proc-01",
        "nombre": "Corte de cabello",
        "descripcion": "Corte clásico con tijeras",
        "precio": 120,
        "duracionMinutos": 30
      }
    ],
    "costoTotal": 120,
    "inicioAt": "2026-05-20T15:00:00.000Z",
    "finAt": "2026-05-20T15:30:00.000Z",
    "fecha": "2026-05-20",
    "horaInicio": "09:00",
    "horaFin": "09:30",
    "estado": "confirmada",
    "estadoLabel": "Confirmada",
    "notas": "Prefiero tijeras, sin máquina",
    "puedeModificar": true,
    "calificacion": null
  }
]

Build docs developers (and LLMs) love