OpenapiUsers
Update user roles
Updates the roles assigned to a user. Replaces all existing roles with the new list. **Security constraints**: - Realm-admin can only assign "user" role, not "realm-admin"
PUT
Updates the roles assigned to a user. Replaces all existing roles with the new list.
Security constraints:
- Realm-admin can only assign "user" role, not "realm-admin"
userId*stringUser ID
Format
uuidapplication/json- body
roleIds*array<>Roles updated
curl -X PUT 'https://example.com/api/users/497f6eca-6276-4993-bfeb-53cbbbba6f08/roles' \
-H 'Content-Type: application/json' \
-d '{
"roleIds": [
"10960216-a894-4481-b8f2-270c1c8fab34"
]
}'Example Response
Empty