Overview
The SharePoint integration lets users connect their Microsoft 365 SharePoint so Alysio can browse sites, document libraries, and lists and read or manage content on their behalf. Users can ask Alysio to list sites, browse drives and folders, download or export file content, save Excel files for analysis with DuckDB, list site users, work with SharePoint lists (get items, metadata, create and update list items)—all in natural language. The integration uses the user’s connected Microsoft account; IDs (site, drive, list, item) from earlier steps must be used in later calls (e.g. get site ID from connected sites, then drive ID, then item ID).
Supported capabilities / objects
- Sites — List all SharePoint sites the user can access in the organization.
- Drives and files — List document libraries (drives) for a site; list files in a drive root or in a folder; download a drive item (returns download URL); export file content (Office docs, PDF, text, etc.; 5MB limit for inline content); save Excel content for use with
execute_sql_query.
- Lists — Get lists in a site; get list items; get list metadata (columns); create a list item; update a list item. Use list metadata to get internal column names for create/update.
- Users — List users in a SharePoint context (for use with people fields in list items).
Authentication
Method: OAuth 2.0 (Microsoft/Azure AD). The MCP sends requests using a Bearer token and a credential ID that identifies the user’s connected Microsoft account. Microsoft Graph API is used for SharePoint sites, drives, and lists.
Redirect URI: Configured when the SharePoint integration is set up in Alysio. The Azure AD app must allow this redirect URI.
Token handling
- OAuth tokens for the connected Microsoft account are stored securely and refreshed automatically.
- Each user/tenant has their own credential; the MCP sends the appropriate credential ID with each request so calls are isolated per connection.
- On disconnect, that credential is no longer used and SharePoint tools will not be available for that user until they reconnect SharePoint.
Required scopes
Files.ReadWrite.All
Sites.Manage.All
Sites.ReadWrite.All
Connection required: Users must connect SharePoint in Alysio before SharePoint tools work. If the connection is missing or expired, they may need to re-authorize in Settings → Integrations.
IDs and metadata: Use the id value from API responses as site_id, drive_id, list_id, or item_id—do not use other keys. For create/update list item, use internal column names from sharepoint_get_list_metadata and user IDs from sharepoint_get_user_list for people fields.
Export limits: Export has a 5MB file-size limit for inline content; larger files return a download URL. For Excel analysis, use sharepoint_save_excel_file_content (not export).
The SharePoint MCP exposes the following tools. Users can invoke these capabilities through natural language in Alysio.
| Tool | Description | Example user prompts |
|---|
sharepoint_connected_sites | Returns all SharePoint sites the user can access in the organization. | ”List my SharePoint sites”, “What SharePoint sites do I have access to?” |
sharepoint_get_drive_list | Returns document libraries (drives) for a site; use site_id from connected_sites. | ”List document libraries for this site”, “What drives are in this site?” |
sharepoint_get_drive_file_list | Returns files and folders in the root of a drive; use site_id and drive_id. | ”List files in this document library”, “What’s in the root of this drive?” |
sharepoint_get_drive_folder_files | Returns files in a specific folder of a drive; use site_id, drive_id, and item_id (folder). | ”List files in this folder”, “What’s inside this SharePoint folder?” |
sharepoint_download_drive_item | Returns download URL and metadata for a drive item; use site_id, drive_id, item_id. | ”Get download link for this file”, “Download this document.” |
sharepoint_export_file_content | Exports file content by site and item ID; supports Office, PDF, text, etc.; 5MB limit for inline content. For Excel use save_excel. | ”Get the text from this Word doc”, “Export the content of this PDF.” |
sharepoint_save_excel_file_content | Saves an Excel file’s content by site_id and item_id to a table for use with execute_sql_query; requires a name and optional sheet(s). | ”Save this spreadsheet so we can analyze it”, “Load this Excel from SharePoint and make it queryable.” |
sharepoint_get_user_list | Returns users in a SharePoint context (for people fields in lists). | ”List users in this site”, “Get user list for people picker.” |
sharepoint_get_list | Returns the lists in a SharePoint site; use site_id from connected_sites. | ”List all lists in this site”, “What lists does this site have?” |
sharepoint_get_list_items | Returns items in a list; use site_id and list_id. | ”Get items from this list”, “Show rows in this list.” |
sharepoint_get_list_metadata | Returns list metadata including column definitions (internal names for create/update). | ”Get column names for this list”, “What fields does this list have?” |
sharepoint_create_list_item | Creates a new list item; use site_id, list_id, and Fields (internal column names from list metadata; user IDs for people fields). | ”Add a row to this list”, “Create a new item in this list.” |
sharepoint_update_list_item | Updates an existing list item; use site_id, list_id, item_id, and Fields (internal column names). | ”Update this list item”, “Change the status of this row.” |
App Behavior
- API calls are made on-demand only when the user asks something that requires SharePoint data or an action (e.g. list sites/drives/files, download/export, save Excel, list/list items, create/update list item). There is no background sync; each request triggers the relevant Microsoft Graph (SharePoint) API call using the user’s OAuth credential.
Example flow
- User asks: “What lists are in the Sales site?”
- Alysio routes the request to the SharePoint MCP.
- The MCP calls
sharepoint_connected_sites to find the site, then sharepoint_get_list with that site’s id as site_id.
- The request is sent to Microsoft Graph using the user’s stored OAuth credential.
- The MCP returns the list of lists; Alysio presents the results in chat. The user can then ask to get list items or create/update an item using list_id and metadata.
Troubleshooting
Common issues
- Missing or expired connection — User sees errors or no SharePoint data. Fix: Reconnect SharePoint in Settings → Integrations (re-authorize with Microsoft).
- 401 Unauthorized — Token invalid or revoked. Fix: Re-authorize the integration in Settings → Integrations.
- 403 Forbidden — Often due to insufficient OAuth scopes. Fix: Ensure the SharePoint integration has the required scopes (
Files.ReadWrite.All, Sites.Manage.All, Sites.ReadWrite.All).
- Wrong ID used — Errors or empty results when site_id, drive_id, list_id, or item_id are incorrect. Fix: Use only the
id value from the previous tool’s response (e.g. from connected_sites for site_id, from get_drive_list for drive_id).
- Create/update list item fails (invalid field) — Display names or guessed column names are not accepted. Fix: Use
sharepoint_get_list_metadata and supply Fields using internal column names; for people columns use user IDs from sharepoint_get_user_list.
- File size limitation — Export returns inline content only for files ≤5MB. Fix: Use the returned downloadUrl for larger files. For Excel analysis use
sharepoint_save_excel_file_content.
- Save Excel requires DuckDB —
sharepoint_save_excel_file_content is intended to be followed by execute_sql_query for analysis. Fix: Ensure the user flow asks Alysio to analyze the saved data with SQL if that’s the goal.
Support