Entities - Update entity

API Url

Update an existing entity record.

GET
http://localhost:16010/ProMarkREST/web/Entity/data/{entity}

Permissions: user

Request headers

FieldTypeDescription
Accept-LanguageoptionalString

=en-GB Language use for localization.

X-ClientoptionalString

=Client type.

Allowed values:"Portal""Mobile""Admin"
X-RoleoptionalNumber

ProMark role (1: Employee, 2: User).

Allowed values:{12}
X-WebPart-IdoptionalNumber

Unique web-part identifier.

Path parameters

FieldTypeDescription
entityString

Name of the entity.

Parameter

FieldTypeDescription
requestObject

Main object containing the request data.

  dataObject

Object containg data to be uploaded.

Request example for updating a department:

{
"request": {
"data": {
"departments": [
{
"id": "TEX",
"description": "Texas production",
"inactive": false,
"inScrollList": false,
"suppressAtTerminal": false,
"sendToApproval": false,
"sendTo2ndLevelApproval": false,
"categories": [
{
"id": "BLUE",
"description": "Blue collar employees"
}
]
}
]
}
}
}

Error 4xx

FieldTypeDescription
responseObject

Main object containing the response data.

  dataObject

Object containing the requested data (empty).

  errorCodeNumber

Error code.

  errorMessageString

Error description.