
I'm trying to use custom tokens for authenticating a user that uses AppleSignIn in an iOS app.
I don't like the OAuth2 implementation for Apple because it kicks the user out of my app, loads Safari to present the authentication screen, then prompts the user "Do you want to open "MyAppName"?" after authentication before finally returning them to my app - which is much, much less than ideal for the user experience.
So to avoid that, I'm handling the AppleSignIn within the app then sending the identityToken to an appwrite function that validates it, then creates an Appwrite user account and generates a custom token (with a 5 minute expiry) that gets returned to the app.
The app exchanges the custom token for a session with: Accounts.createSession(userId: secret:)
That all works - but the providerRefreshToken value is blank and I'm unsure of how to handle refreshing the session.
What is the recommended way to refresh an Appwrite session that was created using a custom token?
Recommended threads
- Functions fail to deploy after switching...
Hi <@1087889306208718959> , after switching my self-hosted Appwrite instance to use AWS S3 as the storage backend, my Cloud Functions stopped working. I’m runni...
- must be a valid domain or hostname
I have just migrated from 1.6.0 to 1.7.4. Upon migration I can log in but then get this screen. I also get this error in docker. Don't know if anyone has any id...
- Retrieving user access token on client s...
I am trying to retrieve the user token from the cookies, but they are HTTP-only and can not be accessed. Is there a way to extract the user token from the cooki...
