Skip to content

Add MS Graph write endpoints for drive items #44

@dschmidt

Description

@dschmidt

Libre Graph specs reads on /drives/{id}/items/{id} (GET), a narrowly-scoped PATCH (only @UI.Hidden), DELETE (share-jail unmount only), and GET /content (#38, merged). Several MS Graph write endpoints are missing or incomplete. Consumers fall back to WebDAV for write ops and pay an extra Graph round-trip per path segment to resolve the resulting driveItem (concrete example: opencloud-eu/n8n-nodes-opencloud#11).

Endpoints needed for MS Graph parity:

Endpoint Purpose Spec Server impl
POST /items/{item-id}/children (non-root) create folder / file shell at arbitrary parent needed (draft in #42) needed
PUT /items/{item-id}/content one-shot small-file upload needed needed
POST /items/{item-id}/copy copy item needed needed
PATCH /items/{item-id} (rename / move) accept name and parentReference beyond @UI.Hidden needed (spec line 1231 locks body) needed
DELETE /items/{item-id} (normal drive items) recycle / permanently delete non-share-jail items already broad enough (line 1280 describes recycle-bin behavior; example at line 1298 uses a share-jail-shaped id and could be supplemented with a normal example) needed
GET /items/{item-id}/children (non-root) list children of a folder at arbitrary parent needed (draft in #43) already exists (GetDriveItemChildren)

Notes on individual endpoints:

  • PUT /content: returns the uploaded driveItem (201 + driveItem), so clients can drop the post-upload resolve walk. feat: Add @microsoft.graph.downloadUrl annotation and /content endpoi… #38 covered the download direction.
  • POST /copy: MS Graph returns 202 Accepted + monitor URL (no body); a synchronous variant for fast copies (body containing the destination driveItem) would let clients skip the monitor.
  • PATCH /items/{item-id}: name and parentReference combinable in one request; response is the updated driveItem. Cross-storage moves are inherently non-instant and should be rejected with a structured error, matching today's WebDAV 502.

Related (in flight):

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions