v1

latestOpenAPI 3.1.02026-07-24112760.5 KB
Swaps

Create a new shift swap

Create a new shift swap with the given details.

post/api/v1/shift_swaps

Request body

cancel_requestedboolean nullable

Whether the shift swap has been requested to be cancelled

endstring date-time nullable

The new proposed end time (UTC) of the shift e.g 2023-07-27 06:30:00+00

find_replacementboolean nullable

Whether a replacement is needed to be found.

group_idstring nullable

The ID of the group the shift swap belongs to

has_update_permission_boolean

Temporary field to tell the client whether the person requesting the shift swap has update permissions

notesstring nullable

Notes

offer_idinteger required

The ID of the person who offered the shift

offer_typestring required

The type of change being requested

publish_calendarboolean nullable

How person who made swap request should get notified when status changes

publish_emailboolean nullable

How person who made swap request should get notified when status changes

publish_slackboolean nullable

How person who made swap request should get notified when status changes

publish_smsboolean nullable

How person who made swap request should get notified when status changes

reasonstring nullable

The reason for approving or denying a shift request

shift_idinteger nullable

The ID of the shift being swapped

startstring date-time nullable

The new proposed start time (UTC) of the shift e.g 2023-07-27 06:30:00+00

statusstring nullable

The status of the shift swap

valuenumber nullable

The value of the shift swap

Response

Successful Response

archivedboolean nullable

Whether the shift swap has been archived

cancel_requestedboolean nullable

Whether the shift swap has been requested to be cancelled

endstring date-time nullable

The new proposed end time (UTC) of the shift e.g 2023-07-27 06:30:00+00

find_replacementboolean nullable

Whether a replacement is needed to be found.

group_idstring nullable

The ID of the group the shift swap belongs to

idinteger required

The unique ID of the shift swap

notesstring nullable

Notes

offer_idinteger required

The ID of the person who offered the shift

offer_typestring required

The type of change being requested

publish_calendarboolean nullable

How person who made swap request should get notified when status changes

publish_emailboolean nullable

How person who made swap request should get notified when status changes

publish_slackboolean nullable

How person who made swap request should get notified when status changes

publish_smsboolean nullable

How person who made swap request should get notified when status changes

reasonstring nullable

The reason for approving or denying a shift request

shift_idinteger nullable

The ID of the shift being swapped

startstring date-time nullable

The new proposed start time (UTC) of the shift e.g 2023-07-27 06:30:00+00

statusstring nullable

The status of the shift swap

time_createdstring date-time required

The time when the shift swap was created

time_updatedstring date-time required

The time when the shift swap was last updated

valuenumber nullable

The value of the shift swap