Skip to main content

StackOne File Picker Integrations: SharePoint vs OneDrive

StackOne supports file selection from Microsoft SharePoint and OneDrive via Microsoft Graph API. While both services use the same API surface, their data models, hierarchies, and access scopes differ, especially around SharePoint’s site-based structure. This document outlines how StackOne models and integrates these services in a consistent developer-facing experience.

File Picker Overview

  • Native File Picker: Both SharePoint and OneDrive use Microsoft’s native file picker components for the file and folder interface.
  • Custom Site Picker (SharePoint only): For SharePoint, StackOne builds a custom site selection layer on top of the native picker. This allows users to:
    • Choose a SharePoint site
    • Then proceed to the native SharePoint file picker scoped to that site’s drives and folders
  • Unified Selection Model: Regardless of source (SharePoint or OneDrive), selected files and folders are normalized into a common StackOne format in both UI and API.

Technical Architecture Comparison


StackOne Modeling Strategy

Both integrations are abstracted into the same file model and API schema. Internally:

API Comparison

Here’s how the underlying Microsoft Graph API calls differ between the two integrations.

Implementation Details

  • Authentication:
    • Microsoft Identity Platform (OAuth 2.0)
    • Required scopes:
      • Files.Read, Files.Read.All
      • Sites.Read.All (SharePoint only)
  • Pagination Support:
    • All Microsoft Graph list endpoints are paginated via @odata.nextLink
    • StackOne SDKs handle pagination and aggregation transparently
  • File Filtering:
    • SharePoint Pages (HTML content) are excluded
    • OneDrive integration shows files as they appear in the user’s drive (including shared items)
  • Caching Strategy:
    • Site metadata in SharePoint may be cached per session for performance
    • Drives and folders are lazily loaded as users navigate via the picker

Summary


Let me know if you’d like this exported to Markdown, Notion, or built into an internal developer doc format.