Back

User login method

  • 0
  • Databases
  • Web
Los Feliz
8 Sep, 2024, 07:35

I developed a Vite ReactJS web application where users log in using Google OAuth 2.0. Upon logging in, I retrieve the user's email and store it in the users collection in Appwrite. After logging in, users are prompted to set a username, which is also stored in the same collection alongside their email. So, each user in the collection has the following attributes: Document ID, email, given_name, username, and avatar.

The email is obtained through Google login, while the username is set after the user completes a CAPTCHA. I do not store the email unless the user has set a username and passed the CAPTCHA.

Appwrite provides an Auth feature with Users and Teams. So I am confused if I am on the correct path with the user sign up process.

Currently, my application works as intended. I just want to know if my approach is unproblematic. Can you please clarify?

TL;DR
Developers created a Vite ReactJS web app where users log in via Google OAuth 2.0, storing email in the `users` collection and prompting users to set a username after login. The username is stored alongside email after completing a CAPTCHA. Appwrite's Users and Teams Auth feature is used, and the signup process works fine. The approach appears to be solid.
Reply

Reply to this thread by joining our Discord

Reply on Discord

Need support?

Join our Discord

Get community support by joining our Discord server.

Join Discord

Get premium support

Join Appwrite Pro and get email support from our team.

Learn more