Skip to content

Conversation

@minh-biocommons
Copy link
Collaborator

@minh-biocommons minh-biocommons commented Nov 24, 2025

Description

AAI-518: Handle existing usernames and emails during registration

Changes

  • Updated BioCommons & SBP registration endpoints to return more specific email/username exist error message along with field errors instead of just a generic "both exists"
  • Added utils endpoints for checking existing username & email to be used during registration form step validation
  • Added/updated relevant tests

Checklist

  • I have commented my code, particularly in hard-to-understand areas
  • I have added unit / integration tests that prove my fix is effective or that my feature works
  • I have run all tests locally and they pass
  • I have updated the documentation (if applicable)
  • For any new secrets, I have updated the shared spreadsheet and the GitHub Secrets.

Copy link
Collaborator

@marius-mather marius-mather left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good but I think we need to do more detailed checking for existing usernames - the Auth0 API lets you search by username but may not return exact matches

Copy link
Collaborator

@marius-mather marius-mather left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good now, thanks!

@minh-biocommons minh-biocommons merged commit 0945278 into main Nov 24, 2025
4 checks passed
@amandazhuyilan amandazhuyilan deleted the email-username-check branch November 24, 2025 22:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants