def set_password_using_hash_salt(self, user_id, password, password_confirmation, password_algorithm, password_salt=None):
self.clean_error()<EOL>try:<EOL><INDENT>url = self.get_url(Constants.SET_PW_SALT, user_id)<EOL>data = {<EOL>'<STR_LIT:password>': password,<EOL>'<STR_LIT>': password_confirmation,<EOL>'<STR_LIT>': password_algorithm<EOL>}<EOL>if password_salt:<EOL><INDENT>data["<STR_LIT>"] = password_salt<EOL><DEDENT>response = self.execute_call('<STR_LIT>', url, json=data)<EOL>if response.status_code == <NUM_LIT:200>:<EOL><INDENT>return self.handle_operation_response(response)<EOL><DEDENT>else:<EOL><INDENT>self.error = str(response.status_code)<EOL>self.error_description = self.extract_error_message_from_response(response)<EOL>self.error_attribute = self.extract_error_attribute_from_response(response)<EOL><DEDENT><DEDENT>except Exception as e:<EOL><INDENT>self.error = <NUM_LIT><EOL>self.error_description = e.args[<NUM_LIT:0>]<EOL><DEDENT>return False<EOL>
Set Password by ID Using Salt and SHA-256

:param user_id: Id of the user
:type user_id: int

:param password: Set to the password value using a SHA-256-encoded value.
:type password: string

:param password_confirmation: Ensure that this value matches the password value exactly.
:type password_confirmation: string

:param password_algorithm: Set to salt+sha256.
:type password_algorithm: string

:param password_salt: (Optional) To provide your own salt value.
:type password_salt: string

Returns if the action succeed
:return: true if success
:rtype: bool

See https://developers.onelogin.com/api-docs/1/users/set-password-using-sha-256 Set Password by ID Using Salt and SHA-256 documentation