Leave Calendar Compatibility API
Summary
Six compatibility operations expose Holiday CRUD and weekly-off read/replace using existing client routes.
Audience
Frontend/backend developers, QA, Leave/Attendance administrators, support, and implementation partners.
Reference Content
Maturity: Compatibility / Transitional. Authentication: monolith requires authenticated calls; gateway/service expectation applies after cutover. Authorization: monolith permits authenticated reads and administrator mutations; extracted parity Requires confirmation. Tenant: required.
| Operation | Method/public route | Body/parameters | Response/status | Behavior |
|---|---|---|---|---|
| List Holidays | GET /api/holidays | None | 200 Holiday rows | Tenant list; no filter/side effect. |
| Create Holiday | POST /api/holidays | Holiday name/date/type | 200 row; 400 invalid; 403 monolith non-admin | Audit in extracted service; no Leave event. |
| Update Holiday | PUT /api/holidays/{id} | Route id + Holiday body | 200 row; 404; 400/403 as owner enforces | Replaces fields. |
| Delete Holiday | DELETE /api/holidays/{id} | Route id | 200 plain success; 404; possible 403 | Removes entry. |
| List weekly offs | GET /api/weekly-offs | None | 200 day rows | Read-only. |
| Replace weekly offs | PUT /api/weekly-offs | JSON day-name array | 200 day rows; possible 400/403 | Replaces tenant collection; exact day validation absent in extracted command. |
Holiday fields and examples are in Holidays; weekly-off fields/examples are in Weekly Offs. No date-range Holiday lookup, optional/regional calendar operation, per-employee weekly-off operation, or individual weekly-off CRUD exists.
Weekly-off routing can resolve to Attendance Service before Leave Service depending on current Time Office ownership. This overlap is Transitional and must be included in gateway parity testing.
Source References
microservices/src/leave-service/Api/LeaveEndpoints.csControllers/HolidaysController.csControllers/WeeklyOffsController.csmicroservices/src/gateway-api/Program.cs
Related Articles
See Also
Keywords
- Leave API
- Compatibility
- Leave Calendar Compatibility API
Revision Information
- Status: Draft
- Last reviewed: 2026-07-15
- Review cycle: Quarterly