Microsoft Planner MCP 标志

Microsoft Planner MCP

组织
aixolotl

Unofficial MCP server for Microsoft Planner using Microsoft Graph and Entra ID delegated authentication

发布者aixolotl
代码仓库microsoft-planner-mcp
语言Python
复刻数
4
星标数
11
可用工具
0
传输类型stdio
分类
许可协议MIT
链接
  • 将工具接入 AI 工作流

    Microsoft Planner MCP 提供 MCP 功能,可供兼容的 AI 客户端和智能体使用。

  • 0 个可用工具

    浏览下方可调用的操作;如果服务器提供了名称和描述,也会一并显示。

  • 可直接复制的配置

    使用安装配置片段,在您首选的 MCP 客户端中配置此服务器。

  • 开源社区热度

    关联的代码仓库有 11 个星标和 4 个复刻。

MCP Server for Microsoft Planner

An unofficial MCP server that connects AI assistants to Microsoft Planner. Ask your AI assistant to create tasks, organise plans, manage buckets, and more, all through natural language.

This is an unofficial, community/open-source MCP server for Microsoft Planner.
It is not affiliated with, endorsed by, or sponsored by Microsoft.

Built with FastMCP and authenticated via Microsoft Entra ID (Azure AD) using the On-Behalf-Of (OBO) flow to call Microsoft Graph.

Table of Contents

What Can It Do?

Once connected, you can ask your AI assistant things like:

  • "Show me all my Planner tasks that are overdue"
  • "Create a task called 'Prepare Q3 report' in the Marketing plan"
  • "Move all incomplete tasks in the Sprint bucket to the Backlog bucket"
  • "Mark the 'Update docs' task as complete"

The AI assistant translates your request into the appropriate tool calls automatically.

Note: This MCP only supports Planner basic tasks and plans

Prerequisites

  • A Microsoft 365 account with access to Microsoft Planner
  • An Azure Entra ID (Azure AD) app registration (see Azure Setup below)
  • An MCP-compatible client — for example:

To run the server locally you also need:

Or, to run via Docker:

Azure Entra ID Setup

An Azure app registration is required so the server can authenticate users and call Microsoft Graph on their behalf. You need admin access to an Azure Entra ID tenant (or ask your IT administrator).

Step 1 — Register the Application

  1. Go to the Azure Portal → Microsoft Entra ID → App registrations → New registration
  2. Enter a name (e.g. Microsoft Planner MCP)
  3. Under Supported account types, choose the option appropriate for your organisation
  4. Set the Redirect URI to Web → http://localhost:8000/auth/callback
  5. Click Register

Step 2 — Configure API Permissions

  1. In your new app registration, go to API permissions → Add a permission → Microsoft Graph → Delegated permissions
  2. Add these permissions:
    • Tasks.ReadWrite — read and write Planner tasks
    • User.Read — read the signed-in user's profile
    • User.ReadBasic.All — resolve user display names from the GUIDs in task assignments (required only for list_users tool)
  3. Click Grant admin consent for your organisation

