POST Api/Employees/UpdateWorkPreferences

Request Information

URI Parameters

None.

Body Parameters

Collection of EmployeeWorkPreferenceVM
NameDescriptionTypeAdditional information
EmployeeWorkPreferenceId

integer

None.

EmployeeId

integer

None.

Day

string

None.

CannotWork

boolean

None.

AnyTime

boolean

None.

Preferred

boolean

None.

Available

boolean

None.

TimeFrom

date

None.

TimeTo

date

None.

Request Formats

application/json, text/json

Sample:
[
  {
    "employeeWorkPreferenceId": 1,
    "employeeId": 2,
    "day": "sample string 3",
    "cannotWork": true,
    "anyTime": true,
    "preferred": true,
    "available": true,
    "timeFrom": "2026-05-06T03:14:23.8830722+02:00",
    "timeTo": "2026-05-06T03:14:23.8830722+02:00"
  },
  {
    "employeeWorkPreferenceId": 1,
    "employeeId": 2,
    "day": "sample string 3",
    "cannotWork": true,
    "anyTime": true,
    "preferred": true,
    "available": true,
    "timeFrom": "2026-05-06T03:14:23.8830722+02:00",
    "timeTo": "2026-05-06T03:14:23.8830722+02:00"
  }
]

text/html

Sample:
[{"employeeWorkPreferenceId":1,"employeeId":2,"day":"sample string 3","cannotWork":true,"anyTime":true,"preferred":true,"available":true,"timeFrom":"2026-05-06T03:14:23.8830722+02:00","timeTo":"2026-05-06T03:14:23.8830722+02:00"},{"employeeWorkPreferenceId":1,"employeeId":2,"day":"sample string 3","cannotWork":true,"anyTime":true,"preferred":true,"available":true,"timeFrom":"2026-05-06T03:14:23.8830722+02:00","timeTo":"2026-05-06T03:14:23.8830722+02:00"}]

application/xml, text/xml

Sample:
<ArrayOfEmployeeWorkPreferenceVM xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/UrgentCareExtra.ViewModels.ViewModels.HR">
  <EmployeeWorkPreferenceVM>
    <AnyTime>true</AnyTime>
    <Available>true</Available>
    <CannotWork>true</CannotWork>
    <Day>sample string 3</Day>
    <EmployeeId>2</EmployeeId>
    <EmployeeWorkPreferenceId>1</EmployeeWorkPreferenceId>
    <Preferred>true</Preferred>
    <TimeFrom>2026-05-06T03:14:23.8830722+02:00</TimeFrom>
    <TimeTo>2026-05-06T03:14:23.8830722+02:00</TimeTo>
  </EmployeeWorkPreferenceVM>
  <EmployeeWorkPreferenceVM>
    <AnyTime>true</AnyTime>
    <Available>true</Available>
    <CannotWork>true</CannotWork>
    <Day>sample string 3</Day>
    <EmployeeId>2</EmployeeId>
    <EmployeeWorkPreferenceId>1</EmployeeWorkPreferenceId>
    <Preferred>true</Preferred>
    <TimeFrom>2026-05-06T03:14:23.8830722+02:00</TimeFrom>
    <TimeTo>2026-05-06T03:14:23.8830722+02:00</TimeTo>
  </EmployeeWorkPreferenceVM>
</ArrayOfEmployeeWorkPreferenceVM>

application/x-www-form-urlencoded

Sample:

Failed to generate the sample for media type 'application/x-www-form-urlencoded'. Cannot use formatter 'JQueryMvcFormUrlEncodedFormatter' to write type 'ICollection`1'.

Response Information

Resource Description

IHttpActionResult

None.

Response Formats

application/json, text/json, text/html, application/xml, text/xml

Sample:

Sample not available.