skillfed

msgraphfs

msgraphfs v0.5 4.7M downloads/30d#2,247 on PyPI10
Permissive license The MIT License (MIT) Copyright (c) 2024 Laurent Mignon (ACSONE) Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the… (full text in the JSON record) Active released

What it is and what it does

msgraphfs is a Python filesystem implementation that bridges Microsoft Graph API (SharePoint and OneDrive) with fsspec, the standard filesystem abstraction layer in the Python data ecosystem. It registers three custom protocols—msgd://, sharepoint://, and onedrive://—allowing you to read and write files on Microsoft 365 services through fsspec-compatible libraries.

The package handles OAuth2 token management, site and drive discovery, and permission queries automatically. It supports both single-site mode (where you specify the site and drive once in configuration) and multi-site mode (where you embed site and drive names in the URL). Authentication uses Azure AD application credentials via the client credentials flow, suitable for server-to-server scenarios. It requires Python >=3.10 and depends on authlib, fsspec, and httpx.

Use it for:

  • Access files from SharePoint document libraries or OneDrive through fsspec-compatible tools without downloading locally first.
  • Build ETL pipelines that read from and write to OneDrive or SharePoint using server-to-server authentication.
  • List files with metadata and permission details from SharePoint sites programmatically for audit workflows.
  • Process multiple files in parallel using fsspec-compatible libraries by reading from SharePoint URLs with wildcard patterns.
  • Integrate Microsoft 365 storage with data processing workflows that already use fsspec.

Worth the install?

AI-flagged interpretation of the facts on this page — verify before relying

Provides a filesystem interface to Microsoft Graph API drives (SharePoint and OneDrive) via fsspec, enabling integration with fsspec-compatible data processing libraries.

Yes, if you need to integrate SharePoint or OneDrive into Python workflows using fsspec. The package is actively maintained, has low install friction, carries a permissive MIT license, and fills a clear gap for fsspec users working with Microsoft 365. Verify that your Azure AD setup and API permissions are in place before installation, and confirm that Python >=3.10 is available.

Install

msgraphfs on PyPI

pip

pip install msgraphfs

uv

uv add msgraphfs

poetry

poetry add msgraphfs

Installing msgraphfs

Before you install

Low install friction with a pure-Python wheel and only three runtime dependencies (authlib, fsspec, httpx). Active maintenance with a recent commit on 2026-08-10 and releases within the past year.

License in practice

MIT license permits commercial and private use with minimal restrictions; you may use, modify, and distribute the package freely provided you retain the copyright notice and license text.

Quickstart

pip install msgraphfs

import fsspec

storage_options = {
    'client_id': 'your-client-id',
    'tenant_id': 'your-tenant-id',
    'client_secret': 'your-client-secret',
    'site_name': 'YourSite',
    'drive_name': 'Documents'
}

fs = fsspec.filesystem('msgd', **storage_options)
files = fs.ls('/folder')

Requires Python >=3.10; Azure AD application credentials (client_id, tenant_id, client_secret) and appropriate API permissions configured in Azure Portal.

Verify before relying

  • Whether the package handles concurrent access safely in multi-threaded environments beyond fork-safe lazy initialization.
  • Performance characteristics and limitations when working with large files or high-volume directory listings.
  • Specific error handling and retry behavior for transient network or authentication failures.
  • Full scope of file operations supported (read, write, delete, rename) and any restrictions on each.

Package facts

License The MIT License (MIT) Copyright (c) 2024 Laurent Mignon (ACSONE) Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the… (full text in the JSON record) (permissive)
Python support supports the current Python release (>=3.10)
Install friction low — pure-Python wheel
Runtime dependencies 3 — authlib, fsspec, httpx
Maintenance actively maintained — 43 days since the last release
Last repo commit
First released
Downloads 4,712,760/month — #2,247 on PyPI (30-day window, as of 2026-08-14)
Known vulnerabilities none known (OSV.dev, checked 2026-08-14)

Evidence: msgraphfs-0.5-py3-none-any.whl

Intended Audience :: DevelopersLicense :: OSI Approved :: MIT LicenseOperating System :: OS Independent

Tags

sharepoint filesystem accessonedrive python interfacemicrosoft graph fsspecazure ad file storagegraph api drive mountfsspec sharepoint pluginmsgd protocol filesystem
cloud-storagemicrosoft-365fsspec-plugin

More Internet packages