Admins
Manage account role assignments
An Admin object looks like:
POST /api/v1/accounts/:account_id/admins
POST /api/v1/accounts/:account_id/admins
Scope: url:POST|/api/v1/accounts/:account_id/admins
Flag an existing user as an admin within the account.
Request Parameters:
Parameter | Type | Description |
---|---|---|
| Required | The id of the user to promote. |
|
|
created with the given role. Defaults to ‘AccountAdmin’. |
|
| The user’s admin relationship with the account will be created with the given role. Defaults to the built-in role for ‘AccountAdmin’. |
|
| Send a notification email to the new admin if true. Default is true. |
Returns an Admin object.
DELETE /api/v1/accounts/:account_id/admins/:user_id
DELETE /api/v1/accounts/:account_id/admins/:user_id
Scope: url:DELETE|/api/v1/accounts/:account_id/admins/:user_id
Remove the rights associated with an account admin role from a user.
Request Parameters:
Parameter | Type | Description |
---|---|---|
|
|
|
| Required | The id of the role representing the user’s admin relationship with the account. |
Returns an Admin object.
GET /api/v1/accounts/:account_id/admins
GET /api/v1/accounts/:account_id/admins
Scope: url:GET|/api/v1/accounts/:account_id/admins
A paginated list of the admins in the account
Request Parameters:
Parameter | Type | Description |
---|---|---|
|
| Scope the results to those with user IDs equal to any of the IDs specified here. |
Returns a list of Admin objects.
GET /api/v1/accounts/:account_id/admins/self
GET /api/v1/accounts/:account_id/admins/self
Scope: url:GET|/api/v1/accounts/:account_id/admins/self
A paginated list of the current user’s roles in the account. The results are the same as those returned by the List account admins endpoint with user_id
set to self
, except the “Admins - Add / Remove” permission is not required.
Returns a list of Admin objects.
© Instructure, Inc. Generated on Wed Nov 6 14:20:04 2024 This documentation is generated directly from the Canvas LMS source code, available on Github.
Last updated