excel-o365
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@excel-o365Create a workbook called Q3 Sales, add a worksheet, and create a table with the sample data."
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Excel Office 365 MCP Toolbox
Un servidor MCP (Model Context Protocol) desarrollado en Python con FastMCP para gestionar archivos de Microsoft Excel en Office 365 (OneDrive / SharePoint) a través de Microsoft Graph API.
🚀 Características
Crear libros de Excel (
.xlsx): Crea archivos nuevos en OneDrive o SharePoint.Listar libros de Excel: Explora y lista archivos
.xlsxen carpetas.Agregar hojas de trabajo: Añade nuevas pestañas a un libro existente.
Crear tablas: Convierte rangos en tablas estructuradas con encabezados.
Agregar filas a tablas: Inserta/añade nuevas filas de datos a una tabla de Excel.
Leer filas de tablas: Extrae encabezados y filas de una tabla existente.
Related MCP server: Aspose.Cells Cloud MCP Server
🏗️ Arquitectura de la Solución
El siguiente diagrama ilustra la arquitectura de componentes y el flujo de integración entre el servidor FastMCP en Python, Google Cloud Run, Microsoft Entra ID y Microsoft Graph API en Office 365:
flowchart TD
subgraph Server["⚡ Excel FastMCP Server (Python / FastMCP)"]
ServerCore["FastMCP Core (server.py)"]
subgraph Tools["🛠️ Herramientas MCP"]
WorkbooksTool["workbooks.py\n(excel_create_workbook, excel_list_workbooks)"]
SheetsTool["sheets.py\n(excel_add_worksheet)"]
TablesTool["tables.py\n(excel_create_table, excel_add_table_rows, excel_get_table_rows)"]
end
GraphClient["GraphExcelService (graph_client.py)\n- Plantilla In-Memory OpenXML XLSX\n- API Async REST Graph Client"]
AuthModule["Módulo de Autenticación (auth.py / config.py)\n- ClientSecretCredential (MSAL / Azure Identity)"]
end
subgraph CloudRunInfra["☁️ Infraestructura GCP (Cloud Run)"]
CloudRunService["Google Cloud Run (excel-mcp-toolbox)"]
SecretManager["GCP Secret Manager\n(MS_CLIENT_SECRET)"]
end
subgraph MS365["🏢 Microsoft 365 & Entra ID"]
EntraID["Microsoft Entra ID (Azure AD)\n- OAuth 2.0 Client Credentials"]
GraphAPI["Microsoft Graph API v1.0\n- /users/{target_email}/drive"]
Office365["OneDrive for Business / SharePoint"]
end
CloudRunService --> ServerCore
SecretManager -.->|"Inyecta MS_CLIENT_SECRET"| AuthModule
ServerCore --> Tools
Tools --> GraphClient
GraphClient --> AuthModule
AuthModule -->|"1. Solicita Token Bearer OAuth2"| EntraID
EntraID -->|"2. Token de Acceso (Files.ReadWrite.All)"| AuthModule
GraphClient -->|"3. Peticiones REST HTTPS"| GraphAPI
GraphAPI -->|"4. Persistencia de Libros (.xlsx)"| Office365
style Server fill:#e6f4ea,stroke:#34a853,stroke-width:2px
style Tools fill:#ffffff,stroke:#34a853,stroke-width:1px
style CloudRunInfra fill:#e8f0fe,stroke:#4285f4,stroke-width:2px
style MS365 fill:#fef7e0,stroke:#fbbc04,stroke-width:2pxComponentes de la Arquitectura
Servidor FastMCP (
excel-mcp-toolbox):server.py: Punto de entrada que inicializa el servidor FastMCP e integra los módulos de herramientas.tools/: Expone las 6 herramientas atómicas con parámetros simplificados (strpara listas y filas) y respuestas formateadas en JSON explícito.graph_client.py: Servicio asíncrono que genera la estructura OpenXML de un.xlsxen memoria mediantezipfiley realiza llamadas REST HTTPS a Microsoft Graph API.auth.py&config.py: Gestión de credenciales mediantepydantic-settingsy autenticación OAuth 2.0 App-Only (ClientSecretCredential).
Infraestructura en GCP (Cloud Run & Secret Manager):
Cloud Run: Ejecuta el contenedor del servidor en un entorno serverless ligero (base
python:3.11-slim).Secret Manager: Almacena de forma segura la credencial sensible
MS_CLIENT_SECRET, inyectándola al contenedor en tiempo de ejecución.
Microsoft 365 & Entra ID (Azure AD):
Entra ID: Otorga permisos de aplicación
Files.ReadWrite.Allpara interactuar con OneDrive/SharePoint del usuario destino (TARGET_USER_EMAIL).Microsoft Graph API: Procesa las operaciones de creación de archivos, pestañas, tablas y formateo de datos.
🛠️ Requisitos Previos
Python 3.11+
uv (Gestor de paquetes de Python)
Registro de Aplicación en Microsoft Entra ID (Azure AD) con permisos
Files.ReadWriteoFiles.ReadWrite.All.
📦 Configuración e Instalación
Clonar e instalar dependencias:
uv venv .venv source .venv/bin/activate uv pip install -e .Configurar variables de entorno (
.env): Copia.env.examplea.envy completa tus credenciales de Azure AD:cp .env.example .envEdita
.env:MS_TENANT_ID=tu-tenant-id MS_CLIENT_ID=tu-client-id MS_CLIENT_SECRET=tu-client-secret DEFAULT_DRIVE_TYPE=onedrive
🚦 Uso con Clientes MCP (Cursor, Claude Desktop, Antigravity)
Agrega la configuración del servidor a la sección de MCP servers de tu cliente:
{
"mcpServers": {
"excel-o365": {
"command": "uv",
"args": [
"--directory",
"/ruta/a/excel-mcp-toolbox",
"run",
"excel-mcp"
]
}
}
}🧪 Pruebas
Para ejecutar la suite de pruebas unitarias:
uv run pytest☁️ Despliegue en Google Cloud Run
Este proyecto incluye soporte nativo para ejecutarse como un servicio de contenedor HTTP con Streamable HTTP (streamable-http) en Google Cloud Run.
1. Variables de Configuración
Proyecto GCP:
tu-proyecto-gcpRegión:
us-central1Artifact Registry:
containersSecret Manager:
excel-mcp-client-secretServicio Cloud Run:
excel-mcp-toolbox
2. Pasos de Despliegue Manuales con gcloud
Guardar el secreto sensible en Secret Manager:
gcloud secrets create excel-mcp-client-secret \ --replication-policy="automatic" \ --project="tu-proyecto-gcp" echo -n "TU_MS_CLIENT_SECRET" | gcloud secrets versions add excel-mcp-client-secret \ --data-file=- \ --project="tu-proyecto-gcp"Compilar la imagen del contenedor con Cloud Build:
gcloud builds submit \ --tag us-central1-docker.pkg.dev/tu-proyecto-gcp/containers/excel-mcp-toolbox:latest \ --project="tu-proyecto-gcp"Desplegar en Cloud Run:
gcloud run deploy excel-mcp-toolbox \ --image us-central1-docker.pkg.dev/tu-proyecto-gcp/containers/excel-mcp-toolbox:latest \ --region us-central1 \ --project tu-proyecto-gcp \ --no-allow-unauthenticated \ --port 8080 \ --set-env-vars MS_TENANT_ID="tu-tenant-id",MS_CLIENT_ID="tu-client-id",TARGET_USER_EMAIL="usuario@tu-empresa.com" \ --set-secrets MS_CLIENT_SECRET=excel-mcp-client-secret:latest
3. Despliegue Automatizado
También puedes ejecutar el script ejecutable ./deploy.sh cargando las variables desde tu archivo .env:
./deploy.sh📄 Licencia
Este proyecto está licenciado bajo los términos de la Licencia Apache 2.0. Consulta el archivo LICENSE para más información.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.
No tool schema history has been recorded yet.
This server cannot be installed
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Generate, edit, merge, translate and PDF-convert PowerPoint (.pptx) over MCP. 8 tools.
OneDrive (Microsoft Graph) MCP Pack
Manage Microsoft 365 email, calendar, contacts and inbox rules via the Graph API with OAuth 2.0.
AXL MCP lets AI assistants create and manage landing pages, courses, email campaigns, CRM records, and marketing workflows inside AXL. Built for growing expert businesses, it turns chat requests into real work across sales, marketing, and course delivery. An AXL account is required. Sign in securely with OAuth 2.1. Website: https://axl.tech/developers/mcp . Setup guide: https://docs.axl.tech/mcp . Watch AXL in 77 seconds: pages, courses, CRM, and automation. Product overview: https://www.youtube.com/watch?v=jlhR9CafIww
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceEnables reading and writing Excel files (text, formulas, and images on Windows) via MCP tools with pagination support.3MIT
- AlicenseCqualityCmaintenanceAutomates Microsoft Excel spreadsheet creation and editing via MCP tools for any MCP-compatible client.37MIT
- AlicenseAqualityDmaintenanceEnables reading and writing Excel workbooks (.xlsx) through MCP. Supports listing sheets, tables, pivot tables, reading cell data, exporting to CSV/text/Markdown, and creating/modifying Excel files.14GPL 3.0
- FlicenseNot gradedqualityAmaintenanceMCP server that integrates with OneDrive and Excel Workbooks via Microsoft Graph API for creating and modifying worksheets.-
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/johburn/mcp_excel_toolbox'
If you have feedback or need assistance with the MCP directory API, please join our Discord server