Overview
Document Sync
Import files from a SharePoint document library into your knowledge base with incremental updates.
Access Control
Each user’s SharePoint permissions are checked at query time — users only see RAG results from files they can access.
Supported Formats
PDF, Word, PowerPoint, Excel, CSV, plain text, and Markdown files are indexed automatically.
Authentication Modes
The connector supports two authentication modes, configured by your platform administrator:- Delegated (default)
- Service Account
Each user connects their own Microsoft account via OAuth. The connector respects per-user SharePoint permissions at query time through PBAV.
- Users must individually click Connect with Microsoft before syncing or querying
- RAG results are filtered per-user: you only see content from files you can access in SharePoint
- Best for organizations that need to enforce document-level access control
Connecting Your Microsoft Account
Before configuring the connector in delegated mode, connect your Microsoft account to authorize access to SharePoint.Open the Connectors Tab
In your AI Knowledge project, go to Advanced > Connectors. The SharePoint connector card displays your current connection status.
Connect with Microsoft
In the Microsoft Connection section of the SharePoint card, click Connect with Microsoft. A popup opens to the Microsoft sign-in page.Sign in with your organizational Microsoft account and consent to the requested permissions (read-only access to your SharePoint files and sites).
Each user connects their own Microsoft account independently. The connector uses delegated OAuth, meaning all SharePoint operations respect the signed-in user’s permissions.
Configuring the Connector
Open Configuration
Click the Configure button on the SharePoint connector card. A configuration dialog opens.
Select a SharePoint Site
The dialog loads the list of SharePoint sites accessible to your account. Select the site containing the documents to sync.If no sites appear, your Microsoft account may not have access to any SharePoint sites — contact your SharePoint administrator.
Select a Document Library
After selecting a site, the dialog loads available document libraries (drives). Choose the library to sync.A confirmation banner shows the selected site and library.
Syncing Documents
Click Sync Now on the connector card to start a synchronization. The card shows real-time progress as files are discovered, filtered, and indexed.What Happens During Sync
- File discovery — The connector recursively lists all files in the configured library, traversing subfolders
- File filtering — Only supported file types are indexed (see table below); other files are skipped
- Incremental sync — Files are compared by their
cTag(content tag). Files whose content has not changed since the last sync are skipped - Indexing — New or modified files are downloaded and indexed into the knowledge base
- Deletion detection — Files that no longer exist in SharePoint are removed from the knowledge base
Supported File Types
| Format | MIME Type |
|---|---|
application/pdf | |
| Word (.docx) | application/vnd.openxmlformats-officedocument.wordprocessingml.document |
| Word (.doc) | application/msword |
| PowerPoint (.pptx) | application/vnd.openxmlformats-officedocument.presentationml.presentation |
| Excel (.xlsx) | application/vnd.openxmlformats-officedocument.spreadsheetml.sheet |
| CSV | text/csv |
| Plain text | text/plain |
| Markdown | text/markdown |
Sync Results
After sync completes, the connector card shows a summary:- Indexed — files that were new or updated and successfully processed
- Unchanged — files skipped because their content hasn’t changed
- Deleted — files removed from the knowledge base because they no longer exist in SharePoint
- Errors — files that failed to index (e.g. missing download URL)
- Skipped — files with unsupported file types
Permission-Based Access Validation (PBAV)
PBAV only applies in delegated authentication mode. In service account mode, PBAV is disabled and all synced documents are visible to all users.
How It Works
- A user submits a query to the AI Knowledge agent
- The RAG pipeline retrieves relevant document chunks, some of which may come from SharePoint
- For each SharePoint chunk, the system calls the MCP server’s
validateUserAccessDelegatedtool, which probes the file using the querying user’s delegated OAuth token - Chunks from files the user cannot access are removed before the LLM generates a response
User Experience
The behavior varies depending on the user’s authentication state:| State | Behavior |
|---|---|
| Not connected | All SharePoint chunks are removed. The agent response includes a prompt to connect with Microsoft. |
| Connected — partial access | Only accessible chunks are included. A warning is appended: “Some documents are not accessible to you; you do not have permission to read them.” |
| Connected — full access | All relevant chunks are included. No warnings. |
PBAV uses a fail-closed approach. If the MCP server is unreachable or returns an error, all SharePoint chunks are removed from the response rather than being shown without access checks.
Non-SharePoint Documents
PBAV only applies to documents that originated from the SharePoint connector (identified by theirsharepoint tag). Documents from other sources (file uploads, web crawls, etc.) are not affected and pass through unchanged.
Disconnecting / Disabling
Disconnecting Your Microsoft Account
To disconnect your personal OAuth session:- Go to Advanced > Connectors
- In the Microsoft Connection section, click Disconnect
Disabling the Connector
To disable the SharePoint connector entirely for a project:- Go to Advanced > Connectors
- Click Configure on the SharePoint card
- Click Disable this connector
- Confirm the action
Troubleshooting
No sites appear in the configuration dropdown
No sites appear in the configuration dropdown
Your Microsoft account does not have access to any SharePoint sites, or the OAuth token has expired.Fix: Verify your SharePoint access by navigating to SharePoint directly in a browser. If your OAuth session is expired, disconnect and reconnect your Microsoft account.
Sync completes with 0 indexed files
Sync completes with 0 indexed files
This can happen if all files in the library are in unsupported formats, or if all files are unchanged since the last sync.Fix: Check the sync summary — a high “skipped” count indicates unsupported file types. A high “unchanged” count means an incremental sync detected no changes.
Files limit reached during sync
Files limit reached during sync
Your AI Knowledge project has reached its maximum document count.Fix: Remove unused documents from the project or contact your administrator to increase the limit.
Agent asks me to connect to Microsoft when I ask a question
Agent asks me to connect to Microsoft when I ask a question
PBAV detected SharePoint chunks in the RAG results but your OAuth session is missing or expired.Fix: Go to Advanced > Connectors and click Connect with Microsoft to establish or refresh your OAuth session.
Partial access warning in agent responses
Partial access warning in agent responses
You are connected but do not have access to some of the SharePoint files referenced in the RAG results.Fix: This is expected behavior — PBAV is correctly filtering results based on your SharePoint permissions. Contact your SharePoint administrator if you believe you should have access to the restricted files.