Cloud Linux, CPanel / WHM

whmapi to change cpanel user account password using SSH.

If you want to reset CPanel user account password using SSH then run below command.

whmapi1 passwd user=username password=passwordtoreset

Above command will change the password of the user. Kindly replace the username with actual username and password with the actual password with which you want to reset it.

It wil show output like below

[[email protected] ~]# whmapi1 passwd user=abcdedfg password=12sdfsdfsdf
    - system
    - ftp
    - mail
    - MySQL
    - postgresql
  command: passwd
    raw: "Password for “abcdedfg” has been changed.FTP (File Transfer Protocol) password change has been queued.\n"
  reason: Password changed for user “abcdedfg”.
  result: 1
  version: 1
[[email protected] ~]#