Two-Pronged Question: OAuth2 User-Agent Flow and Refresh Token

  1. Why is the token not automatically refreshing?
    Am I missing any configuration or setup in Bubble that would allow the OAuth2 User-Agent Flow to automatically handle token refresh? (i keep having to go through the sign-in/authentication after a while)


2. Where can I find/reference the refresh token, access token, expiration date?
During the initial authentication process, where can I capture the refresh token and those other details to store them in the database for manual refresh handling?

If you want to handle the access/refresh token yourself, don’t use the OAuth2 User-Agent Flow method that Bubble natively provides.

Instead, set up your own authorization url and API calls. Once authorized, the user will be redirected back to your app with a code. Use that code to retrieve an access and refresh token.

2 Likes