passwords.strengthCheck wraps the Strength Check Password API endpoint.
This endpoint allows you to check whether or not the provided password is valid based on the configuration set in your Stytch Dashboard, and to provide feedback to the on how to increase the strength of their password.
Parameters
The password to authenticate, reset, or set for the first time. Any UTF8 character is allowed, e.g. spaces, emojis, non-English characters, etc.
The email associated with the password. Provide this for a more accurate strength check.
Response fields
Returns true if the password passes our password validation. We offer two validation options, zxcvbn is the default option which offers a high level of sophistication. We also offer LUDS which is less sophisticated but easier to understand. If an email address is included in the call we also require that the password hasn’t been compromised using built-in breach detection powered by HaveIBeenPwned.
The score of the password determined by zxcvbn. Values will be between 1 and 4, a 3 or greater is required to pass validation.
The strength policy type enforced, either
zxcvbn or luds.Will return true if breach detection will be evaluated. By default this option is enabled. This option can be disabled in the dashboard. If this value is false then
breached_password will always be false as well.Returns true if the password has been breached. Powered by HaveIBeenPwned.
The feedback object contains relevant information to relay to users that failed to create a strong enough password.
The feedback object contains relevant information to relay to users that failed to create a strong enough password.