I have a raw OAuth 2.0 refresh token string (let's say from a previous session or obtained by other means) and would like to get a Azure Token object (including a new access token and refresh token) without requiring any user interaction.
As I only have the raw refresh token string and no AzureToken object, calling refresh() is not possible at that time.
And trying to create an AzureToken directly results in following error message:
Do not call this constructor directly; use get_azure_token() instead
However, the get_azure_token() function does not provide an option to pass a refresh token.
Could you provide a way to get an AzureToken object from an OAuth 2.0 refresh token string?
I have a raw OAuth 2.0 refresh token string (let's say from a previous session or obtained by other means) and would like to get a Azure Token object (including a new access token and refresh token) without requiring any user interaction.
As I only have the raw refresh token string and no AzureToken object, calling
refresh()is not possible at that time.And trying to create an AzureToken directly results in following error message:
Do not call this constructor directly; use get_azure_token() insteadHowever, the get_azure_token() function does not provide an option to pass a refresh token.
Could you provide a way to get an AzureToken object from an OAuth 2.0 refresh token string?