Getting empty response while search an excel files in OneDrive

Hari 6 Reputation points


We are using the 'Search for DriveItems within a Drive' API to search for a particular file across the entire OneDrive. While using this API, we are receiving an empty response from Microsoft. We get the correct search results for some accounts, but this issue only occurs for certain users.

Sample API Request'.xlsx')

Sample API Response

    "@odata.context": "$metadata#Collection(microsoft.graph.driveItem)",
    "": "Use $select to choose only the properties your app needs, as this can lead to performance improvements. For example: GET me/drive/root/<key>)?$select=audio,bundle",
    "value": []
Microsoft Graph
Microsoft Graph
A Microsoft programmability model that exposes REST APIs and client libraries to access data on Microsoft 365 services.
11,067 questions
A Microsoft file hosting and synchronization service.
907 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Hitesh Pachipulusu - MSFT 475 Reputation points Microsoft Vendor

    Hello @Hari,

    Thank you for contacting Microsoft Support.

    I have tried the same Graph API call in my tenant and able to fetch the details in the response using Graph Explorer.

    drive search

    Please ensure that you are using correct permissions provided in the documentation.

    As you mentioned the issue only occurs for limited users, can you check whether the users drive consists of any '.xlsx' files. If no items are found, the API will return an empty collection.

    If there are '.xlsx' files in drive and still you are getting empty response, I would recommend you raise a support case with Microsoft Graph, a Support Engineer will be able to look into this issue and assist you better. You can raise support ticket from New support request - Microsoft Entra admin center or

    Hope this helps.

    If the answer is helpful, please click Accept Answer and kindly upvote it. If you have any further questions about this answer, please click Comment.

    1 person found this answer helpful.
    0 comments No comments