SOLVED

Remove all shared links for one user Onedrive

Contributor

Hello

 

How can i remove all shared links in a users onedrive ? The user has hundreds of folders that he has shared, and i need to remove the share. How can i do this using poweshell? Again i dont want to remove the data, just the share link

 

Thank you

2 Replies
best response confirmed by skipster311-175 (Contributor)
Solution
Sure, you can use the Graph API for that. I have a sample script here: https://www.michev.info/Blog/Post/3018/remove-sharing-permissions-on-all-files-in-users-onedrive-for...
Worked perfectly. Thanks!