Current API
Login
LoginController → SessionService::createSession()
Register
RegisterController → RegistrationService::register()
Side effects:
- Creates user, personal details, address, mobile number
- For tutors: DBS association, Stripe card, subscription
- Fires
Registeredevent → email verification + internal notifications - Auto-creates session (returns token)
Logout
auth:api
Handler: LoginController → SessionService::destroySession()
Forgot password
ForgotPasswordController — sends ResetPassword notification (6-minute token expiry).
Delete account
auth:api
Handler: Soft-deletes user. Sends UserDeleted email to hello@tutorbloc.com.
Legacy v1 API
Login
Register
Logout
Forgot password
Email verification
auth:api
Resends email verification notification. Throttled.