quartz-sharepoint-mcp
Mirrors a SharePoint document library to disk and enables AI assistants to search it via natural language queries using opencode.
README
quartz-sharepoint-mcp
An MCP server that mirrors a SharePoint document library to disk and lets AI assistants search it via the Model Context Protocol.
How it works
- On startup, all files under your configured SharePoint path are downloaded locally.
- A background thread polls Microsoft Graph for changes every
POLL_INTERVALseconds, keeping the mirror in sync. - A single MCP tool —
search_sharepoint(query)— runsopencodeagainst the local files and returns the result.
SharePoint (Graph API) → local mirror → opencode → MCP client
Prerequisites
- Python 3.11+
opencodein yourPATH- An Azure AD App Registration with
Sites.Read.All(or equivalent) granted as an application permission
Setup
# 1. Install dependencies
pip install -r requirements.txt
# 2. Configure environment
cp .env.example .env
# Fill in your Azure and SharePoint credentials
# 3. Run
python server.py
The server starts on http://0.0.0.0:8001 by default.
Environment variables
| Variable | Required | Default | Description |
|---|---|---|---|
AZURE_TENANT_ID |
✓ | — | Azure AD tenant ID |
AZURE_CLIENT_ID |
✓ | — | App registration client ID |
AZURE_CLIENT_SECRET |
✓ | — | App registration client secret |
SHAREPOINT_HOSTNAME |
✓ | — | e.g. yourorg.sharepoint.com |
SHAREPOINT_SITE_PATH |
✓ | — | e.g. /sites/YourSite |
SHAREPOINT_ROOT_PATH |
✓ | — | Folder path within the site |
AUTH_TOKENS |
✓ | — | Bootstrap tokens: label:token,... |
ADMIN_USERNAME |
✓ | — | Admin panel username |
ADMIN_PASSWORD |
✓ | — | Admin panel password |
ADMIN_JWT_SECRET |
✓ | — | Secret for admin JWT signing |
Endpoints
| Path | Description |
|---|---|
GET / |
Admin UI (token management) |
POST /mcp |
MCP streamable-HTTP endpoint (bearer auth required) |
/admin/api/* |
Admin REST API |
MCP tool
search_sharepoint — accepts a natural-language query, runs it against the local mirror via opencode, and returns the answer as plain text.
To connect from an MCP client:
{
"mcpServers": {
"sharepoint": {
"url": "http://localhost:8001/mcp",
"headers": { "Authorization": "Bearer <your-token>" }
}
}
}
Admin panel
Visit http://localhost:8001 to manage bearer tokens — create, enable/disable, or revoke access without restarting the server.
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.