Skip to main content
POST

Authorizations

Authorization
string
header
required

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

Body

application/json
operation
enum<string>
required

Adjustment operation. Any other value is rejected with 422 validation on operation (validator.invalid_type).

Available options:
add,
subtract
employeeId
string<uuid>
required

Employee whose balance is adjusted. Must belong to the company of the token.

from
string<date>
required

First day of the period (Y-m-d). Must not be after to (422 validation on from: validator.invalid_date).

Example:

"2026-01-01"

to
string<date>
required

Last day of the period (Y-m-d), inclusive. It can be equal to from.

Example:

"2026-01-31"

balanceBeforeSeconds
integer
required

Balance the client read before adjusting, in seconds. Required unless operation is reset (then optional and not checked). See the concurrency note above.

Example:

7200

amountSeconds
integer

Seconds to add or subtract. Optional in the validator, but when omitted (or not greater than zero) on add/subtract nothing is applied. Ignored on reset.

Example:

3600

source
enum<string>

Balance the adjustment applies to. Optional: when omitted it defaults to total_balance, except when the policy of the employee is hybrid with separated positive/negative balances, where it is mandatory (422 hybrid_independent_policy_required). When the from-to period covers days of more than one policy, the policy of the latest closed day (up to yesterday) decides; a period with no closed day yet uses its latest day. Ignored on reset unless it is a rule source. Any value outside the enum is rejected with 422 validation on source (validator.invalid_type). For a rule, send the source of the rule as returned by GET /overtime-policies/v1/employees/{employeeId}/rule-balances.

Available options:
total_balance,
positive_balance,
negative_balance,
multiplier_rule,
typifying_rule
note
string | null

Free text stored with the adjustment and shown in its history

ruleId
string<uuid>

Rule whose balance is adjusted (422 validation validator.invalid_uuid when it is not a UUID). Mandatory when source is multiplier_rule or typifying_rule (422 validation on ruleId: validator.rule_ids_required_for_rule_source); rejected when source is any other value or is omitted (422 rule_id_not_allowed_for_source). It must be a rule of the company of the token of the kind the source names (422 rule_adjustment_rule_not_found). Send the ruleId of an item of GET /overtime-policies/v1/employees/{employeeId}/rule-balances together with its source.

Example:

"55555555-5555-4555-8555-555555555555"

bucket
enum<string>

Balance the adjustment belongs to, rest (time off) or paid (remuneration). Mandatory when any policy version of the employee in the from-to period keeps separate rest and remuneration balances (422 adjustment_bucket_required), also on reset, which then brings only that balance to zero. Rejected otherwise and with a rule source (422 adjustment_bucket_not_allowed). With bucket, balanceBeforeSeconds and balanceAfterSeconds refer to the balance of that bucket. Adjustments created without it count as paid in those policies.

Available options:
rest,
paid
Example:

"rest"

Response

Adjustment processed. The status is 200 (not 201) because the controller answers through fromRawData; meta is the default single-object meta.

data
object
required
meta
object
required