Description

This function changes a PostgreSQL® database user's password.

Examples 




/json-api/set_postgresql_password?api.version=1&user=username&password=12345luggage&cpuser=example




/xml-api/set_postgresql_password?api.version=1&user=username&password=12345luggage&cpuser=example




whmapi1 set_postgresql_password user=username password=12345luggage cpuser=example



{
  "metadata": {
    "version": 1,
    "reason": "OK",
    "result": "1",
    "command": "set_postgresql_password"
  }
}




<result>
    <metadata>
        <version>1</version>
        <reason>OK</reason>
        <result>1</result>
        <command>set_postgresql_password</command>
    </metadata>
</result>



Parameters

Parameter
Type
Description
Possible values
Example
userstring

Required

The account's username.

A valid database username.

username
passwordstring

Required

The database user's new password.

A valid  password.12345luggage
cpuserstringThe database user's owner.A valid username.example

Returns

This function only returns metadata.