Skip to content

period.adjusted

The adjustments a timecard holds for a closed pay period are new or changed: changes recorded after that period closed (a late punch, a correction, a setup or policy change naming a day in it), paid in the period open when they were recorded. The closed period’s own timecard never changes; payroll pays these on top of it. Sent with the adjustments’ totals as they stand in this timecard each time they change; with none (“0.00”, no categories) when they left it, the closed period having been reopened. Kept in Time and Attendance’s own event log (apart from Connect’s) and delivered to its sinks: the tenant’s (/api/attendance/tenants/{tenant}/sinks) and the install’s (/api/attendance/sinks). The envelope’s endpoint is “attendance”, its package “houradvantage-attend”, and its device ”//” (the timecard holding the adjustments). The same event sent again has the same id.

Schema id: urn:houradvantage:events:3:period.adjusted

Fields

FieldTypeRequiredDescription
tenantstringyesThe tenant it is about.
personstringyesThe person’s id in the attendance engine (an employee’s id, or an unlinked person’s, ”~”).
sidestringyesWhich side the timecard is: “pay” (what the person is paid), or a bill side the tenant keeps (what a customer is billed).
firststring (date)yesThe first day of the pay period whose timecard holds the adjustments, YYYY-MM-DD.
laststring (date)yesThe last day of the pay period whose timecard holds the adjustments, YYYY-MM-DD.
periodstring (date)yesThe first day of the closed pay period they adjust, YYYY-MM-DD.
adjustmentsobjectyesThe adjustments’ totals in this timecard, as they stand.
adjustments.paidstringyesThe hours of the adjustments in paid categories, in decimal hours as the tenant keeps them (“4.00”, “-2.00”). pattern ^-?\d+(\.\d+)?$
adjustments.categoriesobjectyesHours by pay category, in decimal hours; negative where the closed period paid too much.
adjustments.record_codestringPresent where these adjustments include the whole difference between what the closed period was paid and what this version of the engine works out for it, which happens with the first change after an upgrade: the identifier of the code that worked out the closed period’s record. Left out for an ordinary late change.
adjustments.balancesobjectBalance adjustments by accrual category, in decimal hours: what the changes add to each balance (negative: take off), through the periods after the closed one. Left out where they move no balance.
becausearray of objectWhat marked the person for this recalculation, as the store knew it, in the order made: a setup item put (kind “setup”, its item kind and id, when it was stored, by whom and reason) a correction made (kind “correction”, its id), punches that arrived (kind “punches”: one, however many, with no id), or an operator asking for the person to be worked out again keeping nothing (kind “redo”, by whom and reason). Absent where nothing is known of what it was (a load, a policy, a punch).
because[].kind"setup" \"correction" \"punches" \
because[].idstring
because[].itemstringFor setup, the kind of the item (holiday, rate…).
because[].storedstring (date-time)
because[].bystring
because[].reasonstring

Example

{
"tenant": "acme",
"person": "4471",
"side": "pay",
"first": "2026-10-12",
"last": "2026-10-18",
"period": "2026-10-05",
"adjustments": {
"paid": "4.00",
"categories": {
"overtime": "-2.00",
"work": "6.00"
},
"balances": {
"pto": "0.75"
}
}
}

JSON Schema

period.adjusted.json
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "urn:houradvantage:events:3:period.adjusted",
"title": "period.adjusted: data",
"description": "The adjustments a timecard holds for a closed pay period are new or changed: changes recorded after that period closed (a late punch, a correction, a setup or policy change naming a day in it), paid in the period open when they were recorded. The closed period's own timecard never changes; payroll pays these on top of it. Sent with the adjustments' totals as they stand in this timecard each time they change; with none (\"0.00\", no categories) when they left it, the closed period having been reopened. Kept in Time and Attendance's own event log (apart from Connect's) and delivered to its sinks: the tenant's (/api/attendance/tenants/{tenant}/sinks) and the install's (/api/attendance/sinks). The envelope's endpoint is \"attendance\", its package \"houradvantage-attend\", and its device \"<person>/<side>/<first>\" (the timecard holding the adjustments). The same event sent again has the same id.",
"type": "object",
"properties": {
"tenant": {
"type": "string",
"description": "The tenant it is about."
},
"person": {
"type": "string",
"description": "The person's id in the attendance engine (an employee's id, or an unlinked person's, \"<group>~<person>\")."
},
"side": {
"type": "string",
"description": "Which side the timecard is: \"pay\" (what the person is paid), or a bill side the tenant keeps (what a customer is billed)."
},
"first": {
"type": "string",
"format": "date",
"description": "The first day of the pay period whose timecard holds the adjustments, YYYY-MM-DD."
},
"last": {
"type": "string",
"format": "date",
"description": "The last day of the pay period whose timecard holds the adjustments, YYYY-MM-DD."
},
"period": {
"type": "string",
"format": "date",
"description": "The first day of the closed pay period they adjust, YYYY-MM-DD."
},
"adjustments": {
"type": "object",
"description": "The adjustments' totals in this timecard, as they stand.",
"properties": {
"paid": {
"type": "string",
"description": "The hours of the adjustments in paid categories, in decimal hours as the tenant keeps them (\"4.00\", \"-2.00\").",
"pattern": "^-?\\d+(\\.\\d+)?$"
},
"categories": {
"type": "object",
"description": "Hours by pay category, in decimal hours; negative where the closed period paid too much.",
"additionalProperties": {
"type": "string",
"pattern": "^-?\\d+(\\.\\d+)?$"
}
},
"record_code": {
"type": "string",
"description": "Present where these adjustments include the whole difference between what the closed period was paid and what this version of the engine works out for it, which happens with the first change after an upgrade: the identifier of the code that worked out the closed period's record. Left out for an ordinary late change."
},
"balances": {
"type": "object",
"description": "Balance adjustments by accrual category, in decimal hours: what the changes add to each balance (negative: take off), through the periods after the closed one. Left out where they move no balance.",
"additionalProperties": {
"type": "string",
"pattern": "^-?\\d+(\\.\\d+)?$"
}
}
},
"required": [
"paid",
"categories"
]
},
"because": {
"type": "array",
"description": "What marked the person for this recalculation, as the store knew it, in the order made: a setup item put (`kind` \"setup\", its `item` kind and `id`, when it was `stored`, `by` whom and `reason`) a correction made (`kind` \"correction\", its `id`), punches that arrived (`kind` \"punches\": one, however many, with no id), or an operator asking for the person to be worked out again keeping nothing (`kind` \"redo\", `by` whom and `reason`). Absent where nothing is known of what it was (a load, a policy, a punch).",
"items": {
"type": "object",
"properties": {
"kind": {
"type": "string",
"enum": [
"setup",
"correction",
"punches",
"redo"
]
},
"id": {
"type": "string"
},
"item": {
"type": "string",
"description": "For setup, the kind of the item (holiday, rate...)."
},
"stored": {
"type": "string",
"format": "date-time"
},
"by": {
"type": "string"
},
"reason": {
"type": "string"
}
},
"required": [
"kind"
]
}
}
},
"required": [
"tenant",
"person",
"side",
"first",
"last",
"period",
"adjustments"
],
"examples": [
{
"tenant": "acme",
"person": "4471",
"side": "pay",
"first": "2026-10-12",
"last": "2026-10-18",
"period": "2026-10-05",
"adjustments": {
"paid": "4.00",
"categories": {
"overtime": "-2.00",
"work": "6.00"
},
"balances": {
"pto": "0.75"
}
}
}
]
}