logo
search
Others

How to Retrieve SharePoint Server Audit Logs with REST API or CSOM

Olivia MillerOlivia Miller Oct 9, 2026 869 views

Question details

The user needs to retrieve site collection audit data from SharePoint Server 2019 for a reporting application and needs to know if REST API or CSOM is supported.

Retrieve SharePoint Server Audit Logs with REST API or CSOM
Product
SharePoint Server 2019
Device & OS
not provided
Scenario
Developing a custom reporting application that requires extracting audit log data from a SharePoint site collection.
Observed behavior
Seeking technical confirmation and guidance on whether REST API or CSOM can be used for audit log extraction in SharePoint Server 2019.
Before you start

Ensure you have the necessary administrative privileges for the SharePoint site collection and access to Microsoft Q&A for specialized developer support.

Solution 1Recommended

Consult Microsoft Q&A for SharePoint API Support

Because custom REST API and CSOM development for SharePoint audit logs falls outside standard consumer support, you should consult SharePoint specialists on Microsoft Q&A.

Retrieving audit logs programmatically in SharePoint Server 2019 often requires specific knowledge of server-side APIs or specialized endpoints. Microsoft's standard community support does not cover advanced REST API or CSOM development topics.

1
Navigate to Microsoft Q&A

Open your web browser and go to the official Microsoft Q&A platform at https://learn.microsoft.com/en-us/answers/.

2
Search for existing threads

Use the search bar to look for 'SharePoint 2019 audit logs REST API' to see if other administrators have already solved this specific API query.

3
Post a new question

If no existing answers meet your needs, click 'Ask a question' and ensure you tag your post with 'SharePoint Server' and 'SharePoint Development' to reach the right specialists.

4
Review official documentation

While waiting for a response, review the official Microsoft documentation regarding supported audit and reporting tools for your specific SharePoint Server version.

Consult Microsoft Q&A for SharePoint API Support
Alternative Approaches: For on-premises SharePoint Server 2019, many administrators rely on Server-Side Object Model (SSOM) or PowerShell scripts to extract extensive audit logs, as CSOM capabilities for audit data can be limited.
Free Microsoft Office alternative

Analyze Exported SharePoint Audit Reports with WPS Office

While extracting SharePoint logs requires Microsoft server APIs, analyzing the resulting CSV or Excel data is effortless with WPS Office. As a free, lightweight, and highly compatible alternative to Microsoft Office, WPS Spreadsheet easily handles large audit reports and complex data filtering.

  1. 1. Download and install WPS Office: Visit the official WPS website, download the free version of WPS Office, and complete the installation process.
  2. 2. Open WPS Spreadsheet: Launch WPS Office and open the Spreadsheet module from the main dashboard.
  3. 3. Import your audit report: Go to Menu > Open and select the CSV or XLSX audit log file exported from your SharePoint Server to begin your analysis.
Fully compatible with Microsoft Excel (.xlsx, .csv) formats for seamless audit report analysis.Free and lightweight, allowing for quick installation and fast data processing on any device.Familiar user interface with powerful data filtering, sorting, and pivot table tools.
microsoft office alternative - wps office

Frequently Asked Questions

Can I use REST API to get audit logs in SharePoint Online?

For SharePoint Online (Microsoft 365), Microsoft recommends using the Office 365 Management Activity API rather than the standard SharePoint REST API to retrieve comprehensive and scalable audit logs.

Where can I view audit log reports manually in SharePoint Server 2019?

You can manually view them by navigating to Site Settings > Site Collection Administration > Audit log reports. Note that the audit logging feature must be enabled at the site collection level beforehand.

Does CSOM support full audit log retrieval in SharePoint Server?

CSOM has limited support for reading detailed audit entries. Extracting large volumes of audit data programmatically in an on-premises environment typically relies on the Server-Side Object Model (SSOM) or PowerShell cmdlets.