-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Created a new example for OAuth2 with Token Refresh #74
base: main
Are you sure you want to change the base?
Conversation
This pull request has been linked to and will mark 1 task as "Done" when merged:
|
examples/source_examples/oauth2_with_token_refresh/connector.py
Outdated
Show resolved
Hide resolved
examples/source_examples/oauth2_with_token_refresh/connector.py
Outdated
Show resolved
Hide resolved
examples/source_examples/oauth2_with_token_refresh/connector.py
Outdated
Show resolved
Hide resolved
examples/source_examples/oauth2_with_token_refresh/connector.py
Outdated
Show resolved
Hide resolved
examples/source_examples/oauth2_with_token_refresh/connector.py
Outdated
Show resolved
Hide resolved
examples/source_examples/oauth2_with_token_refresh/Screenshot1.png
Outdated
Show resolved
Hide resolved
examples/source_examples/oauth2_with_token_refresh/connector.py
Outdated
Show resolved
Hide resolved
uri = AUTH_URL + urllib.parse.urlencode(param_dict) | ||
headers = {'content-type': 'application/x-www-form-urlencoded'} | ||
|
||
response = requests.request("POST", uri, headers=headers) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let use response = requests.post(AUTH_URL, headers=headers, data=param_dict)
or similar, to make code more readable
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
passing it in params is not working as it is not encoding the url as required. changing it to request.post
closes T-863159
Tested with fivetran debug and deploy
Added a readme file