requests-oauthlib icon indicating copy to clipboard operation
requests-oauthlib copied to clipboard

Do not pass 'params' IE querystring parameters from original request when refreshing token.

Open dadocsis opened this issue 4 years ago • 0 comments

Consider the following snippet using the automatic token refresh strategy:
https://requests-oauthlib.readthedocs.io/en/latest/oauth2_workflow.html#third-recommended-define-automatic-token-refresh-and-update

from requests_oauthlib import OAuth2Session
    client = OAuth2Session(client_id, token=token, auto_refresh_url=refresh_url,
                           auto_refresh_kwargs=extra, token_updater=token_saver)
    r = client.get(protected_url, params=qs)

The params=qs ends up getting sent in the body of the refresh_token POST.

dadocsis avatar Dec 18 '19 13:12 dadocsis