-
Start the development server:
npm run dev
-
Test Google Sign-In:
- Go to
http://localhost:3001/signuporhttp://localhost:3001/login - Click "Continue with Google"
- Sign in with your Google account
- Go to
-
Capture Google Token for Backend Testing:
- Open
capture-google-token.htmlin your browser - Sign in with Google
- Copy the token for your backend developer
- Open
- ✅ Frontend: Google OAuth integration complete
- ✅ Mock Backend: Working with MSW
- ✅ Token Logging: Console shows Google tokens for testing
- ⏳ Real Backend: Waiting for implementation
Google Credentials:
- Client ID:
1014126568369-l9moqqlcka953cjui6fqt7alf0o0qkli.apps.googleusercontent.com - Client Secret:
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
Required Endpoints:
POST /api/auth/google- Google Sign-InPOST /api/auth/google/signup- Google Sign-Up
Request Format:
{
"id_token": "google_id_token_from_frontend"
}Response Format:
{
"user": {
"id": "user_id",
"email": "[email protected]",
"name": "User Name",
"avatar": "profile_picture_url",
"isGoogleUser": true,
"createdAt": "2024-01-15T10:30:00Z",
"lastLoginAt": "2024-01-15T10:30:00Z"
},
"accessToken": "jwt_token",
"refreshToken": "jwt_refresh_token"
}- Backend developer implements the endpoints
- Test with captured Google tokens
- Update frontend to use real backend API
- Deploy to production
The frontend is ready and waiting! 🚀