3

我正在使用 cognito 用户池进行用户管理,并使用 forgotPassword 流程向用户发送确认码。出于 UI 目的,我需要验证在调用 API ForgotPassword 时发送的代码,但尚未发送新密码。我需要像 ForgotPassword 和 ConfirmForgotPassword 之间的中间步骤。

下面的函数是发送代码的函数:

Auth.forgotPassword(username)

此功能正在使用发送的代码重置密码(如果代码无效,我会在此处收到通知)

Auth.forgotPasswordSubmit(username, code, new_password)

是否可以仅验证使用现有 API 发送的代码?

这里有一个信息链接: https ://docs.amplify.aws/lib/auth/manageusers/q/platform/js#forgot-password

4

0 回答 0