Forum Discussion
T0mek
Jun 06, 2022Copper Contributor
Finding last owner of an orphaned Team (powershell)
Hi there,
Is there a way to find the last owner of an orphaned team? I would like to be able to find the last known owner (deleted user) of a team and then reassign this team to owner's manager.
Thanks for your help!
- As far as I am concerned, this is currently not possible with PowerShell. you can only pull this type of info via API request but never through PowerShell. you can try your luck with Audit logs but again you can't really go way back and the info may not be available for your as you want it to be. Best way to accomplish this in my opinion is to utilize a third part tool like ShareGate Apricot, the tool will generate a report of orphaned Teams for you and will highlight the last active members and last known owners.
- AwsAyadBrass ContributorAs far as I am concerned, this is currently not possible with PowerShell. you can only pull this type of info via API request but never through PowerShell. you can try your luck with Audit logs but again you can't really go way back and the info may not be available for your as you want it to be. Best way to accomplish this in my opinion is to utilize a third part tool like ShareGate Apricot, the tool will generate a report of orphaned Teams for you and will highlight the last active members and last known owners.