Graph API Drive Items

Ivan Zeljkovic 60 Reputation points
2024-06-20T20:35:14.9+00:00

Hi there, I'm using several of the OneDrive/SharePoint APIs to grab all folder/file info for a given user/site.

One concern I have: will I see folders/files shared with the user that they do not own?

The API that I'm using for the collection is `/v1.0/drives/{drive-id}/root/children, would this ever return items that do not belong to that drive-id (shared with it)?

I unfortunately don't have the resources to test this behavior between two business accounts, so I appreciate any help. Thanks.

Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
11,154 questions
0 comments No comments
{count} votes

Accepted answer
  1. Vasil Michev 98,766 Reputation points MVP
    2024-06-21T08:43:47.6566667+00:00

    No, it will not. Only files from the given drive will be returned. If you have added a "shortcut" to a shared file, it will be shown as .url item, which basically contains the URL to the shared item.

    1 person found this answer helpful.
    0 comments No comments

0 additional answers

Sort by: Most helpful