Documentation Index
Fetch the complete documentation index at: https://docs.useparagon.com/llms.txt
Use this file to discover all available pages before exploring further.
Required Scopes
To configure a Sync for SharePoint, you need to request the following scopes from your Microsoft OAuth application:Sites.Read.AllFiles.Read.AllUser.Read.AllUser.ReadGroup.Read.Alloffline_access
If you are using Permissions API, SharePoint requires these scopes to be configured as Application Permissions (not Delegated Permissions) in your Azure AD app registration. This requires certificate-based authentication and admin consent.Follow the SharePoint: Using Application Permissions setup guide before enabling a sync.
Synced Objects
SharePoint supports the following Synced Objects:Files
Send a request to Enable Sync to start a file sync. Syncs for SharePoint can be created with one of the following configurations:- Site Sync: All files in the specified SharePoint site will be synced.
- Folder Sync: Only files in the specified folder will be synced (recursively including all subfolders by default).
- Sync of specific files: Only a group of specific files will be synced.
- Site Sync
- Folder Sync
- Sync of specific files
Example
The SharePoint Site ID to sync files from. This is required and specifies which SharePoint site’s document libraries should be synced.
An optional array of MIME types to filter synced files. Only files matching the specified MIME types will be synced.
Set to
true to include each file’s SharePoint list item fields (custom columns and library metadata) on the synced File under customFields.metadata. Defaults to false. See File metadata for details.File metadata
Synced SharePoint files include additional metadata in the FilecustomFields object:
fullPath(always included): The file’s full path within its drive, built from the parent folder path and file name (for example,/drives/<driveId>/root:/Shared Documents/Reports/Q1.pdf). Use this when you need to display or reason about the location of a file in SharePoint without traversing the folder hierarchy yourself.metadata(included whenincludeMetadataistrue): A flat object of the file’s SharePoint list item fields, including built-in columns and any custom columns defined on the document library. This is fetched per file using the Microsoft GraphlistItemendpoint, so enabling it adds an extra API call per synced file.
includeMetadata enabled:
If a file does not have an associated list item (for example, items in a personal OneDrive context), the
metadata field is omitted for that file.Choosing Files and Folders
You can allow your user to select files from their SharePoint account in your app with the SharePoint File Picker provided by the Paragon SDK. Showing the File Picker Use the Paragon SDK in your frontend application to show the File Picker in your app. The SDK provides anExternalFilePicker class to load SharePoint’s JavaScript into your page and authenticate with your user’s connected SharePoint account.