SOLVED

Report Azure AD Restricted Users

%3CLINGO-SUB%20id%3D%22lingo-sub-2682752%22%20slang%3D%22en-US%22%3EReport%20Azure%20AD%20Restricted%20Users%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2682752%22%20slang%3D%22en-US%22%3E%3CP%3EHello%20together%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI%20need%20to%20get%20the%20the%20report%20from%20Azure%20AD%20User%20who%20have%20had%20their%20email%20privleges%20restricted%20due%20to%20spamming%3CBR%20%2F%3EThe%20following%20link%20shows%20this%20in%20the%20Admin%20Center%3CBR%20%2F%3E%3CA%20href%3D%22https%3A%2F%2Fprotection.office.com%2Frestrictedusers%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehttps%3A%2F%2Fprotection.office.com%2Frestrictedusers%3C%2FA%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIs%20there%20a%20way%20to%20do%20this%20from%20within%20PowerShell%20(as%20it's%20part%20of%20a%20reporting%20%22Suite%22)%20to%20be%20able%20exporting%20it%20to%20CSV%2FExcel%20in%20an%20easier%20way%3F%3CBR%20%2F%3ECan%20this%20be%20achieved%20using%20the%20Graph%20API%20Module%20for%20PowerShell%3F%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThank%20you%20for%20your%20Help%20and%20best%20regards%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThomas%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2683068%22%20slang%3D%22en-US%22%3ERe%3A%20Report%20Azure%20AD%20Restricted%20Users%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2683068%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F1136180%22%20target%3D%22_blank%22%3E%40TechThomas%3C%2FA%3E%26nbsp%3BUsing%20the%20Exchange%20Online%20PowerShell%20module%2C%20you%20get%20access%20to%20the%20%22Get-BlockedSenderAddress%22%20cmdlet%20which%20will%20return%20this%20list%20and%20you%20can%20then%20export%20it%20as%20CSV.%20More%20information%20can%20be%20found%20%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fmicrosoft-365%2Fsecurity%2Foffice-365-security%2Fremoving-user-from-restricted-users-portal-after-spam%3Fview%3Do365-worldwide%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%22%3Ehere%3C%2FA%3E.%20I%20am%20not%20aware%20of%20a%20corresponding%20Graph%20API%20call%20though%2C%20but%20then%20again%2C%20I%20don't%2Fcan't%20know%20everything%20%3A)%3C%2Fimg%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E
Occasional Contributor

Hello together

 

I need to get the the report from Azure AD User who have had their email privleges restricted due to spamming
The following link shows this in the Admin Center
https://protection.office.com/restrictedusers

 

Is there a way to do this from within PowerShell (as it's part of a reporting "Suite") to be able exporting it to CSV/Excel in an easier way?
Can this be achieved using the Graph API Module for PowerShell?

 

Thank you for your Help and best regards

 

Thomas

2 Replies
best response confirmed by TechThomas (Occasional Contributor)
Solution

@TechThomas Using the Exchange Online PowerShell module, you get access to the "Get-BlockedSenderAddress" cmdlet which will return this list and you can then export it as CSV. More information can be found here. I am not aware of a corresponding Graph API call though, but then again, I don't/can't know everything :)

thank you for your fast answer

sometimes the result is so close that you simply not seeing it :)