-
Notifications
You must be signed in to change notification settings - Fork 255
Open
Labels
ADVANCED40 POINTS40 POINTSLevel 3SWOCbugSomething isn't workingSomething isn't workingenhancementNew feature or requestNew feature or request
Description
Describe the bug
Problem Description:
While testing the sign-in/sign-up functionality on the frontend, I discovered a critical issue:
- Backend APIs are not being called from the frontend.
- Instead, Firebase is being used for authentication.
- The Firebase logic is flawed and does not align with the backend API structure.
This discrepancy impacts the authentication flow and needs to be addressed by integrating the backend APIs.
Task Objectives:
We need to:
- Replace Firebase-based authentication in the frontend with calls to the backend APIs.
- Ensure seamless communication between the frontend and backend for authentication.
Required Backend API Integration:
Here are the APIs from the /backend
folder to integrate with the frontend forms:
- POST
/api/auth/signin
: For user login. - POST
/api/auth/signup
: For user registration. - GET
/api/auth/user
: To fetch user details after login. - POST
/api/auth/logout
: To log out the user.
Expected Frontend Behavior:
- Display the username after a successful login.
- Show popup alerts for the following scenarios:
- Successful Registration
- Successful Logout
- Incorrect Login Credentials
Steps to Resolve:
- Set up the full project locally, including the MongoDB database.
- Replace Firebase logic in the frontend with the above backend API calls.
- Test the API integration locally.
Testing Requirements:
- Since the backend is not yet deployed, attach screenshots/video of API responses in frontend when tested locally.
- Ensure proper error handling and user-friendly messaging in the frontend.
Notes for Contributors:
- Remove any redundant Firebase logic from the code.
- Reach out if you encounter issues during local setup or API testing.
Metadata
Metadata
Assignees
Labels
ADVANCED40 POINTS40 POINTSLevel 3SWOCbugSomething isn't workingSomething isn't workingenhancementNew feature or requestNew feature or request