Who is on call across the account's schedules: with no range, right now; with `user_id`, that person's shifts ("my shifts"). Shifts overlapping `since` to `until` (at most 90 days).
GET
/on_call
const url = 'https://api.siteqwality.com/on_call';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://api.siteqwality.com/on_call \ --header 'Authorization: Bearer <token>'Authorizations
Section titled “Authorizations ”Parameters
Section titled “ Parameters ”Query Parameters
Section titled “Query Parameters ” user_id
string format: uuid
Only this user’s shifts
schedule_id
string format: uuid
Only this schedule
since
string
RFC 3339 start; defaults to now
until
string
RFC 3339 end; defaults to since, at most 90 days after it
Responses
Section titled “ Responses ”Shifts, earliest first; gaps are left out
Media type application/json
Array<object>
One shift of one schedule, for the account-wide and per-user view (gaps left out).
object
schedule_id
required
string format: uuid
schedule_name
required
string
user_id
required
string format: uuid
source
required
Why someone is on call, or gap when nobody is.
string
layer_id
string | null format: uuid
layer_number
integer | null format: int32
override_id
string | null format: uuid
starts_at
string | null format: date-time
ends_at
string | null format: date-time
Example
[ { "source": "override" }]Bad UUID or timestamp, until before since, or a range over 90 days
Missing or invalid authentication
User or on-call schedule not found
Internal server error