IndyVC's avatar
IndyVC
Brass Contributor
Nov 25, 2022
Status:
New

$orderby for sharepoint DriveItems

https://graph.microsoft.com/v1.0/sites/{siteID}/drives/{driveID}/items/{itemID}?$orderby=createdDateTime
 When executing the query above, the response is always: 

{
    "error": {
        "code": "notSupported",
        "message": "Operation not supported",
        "innerError": {
            "date": "2022-11-25T13:01:19",
            "request-id": "5f176875-8f91-4868-8c50-39ff3d39a3c9",
            "client-request-id": "5f176875-8f91-4868-8c50-39ff3d39a3c9"
        }
    }
}

This feature IS documented, so I'd expect this to work.

(https://learn.microsoft.com/en-us/graph/api/listitem-get?view=graph-rest-1.0&tabs=http#optional-query-parameters)

4 Comments

  • heinp's avatar
    heinp
    Copper Contributor

    Original question on Stack Overflow: https://stackoverflow.com/questions/71395284/ordering-the-driveitems-from-the-graph-api-only-possible-on-name-property 

  • bartvanmiegem's avatar
    bartvanmiegem
    Copper Contributor

    I have exactly the same issue! So frustrating this is not working out of the box, while using the UI it works fine.

    Is this feature supported in the v2 graph api?