requests / requests-oauthlib

OAuthlib support for Python-Requests!
https://requests-oauthlib.readthedocs.org/
ISC License
1.71k stars 422 forks source link

BROKEN DOCUMENTATION: Backend Flow #551

Open bostonareahuman opened 1 month ago

bostonareahuman commented 1 month ago

URL"

https://requests-oauthlib.readthedocs.io/en/latest/oauth2_workflow.html#backend-application-flow


theauth = HTTPBasicAuth(creds.ClientID,creds.ClientSecret)
client = BackendApplicationClient(creds.ClientID)
bcauth = OAuth2Session(client)
token = bcauth.fetch_token(token_url=tokenendpoint,auth=theauth)

RESPONSE:

"Please supply either code or " "authorization_response parameters." ValueError: Please supply either code or authorization_response parameters.

NO idea what these mean or why they need to be set for just a Backend Client oAuth.

Putting in :

token = bcauth.fetch_token(token_url=tokenendpoint, client_id=creds.ClientID,client_secret=creds.ClientSecret)

Doesn't work either...

What is going with the documentation?