To update a password of a user, use the command user/update_password:
svc=user/update_password¶ms={"userId":<long>, "reset":<bool>, "oldPassword":<text>, "newPassword":<text>}
Name | Description |
---|---|
userId | user ID |
reset | reset password: true - new password will be generated false - new password will be set if old one was correctly entered |
oldPassword | old password |
newPassword | new password |
If success execution:
<text> /* new password */
If fails:
{ "error":<int> /* error code */ }
Code | Value |
---|---|
1 | invalid session |
2 | invalid service name |
3 | invalid result |
4 | invalid format or value of parameters |
|