Roles
Roles define the kind of access that you are granting - i.e. you will be looking to group together similar access for Staff, Students, Security etc
You can assign Roles to People or to Groups (although we advise that you only apply a Role to a Group)
A Role can be considered the glue between a Channel and a Shift (a shift defines the times of the week)
Roles cannot be modified using the API but you can retrieve a list containing the role IDs. (for use when creating and updating people).
Listing all roles
Scopes required : account.role.readonly
GET /api/3/roles
Example Response
[
{
"id": 523,
"name": "Key holders",
"notes": "",
"shift_id": 1,
"created_at": "2013-04-30T16:00:21+01:00",
"updated_at": "2015-04-09T22:33:58+01:00"
},
{
"id": 556,
"name": "Office Staff",
"notes": "",
"shift_id": 1,
"created_at": "2013-11-06T16:30:26+00:00",
"updated_at": "2013-11-06T16:30:26+00:00"
},
{
"id": 1,
"name": "Staff",
"notes": "",
"shift_id": 1,
"created_at": "2012-08-28T18:07:43+01:00",
"updated_at": "2014-02-07T14:00:03+00:00"
}
]
Retrieve a role
Scopes required : account.role.readonly
GET /api/3/roles/:id
Example Response
{
"id": 523,
"name": "Key holders",
"notes": "",
"shift_id": 1,
"created_at": "2013-04-30T16:00:21+01:00",
"updated_at": "2015-04-09T22:33:58+01:00"
}