Has anyone else found that issuing a PATCH call to endpoint /learn/api/public/v1/users/userName:xxxx causes the institution_roles_pk1 column value in the users table to switch with a secondary role found in the user_roles table?
Here are the results of my test:
The Users table for the updated user account before the call:
The User Roles table for the updated user account before the call:
PATCH /learn/api/public/v1/users/userName:amariga HTTP/1.1
Authorization: Bearer [token value]
"given" : "Atlas",
"family" : "Mariga"
Users table after the PATCH call to users:
User Roles table after the PATCH call to users:
Note that the REST API request only sends a name change in the body. I don't see any way to adjust institution roles using the API, so I'm confused why the call seems to have taken the user's primary institution role (220) and switched it with the first secondary institution role (found in the user roles table).
Does anyone have any ideas or suggestions for how to avoid this unwanted update to institution roles? Thanks.