You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We noticed that recently we couldn't get a refresh token for our web application using this gem. We have been using this gem continuously for 3 years without issue with getting refresh token.
We have added the param in our code such as ;
api.authorize({ oauth2_callback: oauth2_callback_platform_partners_url,
oauth2_access_type: "offline", # ask to return refresh token
approval_prompt: "force" }) # force to request user consent
It works in 'localhost', but not in other domain than "localhost" such as our production app. We only being returned the access token without refresh token. And no user consent window had pop up on our production app.
Any changes in they way the gem handles OAuth2?
The text was updated successfully, but these errors were encountered:
After reading the source code, we found that the parameter has been changed from "approval_prompt" to "oauth2_approval_prompt" somewhere in between version. After making that changes, it started working again.
I think it would be good if any change like this is documented as lib migration note.
We never supported :approval_prompt. To set this option from our library, the argument was always :oauth2_approval_prompt. So this means that your setting was getting lost.
However, signet's default setting for :approval_prompt used to be "force", but changed in a recent update to signet that we incorporated into our library. So the default setting happened to be the same as what you wanted, but it's not anymore.
I will look into making 'force' the default action by the client library in a future version; however, this isn't actually a bug and now you're setting the correct attribute, so I'm going to close this issue.
Hi There,
We noticed that recently we couldn't get a refresh token for our web application using this gem. We have been using this gem continuously for 3 years without issue with getting refresh token.
We have added the param in our code such as ;
api.authorize({ oauth2_callback: oauth2_callback_platform_partners_url,
oauth2_access_type: "offline", # ask to return refresh token
approval_prompt: "force" }) # force to request user consent
It works in 'localhost', but not in other domain than "localhost" such as our production app. We only being returned the access token without refresh token. And no user consent window had pop up on our production app.
Any changes in they way the gem handles OAuth2?
The text was updated successfully, but these errors were encountered: