Asistencia / festivos y novedades
Referencia de 7 endpoints generados desde mosend-wb-backend/src/modules/attendance/day-off.controller.ts.
Base path:
/organizations/:orgId/attendance·7 endpoints·Source: mosend-wb-backend/src/modules/attendance/day-off.controller.ts/organizations/:orgId/attendance/holidays bearer
Festivos de la organización (opcionalmente de un año).
Path params
orgIdstringrequerido
Query params
yearstringrequerido
Respuestas
- 200
curl -X GET 'https://api.mosend.dev/organizations/a1b2c3d4-1234-5678-9abc-def012345678/attendance/holidays' \ -H 'X-Api-Key: mk_live_<prefix>.<secret>'
Response · 200
{
"data": [
{
"id": "00000000-0000-0000-0000-000000000000",
"createdAt": "2026-05-01T03:42:18.123Z"
}
],
"timestamp": "2026-05-01T03:42:18.123Z"
}/organizations/:orgId/attendance/holidays bearer
Crea o actualiza festivos. Admite varios de una vez (calendario anual).
Path params
orgIdstringrequerido
Body (JSON)
itemsHolidayItemDto[]requerido
Respuestas
- 201
curl -X POST 'https://api.mosend.dev/organizations/a1b2c3d4-1234-5678-9abc-def012345678/attendance/holidays' \
-H 'X-Api-Key: mk_live_<prefix>.<secret>' \
-H 'Content-Type: application/json' \
-d '{"items": []}'Response · 200
{
"data": {
"id": "00000000-0000-0000-0000-000000000000",
"name": "string",
"description": "string"
},
"timestamp": "2026-05-01T03:42:18.123Z"
}/organizations/:orgId/attendance/holidays/seed bearer
Siembra el calendario oficial de festivos de un país para un año (por defecto CO).
Path params
orgIdstringrequerido
Query params
yearstringrequeridocountrystringrequerido
Respuestas
- 201
curl -X POST 'https://api.mosend.dev/organizations/a1b2c3d4-1234-5678-9abc-def012345678/attendance/holidays/seed' \ -H 'X-Api-Key: mk_live_<prefix>.<secret>'
Response · 200
{
"data": {
"id": "00000000-0000-0000-0000-000000000000",
"createdAt": "2026-05-01T03:42:18.123Z"
},
"timestamp": "2026-05-01T03:42:18.123Z"
}/organizations/:orgId/attendance/holidays/:id bearer
Elimina un festivo.
Path params
orgIdstringrequeridoidstringrequerido
Respuestas
- 200
curl -X DELETE 'https://api.mosend.dev/organizations/a1b2c3d4-1234-5678-9abc-def012345678/attendance/holidays/00000000-0000-0000-0000-000000000000' \ -H 'X-Api-Key: mk_live_<prefix>.<secret>'
Response · 200
{
"data": {
"id": "00000000-0000-0000-0000-000000000000",
"createdAt": "2026-05-01T03:42:18.123Z"
},
"timestamp": "2026-05-01T03:42:18.123Z"
}/organizations/:orgId/attendance/leaves bearer
Novedades (vacaciones, incapacidades, permisos) que tocan el rango dado.
Path params
orgIdstringrequerido
Query params
fromstringrequeridotostringrequeridoagentIdstringrequerido
Respuestas
- 200
curl -X GET 'https://api.mosend.dev/organizations/a1b2c3d4-1234-5678-9abc-def012345678/attendance/leaves' \ -H 'X-Api-Key: mk_live_<prefix>.<secret>'
Response · 200
{
"data": [
{
"id": "00000000-0000-0000-0000-000000000000",
"createdAt": "2026-05-01T03:42:18.123Z"
}
],
"timestamp": "2026-05-01T03:42:18.123Z"
}/organizations/:orgId/attendance/leaves bearer
Registra una novedad de un asesor.
Path params
orgIdstringrequerido
Body (JSON)
agentUserIdstring · uuidrequeridotypestringrequeridoVACATIONSICKPERMISSIONUNPAIDOTHERstartDatestringrequeridoendDatestringrequeridoInclusivo: una novedad de un solo día lleva la misma fecha en ambos.
notestring
Respuestas
- 201
curl -X POST 'https://api.mosend.dev/organizations/a1b2c3d4-1234-5678-9abc-def012345678/attendance/leaves' \
-H 'X-Api-Key: mk_live_<prefix>.<secret>' \
-H 'Content-Type: application/json' \
-d '{"agentUserId": "00000000-0000-0000-0000-000000000000","type": "VACATION","startDate": "<startDate>","endDate": "<endDate>","note": "<note>"}'Response · 200
{
"data": {
"id": "00000000-0000-0000-0000-000000000000",
"name": "string",
"description": "string"
},
"timestamp": "2026-05-01T03:42:18.123Z"
}/organizations/:orgId/attendance/leaves/:id bearer
Elimina una novedad.
Path params
orgIdstringrequeridoidstringrequerido
Respuestas
- 200
curl -X DELETE 'https://api.mosend.dev/organizations/a1b2c3d4-1234-5678-9abc-def012345678/attendance/leaves/00000000-0000-0000-0000-000000000000' \ -H 'X-Api-Key: mk_live_<prefix>.<secret>'
Response · 200
{
"data": {
"id": "00000000-0000-0000-0000-000000000000",
"createdAt": "2026-05-01T03:42:18.123Z"
},
"timestamp": "2026-05-01T03:42:18.123Z"
}