Hi,
When admin assign a coadmin, he can choose to give permissions such as manage users, manage groups, view user's content, edit user's account, log in to users' accounts, view settings for your company, edit settings for your company, run new reports and access existing reports (there are checkbox for every permission, admin can select)
I find we have API to create user as coadmin, but do we have API to assign these different permissions??
The strange part is, I use update user API like this to make an existing user as a coadmin
curl https://api.box.com/2.0/users/USER_ID \
-H "Authorization: Bearer ACCESS_TOKEN" \
-d '{"role": "coadmin"}' \
-X PUTIt works, I can see from the Admin console, it became coadmin. but none of the checkbox is selected.
When I call get current user API, "role" doesn't even exist.
If I call create user API to create a new user, and set is as coadmin, like this
curl https://api.box.com/2.0/users \
-H "Authorization: Bearer ACCESS_TOKEN" \
-d '{"login": "***email address removed for privacy***", "name": "Ned","role":"coadmin"} \
-X POSTin the Admin console, this user is coadmin, and I can see the manage users, manage groups checkbox are selected.
but when I can get current user API, "role" still doesn't exist.
{
"type": "user",
"id":***phone number removed for privacy***",
"name": "Ned",
"login": "***email address removed for privacy***",
"created_at": "2017-08-01T14:15:18-07:00",
"modified_at": "2017-08-01T14:15:19-07:00",
"language": "en",
"timezone": "America/Los_Angeles",
"space_amount": ***number removed for privacy***40,
"space_used": 0,
"max_upload_size"***phone number removed for privacy***,
"status": "active",
"job_title": "",
"phone": "",
"address": "",
"avatar_url": "https://hello.app.box.com/api/avatar/large***phone number removed for privacy***"
}
So, how can I see the role (admin, coadmin, user) for user
and is there any API to assign different permissions (such as manage users, manage groups, view user's content, edit user's account, log in to users' accounts, view settings for your company, edit settings for your company, run new reports and access existing reports) for coadmin??
Thank you in advance.