Step 3 — Expose an API Scope

  1. Go to Expose an API
  2. Set the Application ID URI (accept the default api://<client-id> or customise it)
  3. Click Add a scope:
    • Scope name: mcp-access
    • Who can consent: Admins and users (or Admins only if you prefer)
    • Fill in the display name and description
    • Set state to Enabled

Step 4 — Set Token Version

  1. Go to Manifest (or Authentication → Advanced settings in newer portal versions)
  2. Set "requestedAccessTokenVersion" to 2
  3. Save

Step 5 — Create a Client Secret

  1. Go to Certificates & secrets → New client secret
  2. Add a description and choose an expiry period
  3. Copy the Value immediately (it is only shown once)

Step 6 — Note Your IDs

You will need these three values for configuration:

ValueWhere to Find It
Application (client) IDApp registration → Overview
Directory (tenant) IDApp registration → Overview
Client secretThe value copied in Step 5

Installation

Option A — Local (Python + uv)

bash
git clone https://github.com/aixolotl/microsoft-planner-mcp
cd microsoft-planner-mcp
uv sync

Option B — Docker

No Python installation needed. See Running with Docker below.

Configuration

Copy the example environment file and fill in your Azure credentials:

bash
cp .env.example .env

Edit .env:

ini
# Azure App Registration (required)
CLIENT_ID=your-app-client-id
CLIENT_SECRET=your-app-client-secret
TENANT_ID=your-azure-tenant-id

# Public URL of this server (used for OAuth redirect URI)
BASE_URL=http://localhost:8000

# JSON-encoded list of allowed CORS origins
# Include http://localhost:6274 if using MCP Inspector for testing
ALLOWED_ORIGINS=["http://localhost:8000","http://localhost:6274"]

# Require FastMCP's extra client consent prompt per MCP client. (default: true)
# Prevents confused-deputy attacks by requiring users to explicitly approve each new
# client. Keep true in production; set false only for local dev with throwaway
# clients.
# REQUIRE_AUTHORIZATION_CONSENT=true

# Optional rate-limit overrides (per client sliding window)
# Defaults are 120 requests per 1 minute
# RATE_LIMIT_MAX_REQUESTS=120
# RATE_LIMIT_WINDOW_MINUTES=1

REQUIRE_AUTHORIZATION_CONSENT controls whether FastMCP prompts users to explicitly approve each new MCP client. Keep this true (default) in production to prevent confused-deputy attacks; set it to false only during local development with throwaway clients.

RATE_LIMIT_MAX_REQUESTS and RATE_LIMIT_WINDOW_MINUTES are optional and should stay commented out unless you need to override the defaults for your environment.

Running the Server

Local

bash
uv run uvicorn src.server:app --host 0.0.0.0 --port 8000

The MCP endpoint is available at http://localhost:8000/mcp. A health check endpoint is at http://localhost:8000/health.

Running with Docker

bash
# Pull the latest image
docker pull ghcr.io/aixolotl/microsoft-planner-mcp:latest

# Run with environment variables
docker run --rm -i \
  -e BASE_URL=https://localhost:8000 \
  -e CLIENT_ID=your_client_id \
  -e CLIENT_SECRET=your_api_token \
  -e TENANT_ID=your_tenant_id \
  -e ALLOWED_ORIGINS=["http://localhost:8000","http://localhost:6274", "http://localhost:3000"] \
  -e REQUIRE_AUTHORIZATION_CONSENT=true \
  ghcr.io/aixolotl/microsoft-planner-mcp:latest

This starts the MCP server on port 8000. To override rate limits, also pass -e RATE_LIMIT_MAX_REQUESTS=<value> and -e RATE_LIMIT_WINDOW_MINUTES=<minutes> (defaults: 120 and 1).

Running with Docker compose

bash
docker compose up

This starts the MCP server on port 8000. The Docker Compose configuration also includes a Jaeger instance for trace visualisation (see OpenTelemetry Tracing).

Connecting an MCP Client

Once the server is running, configure your MCP client to connect to it.

VS Code

Add the following to your VS Code settings (.vscode/settings.json in your project, or your user settings):

json
{
  "mcp": {
    "servers": {
      "planner": {
        "type": "http",
        "url": "http://localhost:8000/mcp"
      }
    }
  }
}

Then use Copilot Chat in Agent mode and ask it to interact with your Planner tasks. Copilot will discover the available tools automatically.

Other MCP Clients

Any client that supports the Streamable HTTP transport can connect by pointing to http://localhost:8000/mcp. The server advertises OAuth metadata automatically — the client handles the authentication flow.

Available Tools

All tools are available to your AI assistant automatically once connected. You don't need to call them directly — just describe what you want in natural language. The parameter details below are provided for reference and for client developers.

Read-only tools are annotated with readOnlyHint: true so clients can skip confirmation prompts. Destructive tools (deletes) are annotated with destructiveHint: true.

User

get_me

Return the authenticated user's profile from Microsoft Graph.

  • Parameters: None
  • Returns: User profile object (id, displayName, mail, etc.) or null

list_users

Retrieve Microsoft 365 users by GUID, e-mail address, or free-text search. Useful for resolving the user GUIDs returned in task assignment objects to display names.

ParameterTypeRequiredDescription
selectstringNoComma-separated fields to include (default: id,displayName,mail,userPrincipalName). Pass *all for all fields.
searchstringNoFree text search on display name, or search by field name and value, e.g. Alice or surname:Smith
guidslist[string]NoUser object GUIDs to look up. Translated to an OData $filter expression.
emailslist[string]NoUser principal names (UPNs / e-mail addresses) to look up. Translated to an OData $filter expression.
topintegerNoMaximum number of users to return (default: 10). Ignored when guids or emails are provided.
  • Returns: List of user objects or null

Note: When both guids/emails and search are supplied, the GUID/email filter takes priority. Very large lists of GUIDs or e-mail addresses are silently truncated to stay within the 2 048-character Graph URL limit.

Groups

list_my_groups

List all Microsoft 365 groups the authenticated user is a member of.

ParameterTypeRequiredDescription
selectstringNoComma-separated fields to include (default: id,displayName,mail). Pass *all for all fields.
filterstringNoOData filter expression, e.g. startsWith(displayName,'Project')
searchstringNoOData search string, e.g. "displayName:Project"
  • Returns: List of group objects or null

Note: The Groups tool will not return details like name or mail of groups with the standard permissions Tasks.ReadWrite documented here, however searching and filtering still works, so you can find a group with a specific name using this tool.

Plans

list_my_plans

List Planner plans shared with the authenticated user.

ParameterTypeRequiredDescription
selectstringNoComma-separated fields to include (default: id,title,owner,createdBy,createdDateTime). Pass *all for all fields.
  • Returns: List of plan objects or null

list_group_plans

List all Planner plans belonging to a Microsoft 365 group.

ParameterTypeRequiredDescription
groupIdstringYesThe object ID of the group (from list_my_groups)
selectstringNoComma-separated fields to include (default: id,title,owner,createdBy,createdDateTime). Pass *all for all fields.
  • Returns: List of plan objects or null

create_plan

Create a new Planner plan for a Microsoft 365 group.

ParameterTypeRequiredDescription
groupIdstringYesThe object ID of the M365 group that will own the plan
titlestringYesDisplay title for the new plan
  • Returns: The created plan object or null

delete_plan

Delete a Planner plan.

ParameterTypeRequiredDescription
planIdstringYesThe ID of the plan to delete
etagstringYesThe current @odata.etag of the plan (retries once if stale)
  • Returns: Confirmation message

list_plan_categories

Get category label definitions for a Planner plan. Returns all 25 category slots with their key (e.g. category1) and display name.

ParameterTypeRequiredDescription
planIdstringYesThe ID of the plan
  • Returns: List of category objects (key, display_name) or null

Buckets

list_buckets

List all buckets in a Planner plan.

ParameterTypeRequiredDescription
planIdstringYesThe ID of the plan
  • Returns: List of bucket objects or null

create_bucket

Create a new bucket in a Planner plan.

ParameterTypeRequiredDescription
planIdstringYesThe ID of the plan to create the bucket in
namestringYesDisplay name for the new bucket
  • Returns: The created bucket object or null

delete_bucket

Delete a Planner bucket.

ParameterTypeRequiredDescription
bucketIdstringYesThe ID of the bucket to delete
etagstringYesThe current @odata.etag of the bucket (retries once if stale)
  • Returns: Confirmation message

Tasks

list_my_tasks

List all Planner tasks assigned to the authenticated user across all plans.

ParameterTypeRequiredDescription
selectstringNoComma-separated fields to include (default: *all). Pass *all for all fields.
filterstringNoOData filter expression, e.g. percentComplete ne 100
searchstringNoFree-text search matched against the task title
  • Returns: List of task objects or null

list_tasks

List all tasks in a Planner plan.

ParameterTypeRequiredDescription
planIdstringYesThe ID of the plan
selectstringNoComma-separated fields to include (default: *all). Pass *all for all fields.
filterstringNoOData filter expression, e.g. percentComplete eq 0
searchstringNoFree-text search matched against the task title
  • Returns: List of task objects or null

get_task_details

Get the full details for a task: description, checklist items, and external references.

ParameterTypeRequiredDescription
taskIdstringYesThe ID of the task
  • Returns: Task details object (description, checklist, references) or null

create_task

Create a new task in a Planner plan.

ParameterTypeRequiredDescription
planIdstringYesThe ID of the plan
bucketIdstringYesThe ID of the bucket to place the task in
titlestringYesTitle of the task
startDateTimestringNoISO 8601 start date (e.g. 2026-05-01T00:00:00)
dueDateTimestringNoISO 8601 due date (e.g. 2026-05-31T00:00:00)
percentCompleteintegerNoCompletion percentage, 0–100
assignUserIdslist[string]NoUser object IDs to assign to the task
  • Returns: The created task object or null

update_task

Update a task's standard fields and/or detail fields (description, checklist, references). Only provided fields are changed. When detail fields are specified, a separate API call updates the task details resource automatically.

ParameterTypeRequiredDescription
taskIdstringYesThe ID of the task
etagstringYesThe current @odata.etag of the task (retries once if stale)
titlestringNoNew title
percentCompleteintegerNoCompletion percentage, 0–100
dueDateTimestringNoISO 8601 due date
bucketIdstringNoID of the bucket to move the task to
priorityintegerNoPriority 0 (urgent)–10 (low). Planner maps: 1=urgent, 3=important, 5=medium, 9=low
assigneePrioritystringNoOrder hint for sorting within the assignee's task list
appliedCategoriesobjectNoCategories keyed by category slot (e.g. {"category3": true}). Use list_plan_categories for label names
assignUserIdslist[string]NoUser IDs to assign
unassignUserIdslist[string]NoUser IDs to remove
descriptionstringNoPlain-text description (up to 2000 characters) — detail field
previewTypestringNoPreview style: automatic, noPreview, checklist, description, or reference — detail field
checklistItemsobjectNoDict keyed by checklist item GUID. Pass null for a key to delete that item — detail field
referencesobjectNoDict keyed by URL-encoded reference URL. Pass null for a key to delete that reference — detail field
etagDetailsstringNoThe @odata.etag of the task details resource. Required only when updating detail fields; auto-refreshed from Graph if omitted.
  • Returns: The updated task object, the updated task details object, or both ({ "task": ..., "details": ... }) depending on which fields were provided. Returns null if the result is empty.

Note: The update_task_details tool has been removed. Use update_task with detail field parameters (description, checklistItems, references, previewType) instead. The task and details resources have separate ETags — provide etagDetails when available to avoid an extra round-trip, or omit it to let the tool auto-refresh.

list_task_fields

Return metadata for every field on a Planner task, including its data type, description, whether it is writable, and whether it requires a separate get_task_details call.

  • Parameters: None
  • Returns: List of field metadata objects (name, type, description, writable, detailed)

Note: The list of fields is static as Planner Standard doesn't support custom fields. But this endpoint awaits Microsoft's future updates to the API to fully support Planner Premium.

delete_task

Delete a Planner task.

ParameterTypeRequiredDescription
taskIdstringYesThe ID of the task
etagstringYesThe current @odata.etag of the task (retries once if stale)
  • Returns: Confirmation message

Development

This section covers building, testing, and contributing to the project.

Project Structure

src/
├── server.py                  # FastMCP app, middleware, route mounting
├── config.py                  # Settings via pydantic-settings
├── auth_provider.py           # Azure OAuth provider (OBO flow)
├── deps.py                    # Shared dependency helpers
├── graph_client_manager.py    # Singleton GraphClientManager with per-user OBO clients
├── telemetry.py               # OpenTelemetry setup
├── types.py                   # Shared structural types
├── services/
│   └── planner_service.py     # Business logic wrapping Graph SDK calls
└── tools/
    ├── me.py                  # get_me
    ├── groups.py              # list_my_groups
    ├── plans.py               # plan tools + list_plan_categories
    ├── tasks.py               # task tools + list_task_fields
    └── buckets.py             # bucket tools
tests/
├── conftest.py
├── test_buckets_tool.py
├── test_groups_tool.py
├── test_planner_service.py
├── test_plans_tool.py
└── test_tasks_tool.py

Installing Dev Dependencies

bash
uv sync --dev

Running Tests

bash
uv run pytest

With verbose output:

bash
uv run pytest -v

Architecture

The server is built with FastMCP and uses these key patterns:

Server composition — Tools are split into five domain routers (me, groups, plans, tasks, buckets), each a standalone FastMCP instance mounted on the main app. This keeps each domain's tools, imports, and tests isolated.

Authentication — The server uses FastMCP's OAuthProxy pattern via a custom AzureProvider. Azure Entra ID does not support Dynamic Client Registration (DCR), so the provider acts as a DCR-compliant proxy facing MCP clients while using the pre-registered app credentials with Azure. When a tool call arrives, the server exchanges the MCP session token for a Microsoft Graph token via the On-Behalf-Of flow, scoped to Tasks.ReadWrite and User.Read.

Middleware — Five built-in middleware layers are stacked on the server (outermost first):

MiddlewarePurpose
ErrorHandlingMiddlewareCatches unhandled exceptions, logs full traces server-side, returns clean MCP errors
SlidingWindowRateLimitingMiddleware60 req/min per client to protect the Microsoft Graph quota
TimingMiddlewareRecords wall-clock duration for every MCP operation
StructuredLoggingMiddlewareEmits one JSON log line per request (method, status, duration, client info)
ResponseLimitingMiddlewareTruncates tool responses above 500 KB to prevent overflowing LLM context windows

Client logging — Every tool sends real-time progress messages to the MCP client via get_optional_context(), so users see status updates like "Fetching tasks…" and "Found 12 task(s)" in their client.

OpenTelemetry Tracing

The server includes native OpenTelemetry instrumentation with zero overhead when unused. To enable trace export:

bash
# Install the optional OTEL dependency group
uv sync --group otel

# Set the OTLP endpoint and start the server
export OTEL_EXPORTER_OTLP_ENDPOINT=http://localhost:4317
export OTEL_SERVICE_NAME=microsoft-planner-mcp
uv run uvicorn src.server:app --host 0.0.0.0 --port 8000

Traces follow the MCP semantic conventions and work with any OTLP-compatible backend (Jaeger, Grafana Tempo, Datadog, New Relic, etc.). The Docker Compose setup includes Jaeger with a UI at http://localhost:16686.

Testing with MCP Inspector

MCP Inspector lets you test tools interactively in a browser:

  1. Start the server:

    bash
    uv run uvicorn src.server:app --host 0.0.0.0 --port 8000
  2. In a separate terminal:

    bash
    npx @modelcontextprotocol/inspector
  3. Open the URL printed in the terminal (e.g. http://localhost:6274/?MCP_PROXY_AUTH_TOKEN=...)

  4. Set Transport Type to Streamable HTTP and URL to http://localhost:8000/mcp, then click Connect.

Contributing

Contributions are welcome! Please open an issue or submit a pull request. See the issue templates for bug reports, feature requests, and tasks.

License

This project is licensed under the MIT License.

将 Microsoft Planner MCP MCP 与多个 AI 模型配合使用

TypingMind 在工作区级别连接 MCP 工具,因此连接 Microsoft Planner MCP 后,您就可以在 TypingMind 中搭配不同的 AI 模型使用,无需为每个模型单独设置。 此 MCP 通过您设备上的 TypingMind MCP 连接器在本地运行。

本地连接器设置指南

如果 MCP 服务器需要访问您电脑上的本地文件、应用或私有资源,请选择此方式。

1

打开 MCP 设置

在 TypingMind 中,依次前往“设置”、“高级设置”和“模型上下文协议”,然后选择“设置连接器”。

  1. 在您的浏览器中打开 TypingMind。
  2. 点击“设置”图标。
  3. 进入“高级设置”。
  4. 打开“模型上下文协议”部分。
  5. 点击“设置连接器”,然后选择“此设备”。
TypingMind MCP 连接器设置界面,已选择“此设备”
2

运行连接器命令

选择“此设备”,从 TypingMind 复制命令并在终端中运行。使用 MCP 时,请保持该进程运行。

  1. 复制 TypingMind 显示的设置命令。
  2. 在 macOS 上打开“终端”,或在 Windows 上打开 Windows Terminal。
  3. 粘贴并运行命令。
  4. 如果终端询问您是否继续,请确认安装软件包。
  5. 使用 MCP 工具时,请勿关闭终端窗口或停止其中的连接器进程。
3

将 Microsoft Planner MCP 添加为服务器

当连接器状态为“就绪”时,点击“编辑服务器”,然后粘贴 MCP 服务器配置。

  1. 等待连接器状态显示为“就绪”。
  2. 点击“编辑服务器”。
  3. 粘贴 Microsoft Planner MCP MCP 服务器配置。
  4. 保存服务器列表。
  5. 如需确认连接器是否仍处于就绪状态,请刷新。
TypingMind MCP 设置界面,显示正在运行的服务器和“编辑服务器”按钮
{
  "mcpServers": {
    "microsoft-planner-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "<mcp-server-package>"
      ]
    }
  }
}
4

