Skip to main content

Sign-up Feature Reference

Frontend composition

  • frontend/src/pages/Signup/index.js:16 wraps the form, animates submit states and exposes Google OAuth via onSubmitGoogle.
  • frontend/src/components/SignupForm/index.js:134 sends the primary POST /auth/signup request and persists temporary credentials in session storage for downstream OTP flows.
  • Unique ID and email availability are validated client-side using /s/cuid/{id} (frontend/src/components/SignupForm/index.js:209) and /s/uemail/{email} (frontend/src/components/SignupForm/index.js:190).

Validation rules

  • Formik + Yup enforce email format, Club ID character set and password complexity; helper text mirrors backend validators so errors stay consistent.
  • The submit button is disabled until both availability checks return success and the user accepts the Terms component.

Backend endpoints

  • backend/r/auth_all.js:134 registers POST /auth/signupsocial for OAuth completions; controller_su.signup handles regular user creation.
  • backend/r/search.js:115 exposes GET /s/cuid/:cuid and backend/r/search.js:103 exposes the email lookup to support availability checks.
  • Verification emails are processed by POST /auth/verify-email/ (see backend/r/auth_all.js:216), moving records from users_unverified into the primary tables.

Follow-up flows

  • After signup the UI waits six seconds before redirecting, allowing the success animation to play and providing time for the verification hint.
  • Social sign-ups redirect to /register/social when req.user.newUser === '0', letting the user confirm profile details before activation.
  • Any signup error payload returned by the controller surfaces in the snackbar via helpers.setStatus so users know which field needs attention.