Skip to main content
PATCH

Auf einen Blick

Betriebsverhalten

Aktualisiert eine Division. Wird X-Tenant-ID gesendet, muss der Header zum Tenant der Division passen. Mit dryRun=true gibt die API die projizierte Division zurück, ohne sie zu speichern.
  • Parent-Änderungen müssen im selben Tenant bleiben und dürfen keinen Zyklus erzeugen.
  • Verwenden Sie parentId: null für Root und costCenter: null, um die Kostenstelle zu leeren.

Häufige Fehler

Die Response-Liste der Operation und die Seite Fehlerbehandlung sind für die vollständige Behandlung maßgeblich.

Vor der Implementierung

  • Erzeugen und protokollieren Sie für den Versuch eine neue X-Request-ID.
  • Behandeln Sie jeden dokumentierten Response-Status.
  • Protokollieren Sie weder X-API-Key noch unnötige personenbezogene Daten.
  • Gleichen Sie Hierarchie und aktuellen Ressourcenstatus ab, bevor Sie einen mehrdeutigen Write wiederholen.

Zugehöriger Integrationsleitfaden

Prüfen Sie den vollständigen Prozess sowie Status-, Retry- und Betriebsmuster für diese Operation.

Autorisierungen

X-API-Key
string
header
erforderlich

JobHandy integration API key. Send the credential in the X-API-Key header. Treat the key as a secret and use it only from trusted server-side environments.

Header

X-Tenant-ID
string
inactive
optional
not sent by default

Narrows the operation to one tenant in the API key's scope. Any referenced or target resource must be accessible through that tenant. In interactive clients, use the {{tenantId}} variable when a tenant must be selected. Keep the header disabled when tenant selection is not required.

Pattern: ^[0-9a-fA-F]{24}$
X-Request-ID
string<uuid>
inactive
optional
not sent by default

Optional request identifier. If supplied, it must be a UUID v4 or v7 and is returned unchanged in every response. If omitted, the API generates one. Invalid values return 400 INVALID_REQUEST_ID. If your client uses a {{requestId}} variable, refresh it with a new UUID version 4 or 7 for every HTTP request attempt. Keep the header disabled to let the API generate the request identifier.

Pattern: ^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[47][0-9a-fA-F]{3}-[89aAbB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}$

Pfadparameter

id
string
erforderlich

Division ID.

Pattern: ^[0-9a-fA-F]{24}$
Beispiel:

"68920e08eeaea4f2301eecb3"

Abfrageparameter

dryRun
boolean
inactive
optional
server default: false
not sent by default

When true, the API validates the request without applying the change. The operation's responses specify the returned representation. When omitted, the server uses false.

Beispiel:

true

Body

application/json

The JSON request body must not exceed 5,242,880 bytes.

Fields accepted when updating a division. At least one field is required.

name
string
inactive
optional
not sent by default

New division name. It must be unique among siblings.

Minimum string length: 1
Beispiel:

"Enterprise Sales"

parentId
string | null
inactive
nullable
optional
not sent by default

New parent division ID. Use null to move the division to the root level.

Pattern: ^[0-9a-fA-F]{24}$
Beispiel:

"68920e08eeaea4f2301eecb3"

order
number
inactive
optional
not sent by default

New display order among sibling divisions.

Beispiel:

2

costCenter
string | null
inactive
nullable
optional
not sent by default

Replacement cost center. Use null to clear the existing value.

Beispiel:

null

Antwort

Returns the updated division, or the projected division when dryRun=true.

Division details.

id
string
erforderlich
read-only

Division ID. A create dry run returns a preview ID that cannot be used in later requests.

Beispiel:

"68920e08eeaea4f2301eecb3"

tenant
string
erforderlich
read-only

ID of the tenant that owns the division.

Pattern: ^[0-9a-fA-F]{24}$
Beispiel:

"68a000000000000000000010"

name
string
erforderlich

Division name.

Beispiel:

"Sales"

parentId
string | null
erforderlich
nullable

Parent division ID, or null for a root division.

Minimum string length: 1
Pattern: ^[0-9a-fA-F]{24}$
Beispiel:

null

order
number
erforderlich

Display order among sibling divisions.

Beispiel:

1

costCenter
string | null
erforderlich
nullable

Customer-defined cost center, or null when none is assigned.

Minimum string length: 1
Beispiel:

"CC-SALES"

createdAt
string<date-time>
erforderlich
read-only

UTC creation timestamp.

Minimum string length: 1
Pattern: Z$
Beispiel:

"2026-01-15T10:30:00.000Z"

updatedAt
string<date-time>
erforderlich
read-only

UTC timestamp of the latest update.

Minimum string length: 1
Pattern: Z$
Beispiel:

"2026-07-01T08:15:00.000Z"

Zuletzt geändert am 27. August 2026