Documentation Index Fetch the complete documentation index at: https://mintlify.com/Falasefemi2/companyflow/llms.txt
Use this file to discover all available pages before exploring further.
Permanently delete a leave type. This operation removes the leave type configuration from the system.
This is a destructive operation. Ensure that no active leave balances or pending requests depend on this leave type before deletion.
Authentication
Requires authentication with Bearer token. Available to:
Path Parameters
The unique identifier of the leave type (UUID format) Example: "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
Response
Indicates if the request was successful
curl -X DELETE https://api.companyflow.com/leave-types/a1b2c3d4-e5f6-7890-abcd-ef1234567890 \
-H "Authorization: Bearer YOUR_TOKEN"
200 - Success
400 - Bad Request
401 - Unauthorized
500 - Internal Server Error
{
"success" : true ,
"message" : "leave type deleted"
}
Important Considerations
Before deleting a leave type, consider the following:
Active balances : Employees may have leave balances associated with this type
Pending requests : There may be pending leave requests using this type
Historical data : Approved leave history will be affected
Reporting : Reports may be incomplete if historical leave types are removed
Alternative: Deactivate Instead
Instead of deleting, consider setting the leave type status to inactive using the Update Leave Type endpoint. This preserves historical data while preventing new leave requests.