SharePoint Embedded Samples MCP
The AI/mcp-server MCP server gives an agent about 60 tools for containers, files and permissions in SharePoint Embedded.
- 108 ★ on the repository
- Last commit
- MIT
Broad access
Why this level
- The server deletes containers, changes permissions and overwrites files with Microsoft Entra application rights.
Install
- Works in
Manual install
Clone the repository, open `AI/mcp-server`, fill `.env` from `.env.example`, run `npm install` and `npm run dev`, then register `http://localhost:3000/mcp` as an MCP server and call `/health`.
Access and checks
How we reviewBroad accessThe tool can change data, run commands or handle secrets.
- The server deletes containers, changes permissions and overwrites files with Microsoft Entra application rights.
This is third-party code. Review the repository files before installing.
What it does
The Microsoft repository collects samples for SharePoint Embedded, a document storage API on Microsoft 365. For an agent the useful part is `AI/mcp-server`: a Node.js MCP server that talks to Microsoft Graph and exposes about 60 tools in four areas. Containers: create, list, lock, restore, permissions, properties and the recycle bin. Drives: metadata, browsing by path and change tracking. Files and folders: upload, download, move, copy, search, versions and preview links. Permissions on files and folders: grant, update and revoke. The server runs locally or deploys to Azure Container Apps with `deploy.sh`.
Who it is for. Developers of SharePoint Embedded apps who manage containers and files from Claude, Cursor or GitHub Copilot.
Good fit when
- An agent creates a container and uploads test documents for a new app.
- Files and versions are exported from a container to debug a problem.
- After an access model change the agent grants and revokes folder permissions.
- The interface needs a starting point: the repository ships React, TypeScript and ASP.NET Core boilerplates.
Not a fit when
- There is no Azure subscription or Entra ID app registration.
- Regular SharePoint Online libraries are needed rather than SharePoint Embedded.
- The server would be exposed to a network without protection: its tools can delete containers.
Example request
Create a container, upload three files into it and list the versions of one of them.MCP
- Transport
- http
- Authentication
- API key
Environment variables
TENANT_IDrequired- Entra ID directory (tenant) ID
APP_IDrequired- Registered app client ID
CLIENT_SECRETrequired, secret- App client secret
CONTAINER_TYPE_IDrequired- SharePoint Embedded container type ID
Limitations
Running it needs an Azure subscription, an Entra ID app registration, a SharePoint Embedded container type, Azure CLI and Node.js 22 or newer. The app gets the `FileStorageContainer.Selected` and `Files.ReadWrite.All` permissions with admin consent, and the client secret stays in `.env` out of source control. The server acts with application rights: its tools delete containers and change access. The other samples in the repository are learning starters for developers, not finished products.
How to disable. Remove the server entry from the MCP client settings, stop `npm run dev` and delete the deployed Azure app. Revoke the client secret in Entra ID.
FAQ
What is the server address?
Locally it is `http://localhost:3000/mcp`. After an Azure deployment `deploy.sh` prints the Streamable HTTP address and a legacy SSE address.
Which clients work?
The README covers Lovable, Claude, Cursor and GitHub Copilot. Any client that supports remote MCP servers fits.
What goes into `.env`?
The `TENANT_ID`, `APP_ID` and `CONTAINER_TYPE_ID` identifiers and the `CLIENT_SECRET` secret. `PORT` defaults to 3000.
How do I confirm the server works?
The request `curl http://localhost:3000/health` returns JSON with the `ok` status and the service version.
Where do I get the container type?
The `Get-SPOContainerType` command from the SharePoint Online PowerShell module lists them. Creating one is covered in the Microsoft SharePoint Embedded guide.
Discussion
No questions or reviews yet.
Related
MCP serversA local document base for your agent: hybrid semantic and keyword search plus a web UI for browsing and uploads
ONLYOFFICE DocSpace MCP: rooms and files in an agent
ONLYOFFICE Apps MCP Server
ONLYOFFICE's official MCP server: an agent manages rooms, folders, files and access rights in DocSpace through OAuth or an API key
An MCP server that turns PDF, DOCX, XLSX, PPTX, images, audio, web pages and YouTube transcripts into Markdown
An MCP server to create and edit Excel files without Microsoft Office: formulas, formatting, charts, pivot tables
PowerPoint MCP Server: decks on Windows
PowerPoint MCP Server
A PowerPoint MCP for Windows: the agent drives an installed PowerPoint, fills templates, inserts LaTeX equations and plots, and adds animations
A self-hosted MCP server for Google Drive, Docs, Sheets, Slides and Calendar: 130 tools and per-call account selection
README in short
The root README splits the repository into app samples, validation scripts, AI assets, Power Platform and tools. The `AI` folder matters for agents.