modelcontextprotocol / modelcontextprotocol/php-sdk
[Server] SEP-2663 Tasks: TasksExtension, capability gate, tasks/* handlers
オープン
まだ誰も着手していません。
2026-07-28
enhancement
improves spec compliance
needs design
Server
- 主要言語
- PHP
- スター
- 1.6k
- フォーク
- 173
- 平均マージ
- 2日 49分
- マージ済み PR(30日)
- 23
説明
Server-side handler portion of SEP-2663 for the 2026-07-28 release. Tracked by umbrella #335; sits on the SEP-2133 extensions framework (#344).
Scope
Mcp\Server\Task\TasksExtensionimplementsMethodProvidingExtensionInterfaceandArgumentProvidingExtensionInterface(new, generic: an extension registers its message classes, handlers and injectable handler arguments throughBuilder::enableExtension(); the core never names the extension). Enable withnew TasksExtension($store, $inputHandler)and thetasks/get/tasks/update/tasks/cancelsurface appears; no separatesetTaskStore()builder knob.- Handlers under
Mcp\Server\Task\Handler\:TasksGetHandler,TasksUpdateHandler,TasksCancelHandler. - Capability gate:
TaskCapabilityGuardreads whatinitializeleft in the session and refuses thetasks/*methods with-32021(missing required client capability) for a client that did not declare the extension. - Handlers get a
TaskContextby declaring the parameter:isSupported()so a handler that can work either way asks first,create()stores the task before returning theCreateTaskResult(so the firsttasks/getcannot arrive before the task exists) and refuses an undeclared client with-32021,getStore().
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
#344 の SEP-2133 extensions framework と Builder::enableExtension() のパスから始め、次に Mcp\Server\Task\Handler\ 配下の TasksExtension とハンドラーを調べます。TaskCapabilityGuard と TaskContext を追跡し、宣言されたクライアントのチェック、タスク作成の順序、ストアへのアクセスを検証します。tasks/* のサーフェスが TasksExtension を通じて登録され、クライアント capability がない場合に仕様どおり -32021 を返せば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- php
- 領域
- api, backend
- issue の種類
- 機能追加
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 静か
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 55/100