Skip to main content
Every SharePoint site the token can reach becomes a folder of its document libraries, each holding its real files as raw bytes. No drive ID is needed: the mount finds the sites and libraries itself.

Setup

The mount needs only a Microsoft Graph access token with SharePoint access.
Best for scripts and CI. There is no signed-in user; the mount works through /sites and /sites/{id}/drives, which need no /me context.
  1. In the Microsoft Entra admin center, go to Entra ID > App registrations > New registration.
  2. Under API permissions > Microsoft Graph > Application permissions, add Sites.Read.All to read or Sites.ReadWrite.All to write, then click Grant admin consent.
  3. Under Certificates & secrets, create a client secret.
  4. Request a token:
The fastest way to try it as a user. The token lasts about an hour and reaches only what that user can.
  1. Open Graph Explorer and sign in.
  2. Run a SharePoint query such as GET /sites?search=* and consent when asked.
  3. Open the Access token tab and copy the token.
With the token in TOKEN, list the sites and one site’s libraries:
A token string lasts about 60 minutes. For a long-running mount, pass a callable as access_token: it is called for each request and again after a 401, so the mount outlives one token.

Connect

workspace.yaml

Layout

  • Paths read /<site>/<library>/<path>, with the site’s display name. tenant_host and site_filter narrow the sites listed.
  • site plus drive mounts one library as the root, and key_prefix one folder inside it.
  • Snapshots pin files through version history, which is on by default; old versions read only while the library keeps them (an admin can cap or turn off versioning).

Sample runs

On a write mount, tee, cp, mv, rm and mkdir change the library; the token needs a write permission such as Sites.ReadWrite.All.

SDK guides

Python

Every config field, the VFS.md and write support.

TypeScript

Every config field, the VFS.md and write support.