Whether all files in the folder cannot be found in the Graph API? Or one file in the folder cannot be found in the Graph API?
When you go to the folder of SharePoint, could you see the file in the UI interface?
If you cannot see the file in the UI interface, please check following tips.
1.Go to library settings -> Versioning Settings -> Draft Item Security -> Set Any user who can read items.
2.Access the document library by using the site admin account, make sure the file is published and approved.
3.Access the document library by using the site admin account, check the permission for the file.
If you can see the file in the UI interface, please close the browser then reopen the graph explorer to search the file by using below codes.
POST https://graph.microsoft.com/v1.0/search/query
{
"requests": [
{
"entityTypes": [
"driveItem"
],
"query": {
"queryString": "filename:test.docx path:\"https://tenant.sharepoint.com/sites/emily/doc/1\""
},
"fields": [
"mimeType",
"id",
"parentReference",
"createdBy",
"name",
"createdDateTime",
"lastModifiedDateTime"
]
}
]
}
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.