Skip to navigation

Update Employee ID Settings

Changes how SalaryBox numbers new staff automatically, as the Employee ID settings screen in the app does. Send only what you want to change; anything left out stays as it is. Shared rules: see Writing data.

  • The body is closed: an unknown field is refused with 400 "Unknown field." Counts toward your write budget.
  • Needs the plan feature for automatic Employee IDs: otherwise 403.
  • At least one field is required: otherwise 400 "Send at least one field to change."
  • enabled switches automatic numbering on or off. prefix is up to 50 characters ("" for none). next_number is 1 or more. padding is 0-10.
  • Staff who already have an ID keep it; only staff added afterwards are numbered.
  • The response has the settings after the change, the same as Fetch Employee ID Settings.

Authentication

AuthorizationApi-Key

Format: “Api-Key {api-key}”

Request

This endpoint expects an object.
enabledbooleanOptional
Switch automatic numbering on or off.
prefixstringOptional<=50 characters

Letters put before the number, for example EMP. "" for none.

next_numberintegerOptional>=1
The number the next new staff member gets.
paddingintegerOptional0-10

Digits the number is zero-padded to.

Response

The settings were saved. data has the settings after the change.

messagestring
statusboolean
dataobject

Errors

400
Bad Request Error
403
Forbidden Error