Approval - Count pending approval records

API Url

Use it for loading how many approval entities are pending approval per perspective. A perspective can be Employee/Project etc.

GET
http://localhost:16010/ProMarkREST/web/Approval/counter

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.

Success 200

FieldTypeDescription
responseObject

Main object containing the response data.

  dataObject

Object containing the requested data.

    counterObject[]

Array of counters per perspective.

      countInteger

How many records are there to approve.

      nameString

Name of the perspective.

  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
{
"response": {
"data": {
"counter": [
{
"name": "employee",
"count": 100
},
{
"name": "project",
"count": 5
}
]
},
"errorCode": 0,
"errorMessage": ""
}
}