Creates a new unavailability for the employee.

Request

POST https://apimy.yourpayroll.io/api/v2/business/{businessId}/unavailability

Path parameters

Parameter name Value Description Additional
businessId string Required

Request body

The request body takes a complete UnavailabilitySaveModel resource, containing the following writable properties:

{
    "employeeId": "int32",
    "endDate": "date-time",
    "fromDate": "date-time",
    "id": "int32",
    "reason": "string",
    "recurring": "boolean",
    "recurringDay": "string",
    "toDate": "date-time"
}

Properties

Name Type Description
employeeId int32 Int32
endDate date-time Nullable
fromDate date-time DateTime
id int32 Int32
reason string String
recurring boolean Boolean
recurringDay string Nullable

Possible values are:

  • Sunday
  • Monday
  • Tuesday
  • Wednesday
  • Thursday
  • Friday
  • Saturday
toDate date-time Nullable

Response

The following HTTP status codes may be returned, optionally with a response resource.

Status code Description Resource
200 OK

OK

UnavailabilityModel