EmpUpdate RESTified API
Pass Through Call to Scheduling's "EmpUpdateRequest" API
This RESTified API will perform a pass-through call to the Scheduling sub-system's "EmpUpdateRequest" API (when configured).
URL
PUT /up/v5/rest/scheduling/EmpUpdate
HTTP Request Body
This request requires a JSON object supplied in the HTTP request body, which defines the parameters that will be passed through to the Scheduling "EmpUpdateRequest" API.
EmpUpdate Object Format
EmpUpdate Object Properties
Property | Type | Length | Description | Req? | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
empID |
SS : EmpID (string) | SS: 50 | Identifier of the employee that the newly created standard activity will be allocated to. SS Field: empID | Yes | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
empAttr | object | N/A | f any of the operative’s attributes are not to be updated, then the relevant field in the supplied EmpAttr should be excluded. Each of the items will normally be updated only if they already exist for this employee. For this purpose, each item is identified by its primary key, i.e: StartDate for Postings, SkillID & StartDate for Skills, StartDate for Shifts (Note: The primary key also includes the EmpID, but this is always supplied in another parameter) If an item in one of the Postings, Skills or Shift Assignments supplied does not already exist (as identified by its primary key), the call will fail. However, if the supplied Options field contains UpdateAllowAdd, then any supplied items that don’t already exist will be created and added to the relevant list. If UpdateAllowAdd isn’t set and one of the supplied items doesn’t exist, then SP_POSTING_DOES_NOT_EXIST (235), SP_SKILLASS_DOES_NOT_EXIST (237) or SP_SHIFTASS_DOES_NOT_EXIST (236) will be returned, as appropriate.
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
postings | object | N/A | A posting is an association between an operative and a team (TeamID) which represents the fact that the operative is assigned to that team for a period of time between startDate and endDate. By implication, the operative is also assigned to the FRU containing the IRU containing that team for that time period, and so may be allocated jobs that have been booked into that FRU. Postings can’t overlap in time, but there can be gaps between an operative’s postings when he can’t be assigned any jobs or standard activities.
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
skills | array | An operative may have any number of skills, each for a particular time period.
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
shifts | object | N/A |
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
defaultRangeLKs | object |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
defaultRegionLKs | object |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
pubHols | string | SS: 30 | SS Field: shifts.pubHols |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
workPatt | object | This allowsLocalKnowledgeRanges, Local Knowledge Regions, Local Knowledge Centres, Start Locations and End Locations to be supplied as part of a multi-week repeating work pattern.
|
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
options | object | N/A |
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
externalData | object | N/A |
|
HTTP Response
Success
On success, a JSON-formatted version of the Scheduling "EmpUpdateRequest" API response will be returned.
{ "Success": true, "Code": 0, "Message": "OK", "Payload": { "result": { "type": "OK", "code": "0" } } }
Error
On error, a JSON-formatted version of the Scheduling "EmpUpdateRequest" API response will be returned.
{ "Success": false, "Code": 9, "Payload": { "returnCode": { "type": "Error", "code": "SCH Error Code" } } }
Return Codes
In addition to the Standard Return Codes, and the Scheduling API return codes, the possible Return Codes from this API are:
Pass Through Call to Scheduling's "EmpUpdateRequest" API
This RESTified API will perform a pass-through call to the Scheduling sub-system's "EmpUpdateRequest" API (when configured).
URL
PUT /up/v5/rest/scheduling/EmpUpdate
HTTP Request Body
This request requires a JSON object supplied in the HTTP request body, which defines the parameters that will be passed through to the Scheduling "EmpUpdateRequest" API.
EmpUpdate Object Format
EmpUpdate Object Properties
Property | Type | Length | Description | Req? | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
empID |
SS : EmpID (string) | SS: 50 | Identifier of the employee that the newly created standard activity will be allocated to. SS Field: empID | Yes | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
empAttr | object | N/A | f any of the operative’s attributes are not to be updated, then the relevant field in the supplied EmpAttr should be excluded. Each of the items will normally be updated only if they already exist for this employee. For this purpose, each item is identified by its primary key, i.e: StartDate for Postings, SkillID & StartDate for Skills, StartDate for Shifts (Note: The primary key also includes the EmpID, but this is always supplied in another parameter) If an item in one of the Postings, Skills or Shift Assignments supplied does not already exist (as identified by its primary key), the call will fail. However, if the supplied Options field contains UpdateAllowAdd, then any supplied items that don’t already exist will be created and added to the relevant list. If UpdateAllowAdd isn’t set and one of the supplied items doesn’t exist, then SP_POSTING_DOES_NOT_EXIST (235), SP_SKILLASS_DOES_NOT_EXIST (237) or SP_SHIFTASS_DOES_NOT_EXIST (236) will be returned, as appropriate.
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
postings | object | N/A | A posting is an association between an operative and a team (TeamID) which represents the fact that the operative is assigned to that team for a period of time between startDate and endDate. By implication, the operative is also assigned to the FRU containing the IRU containing that team for that time period, and so may be allocated jobs that have been booked into that FRU. Postings can’t overlap in time, but there can be gaps between an operative’s postings when he can’t be assigned any jobs or standard activities.
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
skills | array | An operative may have any number of skills, each for a particular time period.
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
shifts | object | N/A |
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
defaultRangeLKs | object |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
defaultRegionLKs | object |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
pubHols | string | SS: 30 | SS Field: shifts.pubHols |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
workPatt | object | This allowsLocalKnowledgeRanges, Local Knowledge Regions, Local Knowledge Centres, Start Locations and End Locations to be supplied as part of a multi-week repeating work pattern.
|
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
options | object | N/A |
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
externalData | object | N/A |
|
HTTP Response
Success
On success, a JSON-formatted version of the Scheduling "EmpUpdateRequest" API response will be returned.
{ "Success": true, "Code": 0, "Message": "OK", "Payload": { "result": { "type": "OK", "code": "0" } } }
Error
On error, a JSON-formatted version of the Scheduling "EmpUpdateRequest" API response will be returned.
{ "Success": false, "Code": 9, "Payload": { "returnCode": { "type": "Error", "code": "SCH Error Code" } } }
Return Codes
In addition to the Standard Return Codes, and the Scheduling Error codes, the possible Return Codes from this API are: