-->

MS Graph API Unknown Error when trying to get fold

2019-07-15 08:34发布

问题:

When trying to access a specific folder in my sharepoint site's drive using the Microsoft Graph API relative pathing I get an unknown error. This exact same request worked fine just over a week ago but stopped working this week when using it again.

Test Results is a folder on my site's drive. According to OneDrive dev docs this is how the request should look: /drive/root:/path/to/folder:/children

Actual Request (site-id removed):

https://graph.microsoft.com/v1.0/sites/<site-id>/drive/root:/Test%20Results:/children

Expected Result: a list of all folders/items within the 'Test Results' folder

Actual Result:

{
    "error": {
        "code": "-1, Microsoft.SharePoint.Client.UnknownError",
        "message": "Unknown Error",
        "innerError": {
            "request-id": "79b530f9-1bb9-455d-84e0-b3144fbf9c1c",
            "date": "2017-11-06T18:58:11"
        }
    }
}

This originally used beta instead of v1.0 but it seems that the sharepoint and drive calls are no longer beta (also get the same results using beta in place of v1.0).

I've tried several different changes to my previously working request, but keep getting the unknown error. Am I missing something here since it's no longer using beta - or is this a bug on the Microsoft side? Any help is greatly appreciated.

回答1:

According to this post, the issue was on the MS side. They reverted and the issue is now resolved for me.