EaserixDocs
DevelopersAPI referenceCronCrunchTime off

Request time off

Team workspaces only. Opens a pending request for the caller. startDate and endDate are inclusive YYYY-MM-DD, at most a year apart, and between 2000 and 2100. Working days are Monday to Friday excluding holidays. A range with none is 400. Pending days count against the policy, and the range cannot overlap one of the caller's pending or approved requests.

View as Markdown
POST
/v1/time-off/requests
AuthorizationBearer <token>

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X POST "https://example.com/v1/time-off/requests" \  -H "Content-Type: application/json" \  -d '{    "policyId": "string",    "startDate": "2019-08-24",    "endDate": "2019-08-24"  }'
{  "request": {    "id": "string",    "ownerId": "string",    "policyId": "string",    "policyName": "string",    "startDate": "2019-08-24",    "endDate": "2019-08-24",    "dayCount": 0,    "status": "pending",    "note": "string",    "reviewNote": "string",    "reviewedBy": "string",    "reviewedAt": "2019-08-24T14:15:22Z",    "createdAt": "2019-08-24T14:15:22Z"  }}