Skip to content
ShiftlyDevelopers
Documentation menu

Open-shift requests

Staff asking to work a published shift nobody holds. Managers decide them in Shiftly. A request is removed, not kept, when the shift is deleted or the person is given an overlapping shift.

Needs the roster:read permission, depending on the operation. The business sees it as "Rosters and shifts".

Fields

OpenShiftRequest fields
FieldTypeAccessMeaning
idstringRead-onlyThe request.
shift_idstringRead-onlyThe open shift asked for. Read it at /shifts/{id}.
employee_idstringRead-onlyWho asked for it.
location_idstringRead-onlyWhere the shift is.
status"pending", "accepted", "rejected"Read-onlypending until a manager decides it in Shiftly. accepted means the person was given the shift; rejected means it went to someone else or was turned down.
requested_attimestampRead-onlyWhen the person asked.
created_attimestampRead-onlyWhen the record was created.
updated_attimestampRead-onlyWhen the record last changed.

Operations

List open-shift requests

GET/v1/open-shift-requests

Permission: roster:read

Query parameters
ParameterTypeMeaning
limitinteger, default 50, up to 200OptionalHow many records per page. Up to 200.
afterstringOptionalThe next_cursor from the previous page.
updated_sincetimestampOptionalOnly records changed at or after this moment. Pair it with include_archived to see removals.
include_archived"true", "false"OptionalInclude records that have been archived.
location_idstringOptionalOnly this location.
status"pending", "accepted", "rejected"OptionalOnly records in this status.
shift_idstringOptional
employee_idstringOptionalOnly this person.
200 response
{
  "data": [
    {
      "id": "66f1c2a4b3d9e8f7a6b5c4d3",
      "shift_id": "66f1c2a4b3d9e8f7a6b5c4d3",
      "employee_id": "66f1c2a4b3d9e8f7a6b5c4d3",
      "location_id": "66f1c2a4b3d9e8f7a6b5c4d3",
      "status": "pending",
      "requested_at": "2026-10-06T09:00:00+11:00",
      "created_at": "2026-10-06T09:00:00+11:00",
      "updated_at": "2026-10-06T09:00:00+11:00"
    }
  ],
  "has_more": true,
  "next_cursor": "text"
}
Refusals
StatusWhen
400The error's code is invalid_request or range_too_long. The Errors page describes each code.
401The error's code is invalid_token or token_expired. The Errors page describes each code.
403The error's code is origin_not_allowed, permission_denied, not_available, connection_disconnected, connection_suspended or app_suspended. The Errors page describes each code.
404There is nothing at this address, or no such record in this business.
429Too many requests. Retry-After says when to try again.
500Something went wrong at Shiftly. Quote the request id.
503This environment is not set up for partner apps yet.

Get one open-shift request

GET/v1/open-shift-requests/{id}

Permission: roster:read

200 response
{
  "id": "66f1c2a4b3d9e8f7a6b5c4d3",
  "shift_id": "66f1c2a4b3d9e8f7a6b5c4d3",
  "employee_id": "66f1c2a4b3d9e8f7a6b5c4d3",
  "location_id": "66f1c2a4b3d9e8f7a6b5c4d3",
  "status": "pending",
  "requested_at": "2026-10-06T09:00:00+11:00",
  "created_at": "2026-10-06T09:00:00+11:00",
  "updated_at": "2026-10-06T09:00:00+11:00"
}
Refusals
StatusWhen
400The error's code is invalid_request or range_too_long. The Errors page describes each code.
401The error's code is invalid_token or token_expired. The Errors page describes each code.
403The error's code is origin_not_allowed, permission_denied, not_available, connection_disconnected, connection_suspended or app_suspended. The Errors page describes each code.
404There is nothing at this address, or no such record in this business.
429Too many requests. Retry-After says when to try again.
500Something went wrong at Shiftly. Quote the request id.
503This environment is not set up for partner apps yet.