GIthub oauth: provider_token expires after 60 minutes and is not refreshed #33828
-
|
Hi Supabase community, I'm using supabase authentication with the github provider in a React / Vite app. An hour after signing in, the provider_token expires and attempts to use the github api fail with a 401 incorrect credentials error. The supabase session is still I was under the impression that the supabase client would automatically refresh the token. Does this need to be done manually? If so, the provider_refresh_token does not seem to be in the github oauth session (there is a refresh_token but it does not seem to work when I try manually refreshing the provider_token with it). My supabase client setup is: And my github signin looks like: Thanks for any help! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
|
No. Supabase does nothing with the provider token and refresh token if there is one. It is not stored and is up to you to store somewhere and refresh use as desired. Not sure what gave you the impression they were handled. You should feed back to Supabase if some documentation led you to that. |
Beta Was this translation helpful? Give feedback.
-
|
My bad! Thanks @GaryAustin1 for pointing that out. |
Beta Was this translation helpful? Give feedback.

No. Supabase does nothing with the provider token and refresh token if there is one. It is not stored and is up to you to store somewhere and refresh use as desired.
https://supabase.com/docs/guides/auth/social-login#provider-tokens
Not sure what gave you the impression they were handled. You should feed back to Supabase if some documentation led you to that.