-
Notifications
You must be signed in to change notification settings - Fork 1
Add Oauth2 Support And Add Path Support in sdk #12
Conversation
… in SDK, but we prefer to use path
Hi, about oauth2, we can let the user decide how to generate the token and simply pass it as the comment says and the PR does. So ( BTW, A suggestions: Use descriptive PR title (what problem you solves). In the PR description, you can say |
utils_token.go
Outdated
const ( | ||
secret = "-uGEL0oQZ86Wwr2I-dTF3~Y3i6sCGE5z~n" | ||
client_id = "8ce1780f-12cc-45eb-a4c9-83f284e56621" | ||
redirect_url = "http://localhost:9999" | ||
) |
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.
Generally these sensitive data should not be pushed to GitHub. (You can use GitHub secrets when necessary.) And it seems that we don't need utils_token
as #12 (comment) says
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.
You can try to remove this file from commit history... (a chance to learn advanced git operation 🤣
Hello, @zxy-lgtm, looks like you are in the trouble. Maybe I can give you some suggestions:
At last, happy hacking! ;-) |
change it into utils_token.go
What about pushing |
Hello, any updates here? |
Hello, any updates? (Can you tell us your schedule?) |
I will try to finish it before 9.10
…---Original---
From: ***@***.***>
Date: Mon, Sep 6, 2021 14:14 PM
To: ***@***.***>;
Cc: ***@***.******@***.***>;
Subject: Re: [beyondstorage/go-service-onedrive] Add Oauth2 Support And Add Path Support in sdk (#12)
Hello, any updates? (Can you tell us your schedule?)
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications on the go with GitHub Mobile for iOS or Android.
|
there also have some problems :
I use code flow to get a oauth2 access_token so that we can refresh it to enable long-term use of the API in some scenarios.
But in the first step, I can only access get on the
page_ code_ url
method to obtain the corresponding'code
in the redirection. Thecode
is attached to the redirection URL set by Azure. I think you can obtain thecode
by obtaining the redirected URL, but it is not successful.https://docs.microsoft.com/en-us/onedrive/developer/rest-api/getting-started/msa-oauth?view=odsp-graph-online