Skip to main content

Documentation Index

Fetch the complete documentation index at: https://mintlify.com/CKoldo/Vacaciones-front/llms.txt

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

The Personal API manages the employee roster. Each employee record holds identifying information and a hire date that is used to calculate their vacation period.
All endpoints require a valid Authorization: Bearer <token> header. See Authentication for details.

List employees

Returns all employee records stored in the system.

GET /api/personal

No request body. ResponsePersonal[]
id
string
required
Unique identifier for the employee.
nombre
string
required
First name.
apellido
string
required
Last name.
email
string
required
Email address.
puesto
string
required
Job title or position.
fechaIngreso
string
required
Hire date as an ISO 8601 date string (e.g. "2024-03-15"). The vacation period begins one year after this date.
curl http://localhost:5175/api/personal \
  -H "Authorization: Bearer <token>"

Create an employee

Creates a new employee record.

POST /api/personal

id
string
required
Client-generated UUID for the employee.
nombre
string
required
First name.
apellido
string
required
Last name.
email
string
required
Email address.
puesto
string
required
Job title or position.
fechaIngreso
string
required
Hire date in ISO 8601 format (e.g. "2024-03-15").
Response — the created Personal object.
curl -X POST http://localhost:5175/api/personal \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{
    "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "nombre": "María",
    "apellido": "González",
    "email": "maria.gonzalez@empresa.com",
    "puesto": "Desarrolladora",
    "fechaIngreso": "2023-06-01"
  }'

Delete an employee

Deletes an employee by their ID.

DELETE /api/personal/:id

id
string
required
The UUID of the employee to delete.
No request body. Response200 OK on success. The response body may be empty or contain a confirmation message.
Deleting an employee does not automatically delete their associated vacation schedules or ranges. Clean up related records in the Schedules and Ranges endpoints as needed.
curl -X DELETE http://localhost:5175/api/personal/a1b2c3d4-e5f6-7890-abcd-ef1234567890 \
  -H "Authorization: Bearer <token>"

Build docs developers (and LLMs) love