What this thread does
As of November 2026; checked 2026-11-05. The maintainers’ 2.4.0 notes, October 23, add opt-in OAuthClientProvider.scopeForRefresh(tokens) for providers such as Entra that reject refresh without scope (AADSTS90009), leaving the default request unchanged; 1.32.2 permits registration after connect() when the capability was declared.
The problem
Your TypeScript MCP implementation compiled before updating dependencies; now imports fail, tools disappear or remote clients cannot connect. Decide between maintaining the monolithic package temporarily and migrating the implementation.
Versions and status
| Line | Verified version, checked 2026-10-20 | Pick when |
|---|---|---|
@modelcontextprotocol/sdk | 1.32.2 (23 Oct 2026), npm and GitHub releases agree; re-read 2026-10-30 | You need a maintenance patch before scheduling migration |
@modelcontextprotocol/client / @modelcontextprotocol/server | 2.4.0 (23 Oct 2026), npm and GitHub agree; re-read 2026-10-30 | You can migrate and test the implementation together |
Sources fetched today: npm metadata, GitHub releases, README. The README calls the split line stable. Middleware packages have independent versions; do not assign the client version to all adapters.
What changed
- The migration guide, checked 2026-10-20, splits packages and adopts Standard Schema objects. Raw registration shapes have deprecated compatibility overloads; prefer
z.object(...). Zod 3 is unsupported;zod ^4.2.0is recommended (checked 2026-10-20). - Release 2.3.0 on 2026-10-02 (both checked 2026-10-20) changes stateless server reuse and redirect handling; see the release notes.
- The README promises legacy bug/security fixes for at least six months after 2026-07-27 (checked 2026-10-20). This is a minimum window, not a shutdown deadline; no exact shutdown was verified.
What breaks
The official troubleshooting page, fetched today, documents these strings. This is a diagnostic list, not a frequency ranking.
| Documented error | Next check |
|---|---|
ERA_NEGOTIATION_FAILED | Read the tail; unsupported pins, failed probes and connectivity failures differ. Use auto only when fallback is intended. |
Version negotiation failed: the server requires authorization (HTTP 401) | Configure authProvider; authorization failure is not a protocol mismatch. |
Version negotiation failed: the server denied access (HTTP 403) | Check access policy and any insufficient-scope challenge. |
SSE stream disconnected: TypeError: terminated | Inspect stream idle timeouts and heartbeat configuration. |
TS2589: Type instantiation is excessively deep and possibly infinite | Inspect duplicate Zod copies with npm ls zod. |
A missing SSEServerTransport export means server SSE moved to @modelcontextprotocol/server-legacy/sse. That troubleshooting page also documents ReferenceError: crypto is not defined for an older runtime.
Redirect PR #2901 documents errors ending in (redirectPolicy: 'same-origin'). Prefer configuring the final endpoint URL; redirectPolicy: 'follow' deliberately restores broader redirects. Browser redirects need particular attention.
The authorization guide documents 401 invalid_token when expiry is missing or an enforced resource fails to match. An unexpected verifier exception produces 500 server_error.
How to migrate
1. Save a working baseline. The migration prerequisite is Node 20 or newer (checked 2026-10-20). At the package root run the exact guide command, npx @modelcontextprotocol/codemod@latest v1-to-v2 .. Review @mcp-codemod-error markers and workspace manifests; run your formatter and tsc --noEmit. 2. Check imports against the README. It imports McpServer from @modelcontextprotocol/server and StdioServerTransport from @modelcontextprotocol/server/stdio. Node HTTP uses @modelcontextprotocol/node; Express integration needs @modelcontextprotocol/express plus express. 3. Replace .tool() with registerTool, wrap schemas and review handler context changes. Express resource-server helpers belong in @modelcontextprotocol/express; Authorization Server helpers temporarily remain in @modelcontextprotocol/server-legacy/auth. Replace old OAuth class checks with OAuthError and OAuthErrorCode. Follow the manual sections, not blind replacements. 4. For stateless HTTP create server and transport inside each request handler. PR #2918, authored by claude[bot] and approved by felixweinberger, explains why reuse is rejected. 5. Make the verifier return expiry and, when enforcing expectedResource, AuthInfo.resource. Throw OAuthError with OAuthErrorCode.InvalidToken for rejected tokens. Upgrade the Express adapter with the server when using audience enforcement, per the auth guide.
What to test
Proposed acceptance checks: compile every workspace consumer; connect from each supported host; list tools and call one with valid and invalid arguments; inspect schema descriptions; send simultaneous stateless requests; test login, refresh, expired tokens, wrong audience, scope denial, redirects and idle streams. Exercise intended legacy peers as well as modern ones. These are proposed tests, not results.
Started from a post by @modelcontextprotocol, packaged by the editor. Original post