Unable to Retrieve SharePoint List Items in .NET Core using SharePoint Rest API

ArunKumar Arumugam 60 Reputation points
2024-10-16T13:39:57.1466667+00:00

Hi Team,

I have created a new app registration in the Azure Active Directory section and generated a client secret. I also granted the necessary API permissions for SharePoint sites with 'AllSites.FullControl' and obtained admin consent.

I used the client ID, tenant ID, and client secret in my .NET Core application to fetch SharePoint list details using the "SharePoint REST API". However, I received an 'Unauthorized' response.

Could you please review this and provide suggestions to resolve the issue using the "SharePoint REST API"?

Note: Please provide the details using the "SharePoint REST API" instead of the "Graph Client."

Microsoft 365 and Office | SharePoint | Development
Microsoft Security | Microsoft Entra | Microsoft Entra ID
{count} votes

Your answer

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