PulseAugur
中
实时 10:28:22
English(EN) MCP Server in Node.js: What the v2 TypeScript SDK Changes

MCP Node.js SDK 更新至 v2,移除会话并简化更新

模型上下文协议 (MCP) 已发布其 Node.js TypeScript SDK 的重大更新,升级至 2.0 版本。新版本与 2026-07-28 MCP 规范保持一致,引入了主要变更,例如移除协议级会话以及引入单一更新流。SDK 已模块化为独立的服务器、客户端和适配器包,需要 Node.js 20+ 和 Zod 4。开发者可以使用 codemod 辅助从 v1 迁移到 v2,这包括将 `server.tool()` 替换为 `registerTool()`,并使用 `createMcpHandler()` 或 `serveStdio()` 来确保与新旧客户端的兼容性。 AI

影响 此次 SDK 更新简化了 MCP 服务器的开发,可能提高 Claude 等 AI 模型的集成效率。

排序理由 该条目描述了特定协议的 SDK 更新,包括其结构和用法变更,并提供了迁移指南。

在 dev.to — MCP tag 阅读 →

AI 生成摘要 · Google Gemini · 来自 1 个来源。 我们如何撰写摘要 →

MCP Node.js SDK 更新至 v2,移除会话并简化更新

本文如何被排名

Signal score
30 / 100
Composite score across the factors below. Higher = stronger signal that this story matters right now.
Newsworthiness bucket
Tool
该条目描述了特定协议的 SDK 更新,包括其结构和用法变更,并提供了迁移指南。
Source corroboration
Single-source cluster
Only one publisher covered this so far. Single-source stories can still rank when the publisher is high-authority, but they lack cross-source corroboration.
Topics
product, infra
Editorial topic classification. Feeds into how the story surfaces on /topic/<slug> hub pages and into the per-entity coverage mix.
AI-industry relevance
High
Clearly on-topic for AI-industry coverage.
Story freshness
Breaking (< 6h)
Fresh story with cross-source coverage still developing. Ranking may shift as more sources report.

完整方法见我们的编辑标准。

报道来源 [1]

  1. dev.to — MCP tag TIER_1 English(EN) · ExtensionBooster ·

    Node.js 中的 MCP 服务器:v2 TypeScript SDK 有哪些变化

    <p><em>Originally published on <a href="https://extenify.app/blog/mcp-server-node-js?ref=devto" rel="noopener noreferrer">Extenify</a>.</em></p> <p>If you build an MCP server in Node.js today, most tutorials you find will still show the v1 <code>@modelcontextprotocol/sdk</code> p…