Applies to: Labor API
Find problems and solutions related to managing timecards and breaks using the Labor API.
Note
The Shift object and related endpoints, data types and webhook events are deprecated in Square API version 2025-05-21 and replaced by Timecard equivalents. For more information, see Migration notes.
The error response says that the team member can only have one open timecard (or shift) at a time.
Cause
The team member has an open timecard (or shift) from a previous day that needs to be closed before a new one can be created.
Solution
To find the open timecard, call SearchTimecards and verify that the
end_atfield is null or missing.When checking for an open timecard for a team member, use the
statusandteam_member_idsquery filters, as shown in the following example:Search timecards
Note that the response is an empty object if the team member doesn't have an
OPENtimecard:{}To end the timecard, call UpdateTimecard and set the
end_attime.
Cause
An idempotency key was reused for the CreateTimecard (or CreateShift) request.
Solution
Generate a new idempotency key and resend the request.
There are no overlapping timecards (or shifts) for the team member and the body of the update request is formed correctly.
Cause
An open Break needs to be closed.
Solution
Iterate the Break objects in the breaks field in the returned object. When a Break with no end_at property is found, set the property to the current time and resend your update request.
Cause
A filter field is invalid (REST only) or an enum value is invalid (REST and SDK). When the search endpoint receives a filter field or an enum value it doesn't recognize, the related filter criteria is ignored.
Solution
Enum values and field names are case-sensitive. Confirm that the field name is correct and lowercase (REST) and the provided enum values match their definition in the Square API Reference.