News & Announcements User Community Developer Community

Welcome to the RingCentral Community

Please note the community is currently under maintenance and is read-only.

Search
Make sure to review our Terms of Use and Community Guidelines.
  Please note the community is currently under maintenance and is read-only.
Home » Developers
How to properly refresh the "refresh token"
Tags: getting started
Apr 13, 2021 at 7:46am   •   1 replies  •  0 likes
Cancan Gunadi

Hi @Phong Vu,


We are getting "Refresh Token Expired" errors even when we tried refreshing the "refresh token" before the 7 days expiration of the refresh token.

It seems like when we refresh the refresh token, we get a new refresh token that is different than before but the new "refresh_token_expire_time" is still the same as the old one.

Is this a known problem and how do we fix it?

We use the Python SDK, and here's what our code pretty much looks like:

res = platform.refresh()
save_new_refresh_token(res.json().refresh_token)

Thank you so much for your help.

1 Answer
answered on Apr 13, 2021 at 10:12am  

Every time you refresh a token, you will get a new refresh token with new expire time. If you manage the access token yourself, you have to save/store the new refresh token and use it next time you refresh it.

The refresh_token_expire_time is the same because it is the amount of time in secs (604800 secs = 7 days) when the token is valid since the time it was issued.


 0



A new Community is coming to RingCentral!

Posts are currently read-only as we transition into our new platform.

We thank you for your patience
during this downtime.

Try Workflow Builder

Did you know you can easily automate tasks like responding to SMS, team messages, and more? Plus it's included with RingCentral Video and RingEX plans!

Try RingCentral Workflow Builder

PRODUCTS
RingEX
Message
Video
Phone
OPEN ECOSYSTEM
Developer Platform
APIs
Integrated Apps
App Gallery
Developer support
Games and rewards

RESOURCES
Resource center
Blog
Product Releases
Accessibility
QUICK LINKS
App Download
RingCentral App login
Admin Portal Login
Contact Sales
© 1999-2024 RingCentral, Inc. All rights reserved. Legal Privacy Notice Site Map Contact Us