Hi Appwrite team,
I’m using Appwrite Auth in a Flutter mobile app and trying to upgrade an anonymous user to Google OAuth.
Docs say that if there is already an active session, a new OAuth2 session should be attached to the currently logged-in account. But in Flutter, createOAuth2Session() creates/logs in a different Google Auth user instead of attaching Google to the existing anonymous user.
Environment:
Flutter app Appwrite Flutter SDK 18.0.0 Platform: Android Provider: Google OAuth2 Flow:
Create anonymous session Complete onboarding From profile, call Google OAuth while anonymous session is still active Code:
`final before = await account.get(); final beforeSession = await account.getSession(sessionId: 'current');
await account.createOAuth2Session( provider: OAuthProvider.google, scopes: ['email', 'profile'], );
final after = await account.get(); final afterSession = await account.getSession(sessionId: 'current');` Logs:
`before userId=6a1735f10af0d84b8fe2 before provider=anonymous
after userId=6a1736370ef80119884d after provider=google
attachedToPreviousSession=false` Expected: after.$id should equal the anonymous user id.
Actual: Appwrite creates/logs in a different Google Auth user, so I end up with 2 Auth users: anonymous + Google.
Question: Is anonymous -> OAuth upgrade supported in Flutter/native via createOAuth2Session()
Recommended threads
- TEAM INVITE
There is a problem with the team invitation. When a user invites other users, that time, the newly created email address they don't get the invite link and old ...
- education plan not activated
Hi I have an edu id 13103046@iubat.edu but when I am trying to claim my plan and trying to logging with github where education student plan active. the appwrite...
- 500 simultaneous OAuth logins from the s...
Hi, I'd like to ask about rate limiting around Google OAuth login on Appwrite Cloud. **OVERVIEW** Service type: A PWA (web app) for members of a university clu...