PUT /v2/labor/shifts/{id}
Updates an existing Shift
.
When adding a Break
to a Shift
, any earlier Break
instances in the Shift
have
the end_at
property set to a valid RFC-3339 datetime string.
When closing a Shift
, all Break
instances in the Shift
must be complete with end_at
set on each Break
.
Servers
- https://connect.squareup.com
Path parameters
Name | Type | Required | Description |
---|---|---|---|
id |
String | Yes |
The ID of the object being updated. |
Request headers
Name | Type | Required | Description |
---|---|---|---|
Content-Type |
String | Yes |
The media type of the request body.
Default value: "application/json" |
Request body fields
Name | Type | Required | Description |
---|---|---|---|
shift |
Object | Yes |
A record of the hourly rate, start, and end times for a single work shift for an employee. This might include a record of the start and end times for breaks taken during the shift. |
shift.status |
String | No |
Describes the working state of the current |
shift.wage |
Object | No |
The hourly wage rate used to compensate an employee for this shift. |
shift.wage.title |
String | No |
The name of the job performed during this shift. Square labor-reporting UIs might group shifts together by title. |
shift.wage.hourly_rate |
Object | No |
Represents an amount of money. |
shift.wage.hourly_rate.amount |
Integer | No |
The amount of money, in the smallest denomination of the currency
indicated by |
shift.wage.hourly_rate.currency |
String | No |
The type of currency, in ISO 4217 format. For example, the currency
code for US dollars is See Currency for possible values. |
shift.updated_at |
String | No |
A read-only timestamp in RFC 3339 format; presented in UTC. |
shift.id |
String | No |
The UUID for this object. |
shift.location_id |
String | No |
The ID of the location this shift occurred at. The location should be based on where the employee clocked in. |
shift.team_member_id |
String | No |
The ID of the team member this shift belongs to. Replaced |
shift.timezone |
String | No |
The read-only convenience value that is calculated from the location based
on the |
shift.version |
Integer | No |
Used for resolving concurrency issues. The request fails if the version provided does not match the server version at the time of the request. If not provided, Square executes a blind write; potentially overwriting data from another write. |
shift.breaks[] |
Array | No |
A list of all the paid or unpaid breaks that were taken during this shift. |
shift.breaks[].id |
String | No |
The UUID for this object. |
shift.breaks[].expected_duration |
String | Yes |
Format: RFC-3339 P[n]Y[n]M[n]DT[n]H[n]M[n]S. The expected length of the break. |
shift.breaks[].name |
String | Yes |
A human-readable name. |
shift.breaks[].break_type_id |
String | Yes |
The |
shift.breaks[].start_at |
String | Yes |
RFC 3339; follows the same timezone information as |
shift.breaks[].end_at |
String | No |
RFC 3339; follows the same timezone information as |
shift.breaks[].is_paid |
Boolean | Yes |
Whether this break counts towards time worked for compensation purposes. |
shift.start_at |
String | Yes |
RFC 3339; shifted to the location timezone + offset. Precision up to the minute is respected; seconds are truncated. |
shift.employee_id |
String | No |
The ID of the employee this shift belongs to. DEPRECATED at version 2020-08-26. Use |
shift.end_at |
String | No |
RFC 3339; shifted to the timezone + offset. Precision up to the minute is respected; seconds are truncated. |
shift.created_at |
String | No |
A read-only timestamp in RFC 3339 format; presented in UTC. |
How to start integrating
- Add HTTP Task to your workflow definition.
- Search for the API you want to integrate with and click on the name.
- This loads the API reference documentation and prepares the Http request settings.
- Click Test request to test run your request to the API and see the API's response.