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

Initial Sharepoint integration #2

Open
wants to merge 3 commits into
base: v1.4-avalon
Choose a base branch
from

Conversation

masaball
Copy link

This work adds basic Sharepoint integration to browse_everything. It uses the "access on behalf of a user" authorization flow to allow a user to authenticate to the Microsoft Graph API and upload files from their personal drive(s).

Future work will be to provide upload support from other Sharepoint sites that the user has access to.


Prerequisite:
* App must be registered in the Entra Admin center to receive client_id, client_secret, and tenant_id.
* If using .default endpoint as your scope, you must register API permissions for your application. Minimum permissions:
Copy link
Author

@masaball masaball Sep 25, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

May also require Sites.Selected when implementing sites. Will need to test .

base.each do |k,v|
query += ["#{k}=#{v}"]
end
query += ["response_type=code"]
Copy link
Author

@masaball masaball Sep 25, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rather than initializing query as an empty array, this could be the initialization value instead of adding it later.

If/when we want to commit this back upstream we will want to add back in the code paths for the access without a user auth flow so leaving the initialization as is, with the expectation of having multiple login options may be preferable. (Access without a user requites the client secret to be sent with the auth request and does not send a response_type param).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant