Skip to content
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

Proposal: remove logic for getting OAuth token #15

Closed
aeden opened this issue Feb 29, 2016 · 1 comment · Fixed by #69
Closed

Proposal: remove logic for getting OAuth token #15

aeden opened this issue Feb 29, 2016 · 1 comment · Fixed by #69
Assignees
Labels
enhancement New feature, enhancement or code changes, not related to defects

Comments

@aeden
Copy link
Member

aeden commented Feb 29, 2016

Should we remove the OAuth token acquisition logic from the core library and delegate OAuth token retrieval to a third-party library like https://godoc.org/golang.org/x/oauth2 as it handles things like refresh tokens, password credentials token, etc.?

@weppos
Copy link
Member

weppos commented Feb 29, 2016

FYI we will not likely support refresh tokens, nor the password credentials token. We only support the Code grant flow.

Therefore, the OAuth2 lib may be overkill. I see a value to provide a simple implementation that covers what we offer in our API, since we will likely also have something similar in other clients.

I'll take a look at the OAuth2.

@weppos weppos self-assigned this Apr 3, 2018
@weppos weppos added the enhancement New feature, enhancement or code changes, not related to defects label Apr 3, 2018
weppos added a commit that referenced this issue Apr 3, 2018
This implementation follows the most common best practices around using a RoundTripper for authentication, rather than passing a credential and modifying the Do to apply the credential headers.

Definining a RoundTripper is a more flexible, powerful, and elengant approach.

This change requires to bump to 1.7 (given we add the dependency to golang/x/oauth2 that uses the context package).

Closes GH-15
weppos added a commit that referenced this issue Sep 12, 2018
…e a new Client) (#69)

This implementation follows the most common best practices around using a RoundTripper for authentication, rather than passing a credential and modifying the Do to apply the credential headers.

Defining a RoundTripper is a more flexible, powerful, and elegant approach.

This change requires to bump to 1.7 (given we add the dependency to golang/x/oauth2 that uses the context package).

Closes GH-15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature, enhancement or code changes, not related to defects
Projects
None yet
2 participants