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

Getting the picker v8.0 work with client_credentials OAuth flow. #82

Open
abhishek199-dhn opened this issue Dec 3, 2024 · 0 comments
Open

Comments

@abhishek199-dhn
Copy link

👋 Team,

We have an existing OneDrive integration where we store refresh_token and access_token in the BE. Using this refresh_token, we acquire a new SharePoint access_token (scope: "https://".($webURL)."/.default openid profile") that is compatible with the v8 OneDrive File Picker. Currently this works for OneDrive business account users.

However, we have certain OneDrive business account customers who are onboarded via the client_credentials OAuth flow (Domain-wide-auth), where the MS token API (/oauth2/v2.0/token) does not provide a refresh_token. We attempted to obtain a SharePoint access_token using the client_credentials flow, but the v8 File Picker APIs (the /me endpoint) return the error Unsupported app-only token or Unauthorised and doesn’t work.

How can we make the v8 OneDrive File Picker work with tokens acquired through the client_credentials flow? If that’s not feasible, what alternative solutions can be implemented?

Thanks in advance for your Help!

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

No branches or pull requests

1 participant