-
Notifications
You must be signed in to change notification settings - Fork 51
feat: Oauth design (#269) #272
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
Conversation
* feat: oauth feature * feat: auth feature * refactor the interface * feat: Oauth implementation * feat: remove no auth client * feat: Add test cases * chore: address review comments * chore: address review comments * feat: Add docs * feat: Add docs * chore: address review comments * feat: addressed review comments * feat: addressed review comments * feat: addressed review comments * feat: addressed review comments * feat: added public oauth examples --------- Co-authored-by: kburke <[email protected]>
dae1096
to
f060659
Compare
oauth.go
Outdated
return true, err | ||
} | ||
|
||
expirationTime := time.Unix(int64(exp), 0).UTC() |
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.
I think we need to be careful here and probably need some tests.
I believe what this will do if you have a non-Unix time, is create a local timestamp, and then convert it to UTC.
What we want to do is parse the timestamp in the UTC time zone.
We should add some time zone related test cases.
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.
I'm not sure the above comment is correct on a closer reading but I'd prefer if we had test cases
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.
sure, I will add them.
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.
LGTM
Feature
This PR adds Oauth to twilio-go.
Changes added:
a. The IamService Object used --> This will act as an interface for any IAM service we plan to access
b. The Credentials details
Checklist
If you have questions, please file a support ticket, or create a GitHub Issue in this repository.