ProRoster - Update a demand

API Url

Use it for updating a Demand .

PUT
http://localhost:16010/ProMarkREST/rest/ProRoster/demands

Permissions: user

Parameter

FieldTypeDescription
requestObject

Main object containing the request data.

  dataObject

Object containg data to be uploaded.

    demandsObject[]

List of plan Demands.

      approvalGroupoptionalObject[]
        idoptionalString

Id of the approvalGroup.

        isLockedBoolean

Is the attribute locked.

        isRequiredBoolean

Is the attribute required.

      assignmentMethodoptionalObject[]
        isLockedBoolean

Is the attribute locked.

        isRequiredBoolean

Is the attribute required.

        methodoptionalString

Assignment methode Automatic = "A" or Manual "M".

      attendanceTimeoptionalObject[]

Attendance time interval.

        endTimeoptionalNumber

End time of the interval in seconds.

        isLockedBoolean

Is the attribute locked.

        isRequiredBoolean

Is the attribute required.

        startTimeoptionalNumber

Start time of the interval in seconds.

      backColoroptionalString

BackGround color in HEX without #.

      baseDemandIdoptionalNumber

Id of the base demand.

      categoryoptionalObject[]
        idString

Id of the category.

        isLockedBoolean

Is the attribute locked.

        isRequiredBoolean

Is the attribute required.

      dateDate

The date of the plan demand.

      dayProfileoptionalObject[]
        idoptionalString
        isLockedBoolean

Is the attribute locked.

        isRequiredBoolean

Is the attribute required.

      daysBeforeoptionalObject[]
        daysoptionalNumber

Accept days before shift takes place.

        isLockedBoolean

Is the attribute locked.

        isRequiredBoolean

Is the attribute required.

      departmentoptionalObject[]
        idoptionalString

Id of the department.

        isLockedBoolean

Is the attribute locked.

        isRequiredBoolean

Is the attribute required.

      descriptionoptionalString

Description of the base demand.

      foreColoroptionalString

ForeGround color in HEX without #.

      groupoptionalObject[]
        idoptionalString

Id of the group.

        isLockedBoolean

Is the attribute locked.

        isRequiredBoolean

Is the attribute required.

      idoptionalNumber

The Id of the plan demand.

      ignoreDayProfileoptionalObject[]
        isLockedBoolean

Is the attribute locked.

        valueBoolean
      maximumBidsoptionalObject[]
        amountNumber

Number of employees to bid in.

        isLockedBoolean

Is the attribute locked.

        isRequiredBoolean

Is the attribute required.

      nameoptionalString

The name of the plan demand.

      normalTimeoptionalObject[]

Normal time interval for variable day profiles.

        endTimeoptionalNumber

End time of the interval in seconds.

        startTimeoptionalNumber

Start time of the interval in seconds.

        isLockedBoolean

Is the attribute locked.

        isRequiredBoolean

Is the attribute required.

      planIdNumber

Id of the plan currently working on.

      qualificationSetupoptionalObject[]
        isLockedBoolean

Is the attribute locked.

        isRequiredBoolean

Is the attribute required.

        qualificationsoptionalObject[]
          idNumber

Id of the employee qualification.

          orderNumber
          primaryBoolean
      requiredEmployeesObject[]
        amountNumber

Number of employees

        isLockedBoolean

Is the attribute locked.

        isRequiredBoolean

Is the attribute required.

      versionoptionalNumber

Version of the plan demand.

Request example:

HTTP/1.1 200 OK
{
"request": {
"data": {
"demands": [
{
"id": 2153900338,
"baseDemandId": 2153905338,
"planId": 2153900339,
"date": "18-02-2018",
"name": "Bla",
"description": "blah, blah, blah, blah, blah",
"foreColor": "123400",
"backColor": "567800",
"version": 1,
"attendanceTime": [
{
"startTime": 0,
"endTime": 3600,
"isRequired": false,
"isLocked": true
}
],
"normalTimeInterval": [
{
"startTime": 0,
"endTime": 3600,
"isRequired": false,
"isLocked": true
}
],
"dayProfile": [
{
"id": "DAY",
"isRequired": false,
"isLocked": true
}
],
"requiredEmployees": [
{
"amount": 3,
"isRequired": false,
"isLocked": true
}
],
"department": [
{
"id": "0000007215",
"isRequired": false,
"isLocked": true
}
],
"assignmentMethod": [
{
"method": "A",
"isRequired": false,
"isLocked": true
}
],
"group": [
{
"id": "1",
"isRequired": false,
"isLocked": true
}
],
"approvalGroup": [
{
"id": "01",
"isRequired": true,
"isLocked": true
}
],
"maximumBids": [
{
"amount": 9,
"isRequired": false,
"isLocked": true
}
],
"category": [
{
"id": "02",
"isRequired": false,
"isLocked": true
}
],
"ignoreDayProfile": [
{
"value": true,
"isLocked": true
}
],
"daysBefore": [
{
"days": 2,
"isRequired": false,
"isLocked": true
}
],
"qualifications": [
{
"id": 2153900339,
"empQualId": "3",
"primary": true,
"order": 1,
"isRequired": true,
"isLocked": true
}
]
}
]
}
}
}

Success 200

FieldTypeDescription
responseObject

Main object containing the response data.

  messageoptionalObject

Object containing response messages.

    codeNumber

Message code.

    textString

Message text.

    typeString

Type of message.

Allowed values:"warning""info"

Success example:

HTTP/1.1 200 OK
{
"request": {
"data": {
"demands": [
{
"id": 2153900338,
"baseDemandId": 2153905338,
"planId": 2153900339,
"counter": 2,
"date": "18-02-2018",
"name": "Bla",
"description": "blah, blah, blah, blah, blah",
"foreColor": "123400",
"backColor": "567800",
"version": 1,
"normalTimeInterval": [
{
"startTime": 0,
"endTime": 3600,
"isRequired": false,
"isLocked": true
}
],
"dayProfile": [
{
"id": "DAY",
"isRequired": false,
"isLocked": true
}
],
"requiredEmployees": [
{
"amount": 3,
"isRequired": false,
"isLocked": true
}
],
"department": [
{
"id": "0000007215",
"isRequired": false,
"isLocked": true
}
],
"assignmentMethod": [
{
"method": "A",
"isRequired": false,
"isLocked": true
}
],
"group": [
{
"id": "1",
"isRequired": false,
"isLocked": true
}
],
"approvalGroup": [
{
"id": "01",
"isRequired": true,
"isLocked": true
}
],
"maximumBids": [
{
"amount": 9,
"isRequired": false,
"isLocked": true
}
],
"category": [
{
"id": "02",
"isRequired": false,
"isLocked": true
}
],
"daysBefore": [
{
"days": 2,
"isRequired": false,
"isLocked": true
}
],
"qualifications": [
{
"id": 2153900339,
"empQualId": "3",
"primary": true,
"order": 1,
"isRequired": true,
"isLocked": true
}
],
"notes": [
{
"id": 2163396278,
"text": "bring coffee in the morning",
"isEmpNote": true
},
{
"id": 2163396279,
"text": "no breaks during this shift"
}
]
}
]
},
"errorCode": 0,
"errorMessage": ""
}
}

Error 4xx

FieldTypeDescription
responseObject

Main object containing the response data.

  dataObject

Object containing the requested data (empty).

  errorCodeNumber

Error code.

  errorMessageString

Error description.