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 search result from the response. But we get the correct search results for some accounts, but this issue only occurs for certain users.
API Request :
https://graph.microsoft.com/v1.0/me/drive/root/search(q='.xlsx')
Response
{
"@odata.context": "https://graph.microsoft.com/v1.0/$metadata#Collection(microsoft.graph.driveItem)",
"@microsoft.graph.tips": "Use $select to choose only the properties your app needs, as this can lead to performance improvements. For example: GET me/drive/root/microsoft.graph.search(q=<key>)?$select=audio,bundle",
"value": []
}
Any alternative for this apis?