Get the caller's time off balance(s)
curl --request GET \ --url https://example.com/api/v1/time-off/balance \ --header 'Authorization: Bearer <token>'With policyId, returns the caller’s balance for that policy. Without it, returns one balance per policy assigned to the caller. Balances are created on demand for the current year.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”Return the balance for this policy only. Without it, one balance per assigned policy is returned.
Return the balance for this policy only. Without it, one balance per assigned policy is returned.
Responses
Section titled “Responses”A single balance when policyId is provided; otherwise an array with one balance per assigned policy.
object
A member’s time-off balance for one policy and year, created on demand.
object
A member’s time-off balance for one policy and year, created on demand.
object
Example generated
{ "data": { "carriedOver": 1, "id": "example", "memberId": "example", "policyId": "example", "totalDays": 1, "usedDays": 1, "year": 1 }}Unauthorized.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Forbidden.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Not found.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Rate limit exceeded. Wait for Retry-After before retrying.
Standard error envelope.
object
object
Stable machine-readable error code.
Human-readable error message.
HTTP status code, mirrored in the body.
Example
{ "error": { "code": "UNAUTHORIZED" }}Headers
Section titled “Headers”Maximum requests in the current quota window.
Quota policy in requests and window seconds, for example 60;w=60.
Requests left in this quota window (zero when blocked).
Seconds until the current quota window resets, when available from the rate-limit store.
Seconds until another request may be attempted.
Chelsea is operated by Arepa Labs LLC