Skip to main content
PUT
Update department

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

organizationId
string
required

String. The organization's internal ID (32-character hex string) or its externalSourceId. When the value matches the format of an internal ID, the internal ID takes precedence.

Example:

"11adfe2a080040e3892ffb89c21ec44e"

departmentId
string
required

String. The ID of the department to update, as returned in the id field of the response. Lookup by externalSourceId is not supported for departments, unlike organizationId.

Example:

"9360d03ad7294220868d67f42a2a144d"

Body

application/json

Partial update: only the properties present in the body are changed, the rest are left unchanged. Any other property, such as id, level or customDimensionPresetValues from a GET response, is ignored, so a department returned by GET can be modified and sent back as is. All properties are optional.

name
string

Optional. String, maximum 255 characters. Display name of the department. When present, it must be non-empty and not whitespace-only. Leading and trailing whitespace is trimmed.

Maximum string length: 255
externalSourceId
string | null

Optional. String or null, maximum 255 characters. External source identifier, for example the department's ID in an integrated system. Leading and trailing whitespace is trimmed. Null or an empty value clears it.

Maximum string length: 255
parentId
string | null

Optional. String or null. The id of the department to move this one under. It must be a department in the same organization, and not this department or one of its descendants. The department's sub-departments move with it, and vatType is left unchanged by a move. Null or an empty value moves the department back to top level, directly under the organization's root department. The organization's root department cannot be moved: a non-empty value on it is rejected, while null or an empty value is ignored.

vatType
enum<string> | null

Optional. String or null, one of USE_CATEGORY, NON_DEDUCTABLE_VAT or DEDUCTABLE_VAT. VAT deduction handling for this department, case-sensitive. Applies to this department only: it is not inherited from the parent or passed on to sub-departments. Null or an empty value resets it to USE_CATEGORY.

Available options:
USE_CATEGORY,
NON_DEDUCTABLE_VAT,
DEDUCTABLE_VAT,
null

Response

OK — returns the updated department

id
string
required

Unique identifier of the department.

externalSourceId
string | null
required

External source identifier of the department, if set by an integration. Null when not set.

name
string
required

Display name of the department.

parentId
string | null
required

The id of the parent department. Null only for the organization's own root unit (level 0). Every other department, including a top-level one directly under the root, has this set to its parent's id.

vatType
enum<string>
required

VAT deduction handling for this department. Defaults to USE_CATEGORY when not explicitly set.

Available options:
USE_CATEGORY,
NON_DEDUCTABLE_VAT,
DEDUCTABLE_VAT
customDimensionPresetValues
object[]
required

Preset custom dimension values configured for this department, in the order they were created. The order is stable, so identical requests return the values in the same order. Excludes values belonging to deleted dimension definitions.

level
integer
required

Depth of the department within the organization's unit hierarchy. The organization's implicit root unit is level 0; a genuine top-level department is level 1.