Lokka (Microsoft 365)
Lokka ia an MCP server for the Microsoft Graph API and can be used to query and update all resources in your Microsoft 365 tenant. This MCP server supports all Microsoft Graph APIs including update operations (limited by the permissions you grant to
What is Lokka (Microsoft 365)?
Lokka (Microsoft 365) is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to lokka ia an mcp server for the microsoft graph api and can be used to query and update all resources in your microsoft 365 tenant. this mcp server supports all microsoft graph apis including update op...
Lokka ia an MCP server for the Microsoft Graph API and can be used to query and update all resources in your Microsoft 365 tenant. This MCP server supports all Microsoft Graph APIs including update operations (limited by the permissions you grant to
This server falls under the Business Applications category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- Lokka ia an MCP server for the Microsoft Graph API and can b
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx lokka-microsoft-365-mcp-serverConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use Lokka (Microsoft 365)
Lokka is a full-featured MCP server for the Microsoft Graph API and Azure Resource Manager, enabling AI assistants to query and update any Microsoft 365 or Azure resource in your tenant. It supports all Graph API endpoints — users, groups, mail, calendar, Teams, SharePoint, Intune, Entra ID, and more — with both read and write operations bounded only by the permissions you grant to the registered app. Developers and IT administrators who want to automate tenant management, reporting, or cross-service workflows through a conversational AI interface will find Lokka the most direct bridge between Claude and the Microsoft ecosystem.
Prerequisites
- Node.js 18 or newer installed
- A Microsoft 365 tenant with an account that can register Entra ID applications
- An Entra ID app registration with the appropriate Microsoft Graph API permissions for your use case
- TENANT_ID and CLIENT_ID from the app registration (plus CLIENT_SECRET or a certificate for app-only auth)
- An MCP client such as Claude Desktop or Cursor
Register an Entra ID application
In the Azure portal (portal.azure.com), go to Entra ID > App registrations > New registration. Note the Application (client) ID and Directory (tenant) ID. Under API permissions, add the Microsoft Graph delegated or application permissions your use case requires (e.g., User.Read, Mail.ReadWrite, Group.ReadWrite.All).
Create a client secret or upload a certificate
For app-only authentication (no user sign-in), generate a client secret under Certificates & Secrets, or upload a PEM certificate. For interactive (delegated) authentication you only need the tenant and client IDs — Lokka will prompt for user login.
Install Lokka via npm
Lokka is published as @merill/lokka on npm. You can run it directly with npx without a global install.
npx -y @merill/lokkaConfigure your MCP client
Add Lokka to your MCP client's configuration file. The example below uses app-only authentication with a client secret. For interactive login, set USE_INTERACTIVE to 'true' and omit CLIENT_SECRET.
{
"mcpServers": {
"Lokka-Microsoft": {
"command": "npx",
"args": ["-y", "@merill/lokka"],
"env": {
"TENANT_ID": "your-tenant-id",
"CLIENT_ID": "your-client-id",
"CLIENT_SECRET": "your-client-secret"
}
}
}
}Verify authentication and start querying
Restart your MCP client. Ask Claude to check the auth status, then try a simple Graph query to confirm the connection is working before attempting write operations.
Lokka (Microsoft 365) Examples
Client configuration
claude_desktop_config.json for Lokka using app-only authentication with a client secret.
{
"mcpServers": {
"Lokka-Microsoft": {
"command": "npx",
"args": ["-y", "@merill/lokka"],
"env": {
"TENANT_ID": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"CLIENT_ID": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"CLIENT_SECRET": "your-client-secret-here"
}
}
}
}Prompts to try
Example prompts that exercise Lokka's Microsoft Graph capabilities once connected.
- "List all users in my tenant who haven't signed in for more than 90 days."
- "Show me all Microsoft 365 Groups and their membership counts."
- "Find all Teams channels in the 'Engineering' team."
- "Get the last 10 emails in my inbox and summarize them."
- "List all conditional access policies in Entra ID."
- "What Intune compliance policies are currently assigned to the 'Sales' group?"Troubleshooting Lokka (Microsoft 365)
Authentication fails with 'AADSTS700016: Application not found in directory'
Verify that CLIENT_ID matches an app registration in the tenant specified by TENANT_ID. Multi-tenant apps must be consented in each tenant; single-tenant apps only work in the tenant where they were registered.
Graph API returns 403 Forbidden for certain operations
The app registration lacks the required Microsoft Graph permission for that operation. In the Azure portal go to your app's API Permissions, add the needed scope, and grant admin consent. Use USE_GRAPH_BETA=true if targeting beta endpoints not available in v1.0.
Interactive login prompt never appears
Set USE_INTERACTIVE=true in the env block and remove CLIENT_SECRET. Lokka will open a browser-based Entra ID login flow. Ensure your app registration has 'http://localhost' as a redirect URI under Authentication.
Frequently Asked Questions about Lokka (Microsoft 365)
What is Lokka (Microsoft 365)?
Lokka (Microsoft 365) is a Model Context Protocol (MCP) server that lokka ia an mcp server for the microsoft graph api and can be used to query and update all resources in your microsoft 365 tenant. this mcp server supports all microsoft graph apis including update operations (limited by the permissions you grant to It connects AI assistants to external tools and data sources through a standardized interface.
How do I install Lokka (Microsoft 365)?
Follow the installation instructions on the Lokka (Microsoft 365) GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with Lokka (Microsoft 365)?
Lokka (Microsoft 365) works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is Lokka (Microsoft 365) free to use?
Yes, Lokka (Microsoft 365) is open source and available under the MIT License license. You can use it freely in both personal and commercial projects.
Lokka (Microsoft 365) Alternatives — Similar Business Applications Servers
Looking for alternatives to Lokka (Microsoft 365)? Here are other popular business applications servers you can use with Claude, Cursor, and VS Code.
n8n
★ 189.1kA comprehensive MCP server that provides full control over n8n automation workflows through natural language. It offers 43 tools for managing workflows, executions, credentials, and data tables, with safety features like write-mode protection and dou
LobeHub
★ 77.5k🤯 LobeHub is your Chief Agent Operator, organizing your agents into 7×24 operations by hiring, scheduling, and reporting on your entire AI team.
Jeecgboot
★ 46.4kAI 低代码平台,「低代码 + 零代码」双模式驱动:低代码一键生成前后端代码,零代码 5 分钟搭建系统,AI Skills 一句话画流程、设计表单、生成整套系统。内置 AI聊天、知识库、流程编排、MCP插件等,兼容主流大模型。引领「AI 生成 → 在线配置 → 代码生成 → 手工合并->AI修改」开发模式,消除 Java 项目 80% 的重复工作,提效而不失灵活。
CowAgent
★ 44.7kCowAgent (chatgpt-on-wechat) 是基于大模型的超级AI助理,能主动思考和任务规划、访问操作系统和外部资源、创造和执行Skills、通过长期记忆和知识库不断成长,比OpenClaw更轻量和便捷。同时支持微信、飞书、钉钉、企微、QQ、公众号、网页等接入,可选择DeepSeek/OpenAI/Claude/Gemini/ MiniMax/Qwen/GLM/LinkAI,能处理文本、语音、图片和文件,可快速搭建个人AI助理和企业数字员工。
Minds Platform
★ 39.2kPlatform dedicated to building an open foundation for applied Artificial Intelligence, designed for people seeking production-ready AI systems they can truly control, extend and deploy anywhere.
Astrbot
★ 32.8kAI Agent Assistant & development framework that integrates lots of IM platforms, LLMs, plugins and AI feature, and can be your openclaw alternative. ✨
Browse More Business Applications MCP Servers
Explore all business applications servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up Lokka (Microsoft 365) in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use Lokka (Microsoft 365)?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.