Skip to main content

Leave Balance Compatibility API

Summary

Three compatibility operations expose an HR workspace subset plus balance save and delete.

Audience

Frontend/backend developers, QA, Leave/HR administrators, support, and implementation partners.

Reference Content

Maturity: Compatibility / Transitional. Authentication: monolith requires authentication; gateway/service expectation applies after cutover. Authorization: monolith scopes workspace and requires management capability for mutations; extracted parity Requires confirmation. Tenant: required.

OperationMethod/public routeRequestResponse/statusBehavior
Get HR workspaceGET /api/hr-operations/workspaceNone200 objectExtracted Leave response contains visible employee summaries and Leave balances; monolith response also contains unrelated HR modules, so client shape is Transitional.
Save Leave balancePOST /api/hr-operations/leave-balancesSaveLeaveBalanceRequest-compatible body200 balance; 400 invalid; 403 monolith unauthorizedUpsert/normalize/audit/timeline; extracted balance event.
Delete Leave balanceDELETE /api/hr-operations/leave-balances/{id}Route id200 plain success; 404 missing; possible 403Removes visible balance; extracted audit.

Workspace employee summary fields exposed by Leave Service are id, name, email, and isActive; leaveBalances contains the complete balance DTO. Consumers must minimize personal data and must not rely on unrelated monolith workspace modules during service cutover.

The save example and balance fields are documented in Leave Balances. Example reads should use synthetic authorized contexts; a safe empty workspace is {"employees":[],"leaveBalances":[]}. No carry-forward, encashment, or accrual compatibility operation exists.

Source References

  • microservices/src/leave-service/Api/LeaveEndpoints.cs
  • Controllers/HrOperationsController.cs
  • microservices/src/leave-service/Application/LeaveWorkflows.cs

See Also

Keywords

  • Leave API
  • Compatibility
  • Leave Balance Compatibility API

Revision Information

  • Status: Draft
  • Last reviewed: 2026-07-15
  • Review cycle: Quarterly