Hey! currently making a supabase client for creati...
# help
j
Hey! currently making a supabase client for creating jetpack compose android apps. It works perfectly fine with the authentication but my question: Once the user signs in, should I save the credentials on the phone's storage or the refresh token or whats the best way of doing that?
n
Hello @Jan Tennert! This thread has been automatically created from your message in #843999948717555735 a few seconds ago. We have already mentioned the @User so that they can see your message and help you as soon as possible! Want to unsubscribe from this thread? Right-click the thread in Discord (or use the ``...`` menu) and select "Leave Thread" to unsubscribe from future updates. Want to change the title? Use the ``/title`` command! We have solved your problem? Click the button below to archive it.
j
probably the refresh token because it can be revoked right?
g
This is what supabase.js stores in local storage.
n
TheRealJan (2022-05-21)
j
okay thanks also trying to implement other providers like google using a http server when trying to log in with google. When the oauth2 is "done" and the user authenticated the user is redirected to my http server. How to I get the access token etc?
its a custom http server written in kotlin so I'm not using supabase.js
and its also only hosted locally because its for a desktop app
g
I was just showing the type of info stored besides refresh token
j
yes just asked how I get the session when using a third party provider and getting redirected to a http server. I'm getting redirected to http://localhost:3000/callback#access_token=something&refresh_token=something&token_type=bearer But I can't access the access token etc. The http server should get destroyed after authenticating so its not a webapp
is that even possible for non-web apps?
g
I believe so, but I don't do even do SSR myself. You might glance thru this repository https://github.com/supabase-community/supabase-auth-helpers/blob/main/src/nextjs/README.md for some ideas or search in supabase github discussions. You might need to ask your question again specifically relating to getting the info versus just what to store, although weekends tend to be slow around here.
j
okay let me do that