Sharepoint Mcp
About
Production-grade MCP Server for Microsoft SharePoint — give your AI agent (Claude, Cursor, Continue) live access to read, write, and manage SharePoint files and folders.
Details
- License
- MIT
Explore
| | Feature | Description |
| --- | -------------------------- | ------------------------------------------------------ |
| 🔀 | Dual API Support | Choose Office365 REST or Microsoft Graph API |
| 📁 | Folder Management | List, create, delete, get full recursive tree |
| 📄 | Document Management | Upload, download, update, delete, search, read content |
| 🏷️ | Metadata Management | Read and update SharePoint list-item fields |
| 🔍 | Smart Parsing | Auto-detects PDF / Word / Excel / text |
| 🔎 | KQL Search | Native SharePoint KQL search for semantic file finding |
| 📂 | Flexible Library Scope | Scope to a subfolder or access the entire library root |
| 🔁 | Auto-Retry | Exponential backoff on SharePoint 429/503 throttling |
| 🚀 | Dual Transport | stdio for desktop · http for Docker/remote |
| 🪵 | Structured Logging | JSON in production · coloured console in dev |
| 🐳 | Docker-Ready | Single command: docker compose up -d |
| 🛡️ | Non-Root Container | Runs as unprivileged user inside Docker |
| 🩺 | Health Check | Live /health endpoint with real SharePoint check |
| 🤖 | CI/CD | Tested on Python 3.10 · 3.11 · 3.12 · 3.13 |
---
Setting up with Highlight
This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:
- Download and install Highlight from highlightai.com/download
- Navigate to the plugins tab and select "Add Custom Plugin"
-
Configure the plugin with the settings below
Plugin Name
Sharepoint McpCommand (node, npx, python, etc.)Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.
- Enable "Start Automatically" if you want the plugin to start when Highlight launches
From the repository
pip install sharepoint-mcp
Or from source:
git clone https://github.com/ravikant1918/sharepoint-mcp.git
cd sharepoint-mcp && pip install -e .
cp .env.example .env
docker compose ps
curl http://localhost:8000/health
SHAREPOINT_MCP_VERSION=v1.0.1 docker compose up -d
git clone https://github.com/ravikant1918/sharepoint-mcp.git
cd sharepoint-mcp
cp .env.example .env
| Variable | Default | Description |
| ------------ | --------- | ------------------- |
| TRANSPORT | http | stdio or http |
| HTTP_HOST | 0.0.0.0 | Bind address |
| HTTP_PORT | 8000 | Port |
| LOG_FORMAT | json | json or console |
---
| Variable | Required | Default | Description |
| --------------------------- | -------- | ------------------------ | ----------------------------------------------------------- |
| SHP_ID_APP | ✅ | | Azure AD app client ID |
| SHP_ID_APP_SECRET | ✅ | | Azure AD client secret |
| SHP_TENANT_ID | ✅ | | Microsoft tenant ID |
| SHP_SITE_URL | ✅ | | SharePoint site URL |
| SHP_API_TYPE | | office365 | office365, graph, or graphql |
| SHP_LIBRARY_NAME | | Shared Documents | Library name (Office365 REST only; Graph auto-detects) |
| SHP_DOC_LIBRARY | | _(empty = full library)_ | Subfolder scope (e.g. mcp_server). Empty = entire library |
| SHP_MAX_DEPTH | | 15 | Max tree depth |
| SHP_MAX_FOLDERS_PER_LEVEL | | 100 | Folders per batch |
| SHP_LEVEL_DELAY | | 0.5 | Delay (s) between tree levels |
| TRANSPORT | | stdio | stdio or http |
| HTTP_HOST | | 0.0.0.0 | HTTP bind host |
| HTTP_PORT | | 8000 | HTTP port |
| LOG_LEVEL | | INFO | DEBUG INFO WARNING ERROR |
| LOG_FORMAT | | console | console or json |
---
Problem: Missing or invalid SharePoint credentials
Solution: Verify all 4 required environment variables are set:
bashecho $SHP_ID_APP $SHP_ID_APP_SECRET $SHP_TENANT_ID $SHP_SITE_URL
```
Claude Desktop / Cursor
Paste into your MCP client config file to install this server.
{
"mcpServers": {
"sharepoint mcp": {
"sharepoint": {
"command": "sharepoint-mcp",
"env": {
"SHP_ID_APP": "your-app-id",
"SHP_ID_APP_SECRET": "your-app-secret",
"SHP_SITE_URL": "https://your-tenant.sharepoint.com/sites/your-site",
"SHP_TENANT_ID": "your-tenant-id",
"SHP_DOC_LIBRARY": "Shared Documents/your-folder"
}
}
}
}
}
McpServers
{
"sharepoint": {
"command": "sharepoint-mcp",
"env": {
"SHP_ID_APP": "your-app-id",
"SHP_ID_APP_SECRET": "your-app-secret",
"SHP_SITE_URL": "https://your-tenant.sharepoint.com/sites/your-site",
"SHP_TENANT_ID": "your-tenant-id",
"SHP_DOC_LIBRARY": "Shared Documents/your-folder"
}
}
}
The MCP Server that gives your AI agent a brain for Microsoft SharePoint
A production-grade Model Context Protocol (MCP) server for Microsoft SharePoint.
Connect Claude Desktop, VS Code Copilot, Cursor, Continue, or any MCP-compatible AI agent
to your SharePoint — read files, manage folders, and reason over your organisation's knowledge.
📚 Docs · 🗺️ Roadmap · 🐛 Bugs · 💡 Features
</div>
---
📑 Table of Contents
- Why sharepoint-mcp?
- What Your Agent Can Do
- Features
- Quickstart
- Docker
- Transport Modes
- Integrations — Claude Desktop · VS Code Copilot · Cursor
- All 14 Tools
- Configuration Reference
- Limitations
- Troubleshooting
- Development
- Documentation
- Contributing
- Security
---
🧠 Why sharepoint-mcp?
> Most AI agents only know what's in their training data.
> sharepoint-mcp gives your agent _live access_ to your organisation's real knowledge.
| Without sharepoint-mcp | With sharepoint-mcp |
| ---------------------------------- | --------------------------------------- |
| 🤷 Agent guesses or hallucinates | Agent reads the actual document |
| 📋 You copy-paste content manually | Agent fetches files automatically |
| 🔒 Knowledge locked in SharePoint | Knowledge flows into your AI workflow |
| 🐌 Static, one-shot answers | Agent reasons, rewrites, and saves back |
---
🚀 What Your Agent Can Do
📖 Understand Any Document
You: "Summarise the Q3 report in the Finance folder"
Agent: → Get_Document_Content("Finance", "Q3_Report.pdf")
→ Reads full extracted text
→ Returns a sharp, accurate summary
✏️ Read → Reason → Write
You: "Translate the proposal to French and save it"
Agent: → Get_Document_Content → translate → Upload_Document
🗂️ Navigate Your Library
You: "What files are in the Legal/Contracts folder?"
Agent: → List_SharePoint_Documents("Legal/Contracts")
📊 Supported File Formats
| 📄 Format | 🤖 What the Agent Gets |
| -------------------------------------------- | ----------------------------- |
| PDF | Full text from every page |
| Word .docx .doc | Complete document content |
| Excel .xlsx .xls | All sheets as structured text |
| Text, JSON, Markdown, HTML, YAML, Python | Raw content as-is |
| Images, ZIP, binaries | File type + Base64 |
---
✨ Features
| | Feature | Description |
| --- | -------------------------- | ------------------------------------------------------ |
| 🔀 | Dual API Support | Choose Office365 REST or Microsoft Graph API |
| 📁 | Folder Management | List, create, delete, get full recursive tree |
| 📄 | Document Management | Upload, download, update, delete, search, read content |
| 🏷️ | Metadata Management | Read and update SharePoint list-item fields |
| 🔍 | Smart Parsing | Auto-detects PDF / Word / Excel / text |
| 🔎 | KQL Search | Native SharePoint KQL search for semantic file finding |
| 📂 | Flexible Library Scope | Scope to a subfolder or access the entire library root |
| 🔁 | Auto-Retry | Exponential backoff on SharePoint 429/503 throttling |
| 🚀 | Dual Transport | stdio for desktop · http for Docker/remote |
| 🪵 | Structured Logging | JSON in production · coloured console in dev |
| 🐳 | Docker-Ready | Single command: docker compose up -d |
| 🛡️ | Non-Root Container | Runs as unprivileged user inside Docker |
| 🩺 | Health Check | Live /health endpoint with real SharePoint check |
| 🤖 | CI/CD | Tested on Python 3.10 · 3.11 · 3.12 · 3.13 |
---
⚡ Quickstart
1️⃣ Install
pip install sharepoint-mcp
Or from source:
git clone https://github.com/ravikant1918/sharepoint-mcp.git
cd sharepoint-mcp && pip install -e .
2️⃣ Configure
```bash
cp .env.example .env
Sign in to leave a review
Use Google, GitHub, or an email account so ratings stay tied to real people.
No reviews posted yet.



