Get absence balance
What an employee has allotted, taken, waiting and still available for each absence type.
GET https://cotlet.dev/api/v1/bizneo/absence-balance
read
Returns one row per absence type for the current cycle, in days or hours as the type is set up. pending counts requests that wait for a decision, and available is what is left after taken and pending. Without employee it reads your own balance, the one My Calendar shows. Reading someone else's balance needs a Bizneo role that can see that employee.
Parameters
| Name | Type | Description |
|---|---|---|
| employee string | string | Employee name or work email. Default: you. |
| absence_type string | string | Absence type name as list_absence_types returns it. Default: all types. |
Request
curl https://cotlet.dev/api/v1/bizneo/absence-balance \
-H "Authorization: Bearer $COTLET_API_KEY" result = client.call("bizneo", "get_absence_balance") const result = await cotlet.call('bizneo', 'get_absence_balance'); cotlet call bizneo get_absence_balance Example response
{
"employee": "Ana Torres",
"balances": [
{
"absence_type": "Vacation",
"unit": "days",
"allotted": 25,
"taken": 10,
"pending": 0,
"available": 15
},
{
"absence_type": "Personal days",
"unit": "days",
"allotted": 3,
"taken": 1,
"pending": 0,
"available": 2
}
]
}