@W-20890250 Handle request limit and monthly quota error states for passwordless and reset password#3574
Merged
hajinsuha1 merged 8 commits intofeature/email-otpfrom Jan 16, 2026
Conversation
…, update Commerce API parameters to test with staging-001" This reverts commit 66bcafa.
…rror message for "too many requests" errors
…swordlessLogin and getPasswordResetToken errors
Collaborator
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
…ail mode, update Commerce API parameters to test with staging-001"" This reverts commit bf61c9b.
…or messages and add corresponding unit test
hajinsuha1
commented
Jan 14, 2026
Comment on lines
+1355
to
+1359
| const res = await slasClient.getPasswordResetToken(options, true) | ||
| if (res && res.status !== 200) { | ||
| const errorData = await res.json() | ||
| throw new Error(`${res.status} ${String(errorData.message)}`) | ||
| } |
Collaborator
Author
There was a problem hiding this comment.
calling getPasswordResetToken(options, true) returns the rawResponse which was need to pass the error message to retail-react-app for determining which error message to display
hajinsuha1
commented
Jan 14, 2026
Comment on lines
+49
to
+56
| {form.formState.errors?.global && ( | ||
| <Alert status="error"> | ||
| <AlertIcon color="red.500" boxSize={4} /> | ||
| <Text fontSize="sm" ml={3}> | ||
| {form.formState.errors.global.message} | ||
| </Text> | ||
| </Alert> | ||
| )} |
Collaborator
Author
hajinsuha1
commented
Jan 14, 2026
| SOCIAL: 'social' | ||
| } | ||
|
|
||
| export const PASSWORDLESS_ERROR_MESSAGES = [ |
Collaborator
Author
There was a problem hiding this comment.
this has been moved to auth-utils.js above and renamed to PASSWORDLESS_FEATURE_UNAVAILABLE_ERRORS as it is only used there
yunakim714
approved these changes
Jan 15, 2026
12 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Description
Adds a new "Too many requests" error message when
/passwordless/loginor/password/resetreturn a 400 response:/passwordless/loginreturns too many requests error:/password/resetreturns too many requests error:Also updated Email Confirmation page to display errors if form has any set. This ensures if the "Too many requests" error is returned, when a user spams the "Resend Link" button, the error is displayed.
Full list of API error to UI error message mapping can be found here
Types of Changes
Changes
"no callback_uri is registered for client"->"This feature is not currently available""Too many login requests were made. Please try again later."->Too many requests. For your security, please wait 10 ** minutes before trying again."Monthly quota for passwordless login mode email has been exceeded"->"This feature is not currently available"How to Test-Drive This PR
Too many requests error
Continuebutton. Then clickResend Linkbutton 6 times in 10 minutes.Too many requests. For your security, please wait 10 minutes before trying again.error is displayedContinuebutton.Too many requests. For your security, please wait 10 minutes before trying again.error is displayedPasswordbutton, clickForgot Passwordlink. ClickReset Passwordand repeat this 3 more times to trigger the too many requests errorToo many requests. For your security, please wait 10 minutes before trying again.error is displayedno callback_uri is registered for clienterrorContinuebutton.This feature is not currently available.error is displayedPasswordbutton, clickForgot Passwordlink. ClickReset Password.This feature is not currently available.error is displayedChecklists
General
Accessibility Compliance
You must check off all items in one of the follow two lists:
or...
Localization