update_password

To update a user’s password, use the following method:

Copied!
svc=user/update_password&params={"userId":<long>,
				 "oldPassword":<text>,
				 "newPassword":<text>}

Parameters

The required parameters are marked with an asterisk (*).

Name Description
userId* User ID.
oldPassword* Old password.
newPassword* New password.

Response

Copied!
{}	/* an empty object if the execution is successful; if not, an error code */

Error codes

Error code Description
4 Incorrect parameters provided, or the new password doesn’t match security requirements.
7 One of the following errors:
  • The user wasn’t found, or you have no Act on behalf of this user access right to the user.
  • You change the password of another user and have no Change user’s general properties access right to this user.
  • You change your own password, and it is immutable.
6 The password doesn’t match security requirements, or failed to update the password, or the current user wasn’t found.
1006 The maximum number of failed password update attempts has been exceeded.

If you find a mistake in the text, please select it and press Ctrl+Enter.