Create Request
Requests
Create Request
Create a general request for absence, permission, or remote work
POST
Create Request
Endpoint
Supported Request Types
Absence
Type ID:
3Report justified absencesPermission
Type ID:
2Request special permissionsRemote Work
Type ID:
4Request to work externallyRequest Body
Type of request:
2: Permission3: Absence4: Remote Work
1 for vacation via /api/solicitudes/crearSolicitudVacacionesStart date in ISO format or YYYY-MM-DDExample:
"2026-04-01" or "2026-04-01T08:00:00"End date in ISO format or YYYY-MM-DDMust be equal to or after
fecha_inicioDescription or reason for the requestExample:
"Medical appointment"Optional URL to supporting document (e.g., medical certificate)
Response
Success message indicating the request was created
Code Examples
Response Example
201 Created
Error Responses
Notifications
When a request is created, the system automatically sends notifications to all HR administrators (users with Admin role). The notification includes:- Title: “Nueva Solicitud de Permiso”
- Message: Employee name and request type
- Type:
SOLICITUD_NUEVA - Reference: The created request ID
Business Logic
Day Calculation
The system automatically calculates
dias_solicitados based on the date range, excluding weekends and considering business days.Date Formatting
All dates are stored in MySQL datetime format (YYYY-MM-DD HH:mm:ss) using dayjs library.