Skip to content

List duty arrangements

GET
/v1/rotations/{rotationId}/duty-arrangements
curl --request GET \
--url 'https://api.roundrobinbot.eu/v1/rotations/example/duty-arrangements?from=2026-04-15T12%3A00%3A00Z&to=2026-04-15T12%3A00%3A00Z' \
--header 'Authorization: Bearer <token>'

Requires read:oncall. Returns active arrangements overlapping a UTC range of at most 90 days. Cancelled arrangements are excluded. The response ETag identifies the rotation version for a later write. A range with missing bounds, a nonzero UTC offset or an end at or before its start returns 422 with invalidArrangementRange.

rotationId
required
string

The rotation identifier.

from
required
string format: date-time

The inclusive range start with UTC offset zero.

to
required
string format: date-time

The exclusive range end with UTC offset zero, at most 90 days after from.

OK

Media typeapplication/json

Active arrangements overlapping the requested range, with current cell capabilities.

object
items
required

Matching arrangements ordered by start and identifier. Cancelled arrangements are excluded.

Array<object>

An interval assignment. Its recorded terms remain distinct from actual served history.

object
id
required

The arrangement identifier.

string
rotationId
required

The rotation identifier.

string
cellId
required

The rotation cell identifier.

string
userId
required

The assigned person’s Slack user identifier.

string
from
required

The inclusive UTC start.

string format: date-time
to
required

The exclusive UTC end.

string format: date-time
revision
required

The arrangement revision used when changing or ending it.

integer | string format: int64
/^-?(?:0|[1-9]\d*)$/
state
required

active or cancelled. An active record can describe an interval that has already ended.

string
kind
required

directAssignment, acceptedCover or swapLeg. Direct-assignment writes change or end only directAssignment.

string
origin
One of:
null
originalSnapshot
One of:
null
turnSelection
One of:
null
capabilities
required

Direct-assignment capability for each rotation cell.

Array<object>

Current direct-assignment capability for a rotation cell.

object
cellId
required

The rotation cell identifier.

string
canAssign
required

Whether the caller can submit a direct assignment, subject to term and conflict validation.

boolean
reason
required

A refusal code when assignment is unavailable; otherwise null.

null | string
eligibleUserIds
required

Slack user identifiers of current lane members, excluding known deactivated users and bots. An unknown profile does not remove lane membership.

Array<string>
from
required

The requested inclusive UTC start.

string format: date-time
to
required

The requested exclusive UTC end.

string format: date-time
complete
required

Whether the full matching arrangement list was returned.

boolean
Examplegenerated
{
"items": [
{
"id": "example",
"rotationId": "example",
"cellId": "example",
"userId": "example",
"from": "2026-04-15T12:00:00Z",
"to": "2026-04-15T12:00:00Z",
"revision": 1,
"state": "example",
"kind": "example",
"origin": {
"userIds": [
"example"
],
"complete": true
},
"originalSnapshot": {
"asOfUtc": "2026-04-15T12:00:00Z",
"from": "2026-04-15T12:00:00Z",
"to": "2026-04-15T12:00:00Z",
"complete": true,
"segments": [
{
"from": "2026-04-15T12:00:00Z",
"to": "2026-04-15T12:00:00Z",
"userIds": [
"example"
],
"resolved": true
}
]
},
"turnSelection": {
"kind": "example",
"from": "2026-04-15T12:00:00Z",
"to": "2026-04-15T12:00:00Z"
}
}
],
"capabilities": [
{
"cellId": "example",
"canAssign": true,
"reason": "example",
"eligibleUserIds": [
"example"
]
}
],
"from": "2026-04-15T12:00:00Z",
"to": "2026-04-15T12:00:00Z",
"complete": true
}