在不同模型中使用同一连接

保存服务器列表,打开“插件”,启用 Microsoft Planner MCP MCP 工具,然后在 TypingMind 中选择任意受支持的 AI 模型,即可在聊天中使用这些工具,或将其分配给智能体。

  1. 在 TypingMind 中打开“插件”页面。
  2. 启用 Microsoft Planner MCP MCP 工具。
  3. 开始聊天并选择您想使用的 AI 模型。
  4. 在聊天中使用 MCP 工具,或将其分配给 AI 智能体。
  5. 根据需要随时切换到其他 AI 模型,无需重新连接 MCP。
在 TypingMind 聊天中使用已启用的 MCP 工具和选定的 AI 模型
您能使用 Microsoft Planner MCP 帮我完成这项任务吗?
Microsoft Planner MCP
当然,我看过了。
以下是我使用 Microsoft Planner MCP 得到的结果。

常见问题

Microsoft Planner MCP MCP 服务器有什么用途?

Microsoft Planner MCP 是一个 MCP 服务器,可让兼容的 AI 客户端连接外部工具并获取上下文。在 TypingMind 中,只需添加一次此 MCP 服务器,即可在您的 AI 工作区中使用其工具。

可以在 TypingMind 中让多个 AI 模型使用 Microsoft Planner MCP MCP 吗?

