List shifts
curl --request GET \
--url https://api.rootly.com/v1/shifts \
--header 'Authorization: Bearer <token>'
{
"data": [
{
"id": "143d1304-7a36-4bcd-bd4a-af1621b5031e",
"type": "shifts",
"attributes": {
"schedule_id": "e65b2a99-0490-4e98-95a6-a98f4c304b3e",
"rotation_id": "ce825090-0e41-4d0e-841f-8516db024398",
"starts_at": "2024-07-02T21:00:00.000-07:00",
"ends_at": "2024-07-02T23:00:00.000-07:00",
"is_override": true
},
"relationships": {
"shift_override": {
"data": null
},
"user": {
"data": {
"id": "462",
"type": "users"
}
}
}
},
{
"id": "be3f95c3-3373-49a8-84cf-1b49fcd4b4a5",
"type": "shifts",
"attributes": {
"schedule_id": "e65b2a99-0490-4e98-95a6-a98f4c304b3e",
"rotation_id": "6d0dbb5f-c99b-44ae-b0a7-0226f20c21d5",
"starts_at": "2024-07-02T19:00:00.000-07:00",
"ends_at": "2024-07-02T21:00:00.000-07:00",
"is_override": false
},
"relationships": {
"shift_override": {
"data": null
},
"user": {
"data": {
"id": "462",
"type": "users"
}
}
}
}
]
}
Bearer authentication header of the form Bearer <token>
, where <token>
is your auth token.
comma separated if needed. eg: shift_override,user
shift_override
, user
Start range for shifts
End range for shifts
success
The response is of type object
.
Was this page helpful?
curl --request GET \
--url https://api.rootly.com/v1/shifts \
--header 'Authorization: Bearer <token>'
{
"data": [
{
"id": "143d1304-7a36-4bcd-bd4a-af1621b5031e",
"type": "shifts",
"attributes": {
"schedule_id": "e65b2a99-0490-4e98-95a6-a98f4c304b3e",
"rotation_id": "ce825090-0e41-4d0e-841f-8516db024398",
"starts_at": "2024-07-02T21:00:00.000-07:00",
"ends_at": "2024-07-02T23:00:00.000-07:00",
"is_override": true
},
"relationships": {
"shift_override": {
"data": null
},
"user": {
"data": {
"id": "462",
"type": "users"
}
}
}
},
{
"id": "be3f95c3-3373-49a8-84cf-1b49fcd4b4a5",
"type": "shifts",
"attributes": {
"schedule_id": "e65b2a99-0490-4e98-95a6-a98f4c304b3e",
"rotation_id": "6d0dbb5f-c99b-44ae-b0a7-0226f20c21d5",
"starts_at": "2024-07-02T19:00:00.000-07:00",
"ends_at": "2024-07-02T21:00:00.000-07:00",
"is_override": false
},
"relationships": {
"shift_override": {
"data": null
},
"user": {
"data": {
"id": "462",
"type": "users"
}
}
}
}
]
}