user.update
The user.update command is used to update an existing user.
Requires Super-Ops to change a user other than self.
The user record fields updatedOn and updatedBy change automatically in the system.
TR50 Request
{
"cmd": {
"command": "user.update",
"params": {
"id": "52a1d3db169e1fd03217940d",
"emailAddress": "user@example.com",
"password": "abc123",
"defaultOrgId": "52a1d3db169e1fd032179408",
"firstName": "Jane",
"lastName": "Smith",
"company": "Acme",
"title": "CEO",
"officePhone": "5558675309",
"mobilePhone": "5558675309",
"isSuperAdmin": false,
"isSuperOps": false
}
}
}
To change your password:
{
"cmd": {
"command": "user.update",
"params": {
"currentPassword": "abc123" ,
"password": "xyz123",
}
}
}
SuperOps+ - To change the user's password with their id:
{
"cmd": {
"command": "user.update",
"params": {
"id": "52a1d3db169e1fd03217940d",
"password":"xyz123"
}
}
}
SuperOps+ - To change the user's password with their email address:
{
"cmd": {
"command": "user.update",
"params": {
"emailAddress":"user@example.com",
"password":"xyz123"
}
}
}
Request Parameters
Name |
Type |
Required |
Description |
---|---|---|---|
id |
String |
|
The user's id. Defaults to the current session user's id. |
emailAddress |
String |
|
The email address of the user. |
password |
String |
|
The password of the user. |
defaultOrgId |
String |
|
The object id of the default org the user is associated with. |
firstName |
String |
|
The first name of the user. |
lastName |
String |
|
The last name of the user. |
company |
String |
|
The name of the company the user belongs to. |
title |
String |
|
The title the user holds within the company. |
officePhone |
String |
|
The office phone number of the user. |
mobilePhone |
String |
|
The mobile phone number of the user. |
isSuperAdmin |
Boolean |
|
If the user has super admin permission. |
isSuperOps |
Boolean |
|
If the the user has super ops permission. |
support |
Boolean |
|
Whether the user has access to the support system. |
data |
Object |
|
Opaque data store object with valid keys. If provided, overwrites the existing data object. |
TR50 Response
If the command is sent successfully a success message is returned. Otherwise, an error and error message will be returned.
{
"cmd": {
"success": true
}
}