Onedrive-api-docs: Create Share Link API Broken

Created on 9 Feb 2021  Â·  3Comments  Â·  Source: OneDrive/onedrive-api-docs

Currently the /drives/{driveId}/items/{itemId}/createLink endpoint documentation says that the scope field is not required. Specifically, the documentation says:

If the scope parameter is not specified, the default link type for the organization is created.

However, when I supply the following request body the API errors:

{
    "type": "view"
}

Here is the specific error I get

{
    "error": {
        "code": "invalidRequest",
        "message": "Invalid request"
    }
}

Note that an empty request body of {} seems to work fine, and a request body specifying both the type and the scope also works fine. However, it seems that if only a type parameter is specified, then the API errors. There is no explanation for why this is happening.

I also want to clarify that until a few days ago, this request body actually worked fine

{
    "type": "view"
}

I believe Microsoft introduced a breaking change here, so that was either an accident or these docs need updating.


Document Details

⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

resolved

Most helpful comment

I'm getting the same error message when I make this request. This seemed to happen gradually across clients across this past week

All 3 comments

Thank you for your contribution to OneDrive API Docs. We will be triaging your incoming issue as soon as possible.

I'm getting the same error message when I make this request. This seemed to happen gradually across clients across this past week

@marcreicher @ashtonhsu20 There was a change that was gradually being rolled out that caused this issue.
The rollout has been halted and this should no longer be occurring.

Was this page helpful?
0 / 5 - 0 ratings