You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
When using just Google as a provider, I am not getting a refresh_token back. This means when I come to use the Google Sheets API, I give it the access_token, but that then expires after 1 hour.
I have read around all the issues and noticed that for Google a refresh token is only available on first login (#269), but I have tried the following but it is still returning null:
Expected behavior
When authenticating with Google, I get a refresh_token value back.
Screenshots or error logs
Screenshot of Mongo showing no refreshToken value:
Additional context
I want to be able to use the refresh_token to rotate my access_token so that I can continually access the Google Sheets API. Here's how I'm using that incase that's helpful:
After quite a lot of messing around, I ended up using the authorizationUrl with the params directly appended to the URL (not using the params option), and also using a different accessTokenUrl from the Google docs.
Describe the bug
When using just Google as a provider, I am not getting a
refresh_token
back. This means when I come to use the Google Sheets API, I give it theaccess_token
, but that then expires after 1 hour.I have read around all the issues and noticed that for Google a refresh token is only available on first login (#269), but I have tried the following but it is still returning
null
:access_type: 'offline'
to theparams
objectprompt: 'consent'
to theparams
objectApologies if I have missed something, this was my last resort opening an issue, I promise.
Any help truly appreciated. Thank you.
Versions tried:
2.2.0
3.0.0-beta.15
To Reproduce
Here is my
_app.tsx
:Expected behavior
When authenticating with Google, I get a
refresh_token
value back.Screenshots or error logs
Screenshot of Mongo showing no
refreshToken
value:Additional context
I want to be able to use the
refresh_token
to rotate myaccess_token
so that I can continually access the Google Sheets API. Here's how I'm using that incase that's helpful:The text was updated successfully, but these errors were encountered: