Unable to Retrieve SharePoint List Item Attachments in .NET Core using Graph API

EdbergVasan DallasVaz 0 Reputation points
2025-02-13T07:00:27.3+00:00

In SharePoint Online, when retrieving list items using Graph Explorer, the Attachments property only returns a boolean value (true or false), indicating whether an item has attachments. However, it does not provide direct links to attached files such as images, PDFs, or text documents.

However, Graph Explorer does not support the Attachments property.

I need help in retrieving attachment links for list items in SharePoint Online using the Microsoft Graph API using C#.

Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
13,050 questions
SharePoint Development
SharePoint Development
SharePoint: A group of Microsoft Products and technologies used for sharing and managing content, knowledge, and applications.Development: The process of researching, productizing, and refining new or existing technologies.
3,292 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Yanli Jiang - MSFT 29,041 Reputation points Microsoft Vendor
    2025-02-13T09:43:50.48+00:00

    Hi @EdbergVasan DallasVaz ,

    Good days, thanks for posting in this forum.

    Unfortunately, it is currently impossible to obtain the URL of the attachment in the List item through the API. As you said, it only returns a Boolean value. But you can try to use Power Shell to obtain relevant information about Attachments:

    SharePoint Online: Get Attachments Report in a List using PowerShell

    Non-official, just for reference.

    Please do let us know if you have any further queries.

    Kindly consider accepting the answer if the information provided is helpful. This can assist other community members in resolving similar issues.


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.