Correct a direct report's attendance day
/attendances/{id}/adjustattendance/adjust_teamRequires feature attendanceNot available in Claudeattendances.adjustLets a manager set the check-in and/or check-out time of one day of an employee who reports directly to them, with a reason, and on a break-tracking day replace its breaks. QHR recomputes the hours worked and the day's status (present, late…) from the new times; those sides are marked manual.
When to use: when a team member forgot to check in or out, or a device missed a scan. The employee's own route to the same result is a justification (time_incidents.submit_justification).
Prerequisites: the day's id. A missed check-in or check-out leaves an incident in the manager's queue, time_incidents.team_list, whose rows carry the day as attendance.record_id; HR finds any day as id in attendance_log.records. The token's owner must be the employee's direct manager; any other day answers 404. Days on approved leave and future days cannot be adjusted.
Side effects: the change and its reason are kept in the record's audit trail, deductions for the day are recalculated, and the employee is emailed what changed. Not offered to Claude, because it rewrites another person's working time, which feeds payroll.
Not available in Claude yet.
Before you call this
You will need ids that come from these operations:
Parameters
| Name | In | Type | Description | Example |
|---|---|---|---|---|
idRequired | path | integer | Attendance record (day) id: id in attendances.my_history (your own days), attendance.record_id in time_incidents.team_list (your team's days with an incident) or id in attendance_log.records (HR). | 58231 |
Accept-Language | header | string | Language of messages and translated labels. English when omitted. Allowed values: ar, en | ar |
Request body
application/json
| Field | Type | Description |
|---|---|---|
check_in_at | string (date-time) | New check-in time, ISO 8601 (UTC or with an offset). Leave out to keep it. |
check_out_at | string (date-time) | New check-out time, ISO 8601. Leave out to keep it. |
reasonRequired | string | Why the day is corrected; emailed to the employee and kept in the audit trail. |
breaks | array<object> | Tracked days only: the day's complete list of breaks, replacing the current one. Each break needs a start and an end inside the check-in and check-out, without overlaps. |
breaks[].started_at | string (date-time) | Break start, ISO 8601. |
breaks[].ended_at | string (date-time) | Break end, ISO 8601. |
Response
200 The corrected day.
| Field | Type | Description |
|---|---|---|
idRequired | integer | Attendance record id. |
dateRequired | string (date) | Work date, in the company's timezone. A night shift belongs to the date it started. |
statusRequired | string | present, late (arrived after the start plus the grace period), incomplete (checked in, not out), absent, on_leave, holiday or weekend. An early leave stays present; it shows in incidents.Allowed values: present, late, incomplete, absent, on_leave, holiday, weekend |
check_in_at | string (date-time) | Check-in time, UTC. |
check_out_at | string (date-time) | Check-out time, UTC. |
hours_worked | number | Hours worked, net of breaks on a day that tracks breaks; null until the day is closed. |
check_in_source | string | How that side was recorded: app (the QHR app or this API), device (a fingerprint or face device), manual (corrected by a manager or HR); null when there is no time.Allowed values: app, device, manual, null |
check_out_source | string | How that side was recorded: app (the QHR app or this API), device (a fingerprint or face device), manual (corrected by a manager or HR); null when there is no time.Allowed values: app, device, manual, null |
check_in_device | object | The device scan behind that side, when it came from a device. |
check_in_device.name | string | Device name. |
check_in_device.external_employee_no | string | The employee's number on the device. |
check_out_device | object | The device scan behind that side, when it came from a device. |
check_out_device.name | string | Device name. |
check_out_device.external_employee_no | string | The employee's number on the device. |
incidents | array<object> | Deductions this day produced (late arrival, early leave…), and whether the employee has explained each. Details with attendances.justification_context. |
incidents[].id | integer | Time incident id. |
incidents[].kind | string | absence, late, early_leave, short_hours or incomplete. |
incidents[].status | string | pending (under review), deducted or ignored. |
incidents[].justification_state | string | submitted or none. |
permissions | array<object> | Approved and pending hourly permissions on this day (history only). |
permissions[].id | integer | Permission request id. |
permissions[].kind | string | Permission kind, e.g. late_arrival, early_leave. |
permissions[].status | string | approved or pending. |
permissions[].start_time | string | Start, HH:MM local. |
permissions[].end_time | string | End, HH:MM local. |
tracks_breaks | boolean | True when this day records breaks (pause / resume). |
day_state | string | On a day that tracks breaks: working, paused or ended; null otherwise. |
ended_by | string | Who ended a tracked day: employee (from the app or a device) or system (closed automatically). |
break_minutes | integer | Minutes on break. |
breaks | array<object> | The day's breaks; empty when breaks are not tracked. |
breaks[].started_at | string (date-time) | Break start, UTC. |
breaks[].ended_at | string (date-time) | Break end, UTC; null while the break is running. |
breaks[].started_via | string | app or device. |
breaks[].ended_via | string | app or device. |
breaks[].started_device_name | string | Device that started the break. |
breaks[].ended_device_name | string | Device that ended the break. |
Errors
| HTTP | Code | Meaning | How to fix |
|---|---|---|---|
| 401 | token_missing | No Authorization: Bearer … header, or it is malformed. | Send Authorization: Bearer qhr_… with the full token. |
| 401 | token_invalid | The token is unknown or wrong, or its owner's account is locked. | Check the token was copied in full, or create a new one in QHR › Settings › API & Integrations. |
| 401 | token_expired | The token is past its expiry date. | Create a new token. |
| 401 | token_revoked | The token was revoked by its owner or an admin, or the owner was removed from the company (which revokes all their tokens). | Create a new token, or ask your admin. If the owner was removed, they must be re-invited to the company first. |
| 401 | tenant_inactive | The company account is suspended. | Contact QHR support. |
| 403 | token_read_only | This token can only read; the operation makes changes. | Use a token created with "Allow changes". |
| 403 | forbidden | The token owner's role lacks the permission this operation needs. | Ask an admin to grant the permission shown on this operation (x-permission). |
| 403 | employee_inactive | The token owner's employee record is not active. | HR must reactivate the employee record. |
| 403 | tenant_access_revoked | The token's owner is no longer an active member of this company. Rare: removing a member normally revokes their tokens, which answers 401 token_revoked instead. | The owner must be re-invited to the company, then create a new token. If the owner is still a member, contact QHR support. |
| 404 | not_found | The record does not exist, or you cannot see it. | Check the id. List the records first to get a valid one. |
| 422 | validation_failed | Refused: no reason, a time in the future or not valid, a future day, the employee is on approved leave that day, breaks sent for a day that does not track them or breaks outside the new times, or the day changed meanwhile. | Fix what error names and send again; on approved leave, cancel the leave first. |
| 422 | employee_required | The token's owner is a company user with no employee record, so they have no attendance. | Use a token created by a user who is linked to an employee, or ask HR to link this user to their employee record. |
entitlement_blocked · 429 rate_limited · 500 internal_error