Update Account User
API Explorer: /accounts/{accountId}/users/{userId}
To change a user's account role or disable or enable a user, an accountId
and userId
are required. The sample code changes the userId
of 123456
account role within accountId
of 123456
to user_manager
and disables the user in the account. Use the actual ID value for the account and user you are wanting to change.
accountId
of the account, use view the accountId
glossary section for the details on where to find this value.Update Account User
curl 'https://a.blazemeter.com/api/v4/accounts/123456/users/123456' \
-X PUT \
-H 'Content-Type: application/json' \
--user 'api_key_id:api_key_secret' \
-d '{"roles":["user_manager"],"enabled": false}'
Update Account User Request Attributes
Attributes
-
roles
arrayAn array of account roles that will be assigned to the user. Only ONE role should be assigned for any user, with the execption of the account
owner
role. The following are the available roles:admin
- Account admin rolebilling
- Account billing rolestandard
- Account standard roleuser_manager
- Account user manager role -
enabled
booleanDenotes if the user is enabled or disabled in the account
Update Account UserUpdate Account User PUT Body (JSON)
{
"roles": [
"user_manager"
],
"enabled": false
}
Update Account User Response Attributes
For a breakdown of the response attributes, see the Add User to Account Response Attributes section.
Response200 OK
{
"api_version": 4,
"error": null,
"result": {
"id": 123456,
"roles": [
"user_manager"
],
"enabled": false,
"lastAccess": 1573229467,
"type": "account",
"displayName": "My Name",
"login": 1573145246,
"email": "my.name@domain.com"
},
"request_id": "5dc5939bd8286"
}