citeright-sdk-js
Version:
An SDK to connect to the CiteRight API.
30 lines (29 loc) • 1.04 kB
TypeScript
import { PasswordValidationModel } from "./PasswordValidationModel";
/**
* @swagger
* definitions:
* PasswordChangeDTO:
* type: object
* properties:
* oldPassword:
* type: string
* newPassword:
* type: string
* confirmPassword:
* type: string
*/
export declare class PasswordChangeDTO {
oldPassword: string;
newPassword: string;
confirmPassword: string;
constructor(oldPassword?: string, newPassword?: string, confirmPassword?: string);
/**
* This function will compare two passwords to make sure they match and also validate against a list of rules
* that we insist on for password strength. Upon completion, we return a PasswordValidationModel that contains any
* errors as well as a convenient boolean to indicate validity. If an "oldPassword" is supplied, we will check to
* see if matches the new password.
*
* @returns {PasswordValidationModel}
*/
validate(): PasswordValidationModel;
}