Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/devdavco/backend_1/llms.txt

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

The GET /espacios/{id} endpoint retrieves a single coworking space whose id matches the integer you supply in the URL path. Use this endpoint when you need the full details of one specific space — for example, to display a space detail page, pre-fill an edit form, or confirm that a space exists before creating a reservation against it.

Path parameters

id
integer
required
The integer primary key of the coworking space to retrieve. This value is assigned by the database when the space is created and can be discovered by calling GET /espacios/all.

Request

No request body or query parameters are required. No authentication headers are needed.

Example request

curl http://localhost:8080/espacios/1

Response

200 OK

Returns a single JSON Espacio object when the ID exists.
{
  "id": 1,
  "nombre": "Sala de Reuniones A",
  "tipo": "sala_reunion",
  "capacidad": 10,
  "minutos_limpieza": 15
}

Response fields

id
integer
The unique identifier of the retrieved coworking space. Matches the {id} supplied in the request path.
nombre
string
Human-readable name of the space. Up to 50 characters.
tipo
string
Functional category of the space (e.g., sala_reunion, auditorio, oficina_privada). Up to 30 characters.
capacidad
integer
Maximum number of people the space can accommodate simultaneously.
minutos_limpieza
integer
Number of minutes automatically blocked after each booking ends for cleaning before the next booking can begin.

Errors

If no coworking space with the given id exists, the service throws a RuntimeException with the message "Reserva no encontrada con ID: {id}". Spring Boot will propagate this as an unhandled exception and return an HTTP 500 Internal Server Error. There is currently no dedicated 404 response for this endpoint — validate that the ID exists (via GET /espacios/all) before calling this endpoint with user-supplied input.

Build docs developers (and LLMs) love