-
Notifications
You must be signed in to change notification settings - Fork 13
Description
I'm building an application to hook into users' CRM and send automated text messages throughout their sales campaigns. I'm a bit confused regarding the best way to generate a new token using the refresh token flow - I'm able to obtain a token using the Authorization Flow and cache the token for future use. I'm able to use the cached token with a new Rest Client (client.set_token(token)
) and the refresh performs automatically if the token's 'expires_at' time has passed, however I can't get access to the refresh token object after the refresh has been performed. Will I be able to reuse the original token object indefinitely so long as it's refreshed within a week of when the previous refresh was performed? I was under the impression that the refresh token would cease to work one week (or however long the 'refresh_token_expires_in' is set to) after the original token was issued.
Essentially, I'm wondering whether users will need to log in at least once a week and obtain a new OAuth token, or if we're able to retrieve a new token via a background process/worker via Refresh Token Flow.
I posted this question on the developer forum as well - https://devcommunity.ringcentral.com/ringcentraldev/topics/text-automation#reply-comment-list-18391351
Thanks in advance for your help! Hope you're having a nice day.