Per my test, I am able to get ondrive site by GET https://graph.microsoft.com/v1.0/sites
. You can refer to the following document
https://learn.microsoft.com/en-us/graph/api/site-list?view=graph-rest-1.0
In my case, I am unable to retrieve One Drive For Business sites by GET https://graph.microsoft.com/v1.0/sites?search={query}
.
The api only returns the collection of drives (document libraries) under this site. You can refer to the following document
https://learn.microsoft.com/en-us/graph/api/site-search?view=graph-rest-1.0&tabs=http
https://learn.microsoft.com/en-us/graph/api/resources/site?view=graph-rest-1.0#relationships
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.