Is there any API to get Microsoft compliance reports?

Sulagna Nandi 0 Reputation points
2024-04-16T04:42:20.69+00:00

I want to get the Microsoft Message encryption report and Alerts from Microsoft Compliance programatically using API. Manually I do the process in the following way:

  1. Message Encryption Report:
    Screenshot 2024-04-16 at 10.03.47 AM

Link: https://compliance.microsoft.com/reports/encryptionreport

  • Select “Export” found below the graph
  • Follow prompts that appear on the right of the screen

Report will be emailed to you, click on link in email and report will be downloaded via browser.

  1. DLP reports:
    Screenshot 2024-04-16 at 10.05.05 AM

Link: https://compliance.microsoft.com/datalossprevention?viewid=dlpalerts

  • Click on “Alert Name”
  • Using the details shown on the right pane, count DLP instances for PII and PCI.
Microsoft 365 and Office | Install, redeem, activate | For business | Windows
Microsoft Security | Intune | Reporting
Microsoft Security | Microsoft Graph
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Catherine Kyalo 2,380 Reputation points Microsoft Employee
    2024-05-13T08:41:54.81+00:00

    Hi @Sulagna Nandi

    For the email encryption report, you can use the Get-MailDetailEncryptionReport cmdlet:

    https://free.blessedness.top/en-us/powershell/module/exchange/get-maildetailencryptionreport?view=exchange-ps

    e.g. Get-MailDetailEncryptionReport -StartDate 05/01/2024 -EndDate 05/12/2024

    123

    To get all the DLP alerts across workloads, you can use the Graph API's /alerts_v2 endpoint instead and filter DLP as the source:

    https://free.blessedness.top/en-us/graph/api/security-list-alerts_v2?view=graph-rest-1.0&tabs=http

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.