Access Token Refresh

Hi all. I have a question about using oData (specifically the Spotify API). I have an API that gets Spotify playlists for the logged in user. I created it last night and it worked. Today I am getting an error that the token has expired. I’ve refreshed, cleared my cache, etc. I read other posts on this forum that said the refreshing of the token was handled by bubble. I’m not sure what i’m doing wrong. My settings are below. If I test the api’s in the plugin the data returns just fine. Any help is appreciated.

Hello @glennfrank,

Please try to use the following option:

Thanks I checked that box and redeployed the api. Unfortunately i’m still not seeing the data. Getting the same error as before that the access token is expired.

Does anyone know if I need to trigger something in a workflow to get a new access token? I’m at a loss here. Thanks

May I know if you reauthenticated using the new configuration, please?

If you still have the same issue, you can try out the next topic:

Note: if you choose that way, please take care of the keys’ privacy.

1 Like

Yes I reauthenticated just fine. I tested all the calls in the API designer and everything works. When I try to view on the page I get the same errors. I’ll try the other process you listed.
thanks so much for the help!

1 Like

Did you reauthenticate on the page?

OK maybe this is the part i’m missing. I have a repeating group that pulls back data from the api. Do I need to do something to reauthenticate on the page itself?

Yeah. Please sign in again via the Spotify from the page using, for example, a button, not from the plugin editor. That will retrigger the workflow.

ok is it this workflow action?
Screen Shot 2020-09-22 at 9.53.11 PM

Yup. This action will authenticate via your Spotify account.

OK I added a button to the page and set the workflow to hit my api. When I click that button I get the same error. Damn

I might help faster if you invite me to your app. I need the read access only. Please use the following email:

This email is under the agency subscription, so you can invite me even if your app has a free plan.

Ok added. I can’t thank you enough for your help

1 Like

  1. Can you try to set the dynamic id here?
    Current User’s Spotify Advanced’s id

  2. Please make the repeating group visible only when Current User’s Spotify Advanced’s id is not empty.

  3. Add the logout button that will sign out your current user.

  4. Refresh the page

  5. Sign in via the Spotify again


holy crap. that worked!! What was the issue? Not logging out? Thank you so much!!

1 Like always to the rescue :raised_hands:


Did you check if the system refreshed your token?

1 Like

Hi sorry I missed this yesterday. So no, its not refreshing as it should. I have to go to the spotify website each time and remove access for it to work once it expires. Also, I added that logout button that worked, but unfortunately that logs out the user from my website each time. If I do all the steps manually I can get it to work but it takes a few tries. thanks