Departments
A Department can help split the reporting between major parts of an organisation.
Searching existing departments
Existing departments can be searched using GET /api/department
.
Note this is a paginated response, and will return by default up to 100 results. Use the skip
and take
query parameters to get next pages:
GET /api/department?skip=300&take=100
See reference for supported search criteria: GET /api/department
Loading additional details:
A department can be retrieved by its id or code:
GET /api/department/1d29276e-700b-49e6-88b9-0b037e9dc157
GET /api/department/DEP100
Additional details can be included:
resources
subDepartments
: child departments
The details can be loaded with the include
parameter:
GET /api/department/DEP100?include=resources,subDepartments
Creating a new department
This is the minimal example to create a department:
POST /api/department
{
"code": "DEP100",
"description": "Department100"
}
Complete example:
This is a complete example that contains all supported fields.
Note the codes might vary in your environment so be sure to consult the available reference catalogs in Iplicit or via the catalogs endpoints
POST /api/department
{
"code": "DEP100",
"description": "Department100",
"legacyRef": "DEP1",
"legalEntityId": "LEGEA",
"managerResourceId": "MAN1",
"parentDepartmentId": "DEP000"
}
See reference for supported create criteria: POST /api/department
Updating an existing department
The updating of departments is done by patching: only the specified fields will be updated.
The following sections are completely replaced if they are specified in the patch object:
description
parentDepartmentId
legalEntityId
legacyRef
managerResourceId
Examples
Simple update
PATCH /api/department/{{departmentRef}}
{
"description": "Department100A"
}
This will only update the description field specified, keeping everything else as is.
Locking
Locking (soft deleting) a department:
POST /api/department/{{departmentRef}}/lock
Unlocking:
POST /api/department/{{departmentRef}}/unlock
Locked departments have isActive
field set to false
.