1
votes

I am trying to access my customers (later also OneDrive business, but for the beginning only regular) OneDrive files. I started with the azuread endpoint, because it can be used with ad and Hotmail/live accounts. I registered an app with my Microsoft live account (not business) and setup everything using Django and social-auth. The login is working I tried it with the same live account and I get an access token in social auth. When I try to access the files using postman and the token I get the error: CompactToken parsing failed As response. So I am completely confused about using the Microsoft graphing API to get to the customers OneDrive files. Is this the right endpoint or shouldn't I use azuread but live instead? Do I need a business account for the app registration? What would be the right way to get it working? The Microsoft API architecture is very complex. Probably it has its advantages, but after I grasp it. Thanks in advance If you need further information, just let me know

1

1 Answers

1
votes

You're on the right path, but it's possible you're sending your token to the wrong endpoint. Since your token was minted for MS Graph, make sure you send you token to the OneDrive endpoint of MS Graph. The docs are here.

Now in terms of the difference between Azure AD and MSA (Microsoft Live Accounts) there's a few key differences. Fundamentally, these are two different identities a user may have. There is a new converged endpoint called Azure AD v2.0 which supports both AAD+MSA. For a code sample, checkout this link.