6
votes

I'm testing Graph Api for OneDrive.

For testing purposes, I both listen to a webhook subscription, and poll deltas each 10 seconds.

I noticed that if I create/delete sharing links (for file or folder) of "anyone can access" and "all people in Company" types -- I do not receive webhook push or new delta.

For all other change types, like new file, renamed file, even sharing "with specific person" -- both methods show new event.

My question is: is it supposed to work (any kind of notification about item sharing by link)? Am I doing something wrong, or is this an API issue?

1
I would love to know the answer to this too. It would seem that MSFT really wants users to collaborate using OneDrive, but Graph does not appear to be able to tell us when a file "shared with us" has changed? How are we to keep our clients up-to-date? Hopefully someone from the Graph/OneDrive team can help? - AWeber

1 Answers

0
votes

I know it's probably not too helpful but:

  1. From Graph page about webhooks and notifications: "Your app will not receive notifications for items that have been shared with the user who has signed in or remote items in the user's drive unless separate subscriptions are created on the original items." - it's not clear to me how can I create notifications "on the original items" but anyway by design - no notifications by default.

  2. What you can do, is to poll on /SharedWithMe endpoint that returns all the items that were shared with the user (from my check it only returns internal (same tenant) shared items, but in the big WWW you can find references that claim it also for external sharing).