可以。TypingMind 在工作区层面连接 MCP 工具,因此您无需为每个模型单独配置 MCP 服务器,就能在 Claude、ChatGPT、Gemini 或您在 TypingMind 中配置的其他 AI 模型中使用 Microsoft Planner MCP。

为什么在 TypingMind 中使用 Microsoft Planner MCP MCP?

TypingMind 将多个 AI 模型、提示词、插件、AI 智能体、API 密钥和 MCP 工具整合到同一个工作区中,是最出色的大语言模型聊天前端之一。连接 Microsoft Planner MCP 后,您可以在偏好的不同模型中使用其 MCP 工具,同时在 TypingMind 中井然有序地管理聊天工作流程。

如何将 Microsoft Planner MCP MCP 连接到 TypingMind?

Microsoft Planner MCP 通过 TypingMind 本地 MCP 连接器运行。当 MCP 服务器需要访问您计算机上的本地文件、桌面应用、命令行工具或私有资源时,这种方式最合适。

Microsoft Planner MCP MCP 在 TypingMind 中提供哪些工具?

Microsoft Planner MCP 提供 MCP 功能,您可以在 TypingMind 的插件页面启用这些功能,然后在聊天中使用,或将其分配给 AI 智能体。

使用 Microsoft Planner MCP MCP 需要向 TypingMind 提供我的 API 密钥吗?

不需要。TypingMind 采用本地优先的设计,让您自行选择模型提供商,并自行管理 API 密钥、提示词和 MCP 配置。如果 Microsoft Planner MCP 需要身份验证,请在创建连接时,为该 MCP 服务器添加所需的请求头、OAuth 设置或本地配置。

相关 MCP 服务器

查看全部

立即创建您自己的 AI 工作区

订阅我们的电子简报,获取新功能和后续赠奖活动的通知 👇