General - Save/delete a list of temporary registrations
API Url
Use it to save/edit a list of temporary registrations
PUT
http://localhost:16010/ProMarkREST/web/General/employees/{empId}/temporary-registrations?date=2021-08-01
Request headers
| Field | Type | Description |
|---|---|---|
Accept-Languageoptional | String | =en-GB Language use for localization. |
X-Clientoptional | String | =Client type. "Portal""Mobile""Admin" |
X-Roleoptional | Number | ProMark role (1: Employee, 2: User). {12} |
X-WebPart-Idoptional | Number | Unique web-part identifier. |
Path parameters
| Field | Type | Description |
|---|---|---|
| emp_id | String | Employee id. |
Query parameters
| Field | Type | Description |
|---|---|---|
dateoptional | Date | Selected day for the break intervals |
Parameter
| Field | Type | Description |
|---|---|---|
| request | Object | Main object containing the request data. |
| data | Object | Object containg data to be uploaded. |
| cancelBreak | Object | Employees cancel break |
| breakProfId | String | Break profile id |
| breaks | Object[] | Collection of temporary cancel breaks |
| end | Number | Break interval end |
| isCanceled | Logical | True -> create temporary cancel break if it doesn't exists False -> delete temporary cancel break if exists |
| start | Number | Break interval start |
| temporaryRegistrations | Object | Employees temporary registrations |
Request example:
{"request": {"data": {"temporaryRegistrations":[{"type":"CB","empId" :"400","cancelBreak":{"breakProfId":"vpeid","isCanceled": yes,break:{"start": 14400,"end": 16200}}},{}]}}}
Error 4xx
| Field | Type | Description |
|---|---|---|
| response | Object | Main object containing the response data. |
| data | Object | Object containing the requested data (empty). |
| errorCode | Number | Error code. |
| errorMessage | String | Error description. |