---
title: "@anthropic-ai/claude-agent-sdk 0.3.142 Breaking Changes"
description: "What each @anthropic-ai/claude-agent-sdk release removed, renamed or changed: 25 breaking changes in 2 versions on npm, each with its source."
canonical_url: https://since.dev/packages/npm/@anthropic-ai/claude-agent-sdk
last_updated: 2026-12-04
---

# @anthropic-ai/claude-agent-sdk breaking changes

@anthropic-ai/claude-agent-sdk 0.3.142 (May 14, 2026) is its newest release with breaking changes, 13 of them. The first: Removed SDKSession. Every breaking API change we have recorded in @anthropic-ai/claude-agent-sdk on npm: 25 breaking changes in 2 versions. Below, its 2 versions with breaking changes, newest first, removals and renames first, each with its source.

Updated December 4, 2026

Latest version `0.3.337`, released December 4, 2026. [Source repository](https://github.com/anthropics/claude-agent-sdk-typescript)

Packages on npm run on Node.js. [Node.js end of life dates](https://since.dev/calendar/nodejs.md).

- From [0.2.0](#v-0-2-0) to [0.3.142](#v-0-3-142): 13 breaking changes in 1 version.

## @anthropic-ai/claude-agent-sdk 0.3.142 breaking changes

@anthropic-ai/claude-agent-sdk 0.3.142, released May 14, 2026: 13 breaking changes.

- **Removed** `SDKSession`  

The v2 session API was removed after being deprecated since 0.2.133. Use query() instead, passing an AsyncIterable\<SDKUserMessage> for multi-turn use or options.resume to continue a session. [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.3.142)
- **Removed** `SDKSessionOptions`  

The v2 session API was removed after being deprecated since 0.2.133. Use query() instead, passing an AsyncIterable\<SDKUserMessage> for multi-turn use or options.resume to continue a session. [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.3.142)
- **Removed** `TodoWrite`  

Headless and SDK sessions now use the Task tools instead of TodoWrite, which was deprecated since 0.2.136. Tool consumers should accumulate by task ID instead of replacing a snapshot list. [github.com](https://github.com/anthropics/claude-agent-sdk-typescript/releases/tag/v0.3.142)
- **Removed** `unstable_v2_createSession`  

The v2 session API was removed after being deprecated since 0.2.133. Use query() instead, passing an AsyncIterable\<SDKUserMessage> for multi-turn use or options.resume to continue a session. [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.3.142)
- **Removed** `unstable_v2_prompt`  

The v2 session API was removed after being deprecated since 0.2.133. Use query() instead, passing an AsyncIterable\<SDKUserMessage> for multi-turn use or options.resume to continue a session. [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.3.142)
- **Removed** `unstable_v2_resumeSession`  

The v2 session API was removed after being deprecated since 0.2.133. Use query() instead, passing an AsyncIterable\<SDKUserMessage> for multi-turn use or options.resume to continue a session. [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.3.142)
- **Behavior changed**  

Sessions start immediately and slow MCP servers report status pending in init until ready. Set MCP_CONNECTION_NONBLOCKING=0 to restore waiting up to 5s before the first query, or mark a server alwaysLoad: true to require it in turn 1. [github.com](https://github.com/anthropics/claude-agent-sdk-typescript/releases/tag/v0.3.142)
- **Signature changed** `Options`  

Was type Options = {abortController?: AbortController; additionalDirectories?: string\[\]; agent?: string; agents?: Record\<string, AgentDefinition>; allowedTools?: string\[\]; canUseTool?: CanUseTool; continue?: boolean; cwd?: string... [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.3.142)
- **Signature changed** `SDKAssistantMessage`  

Was type SDKAssistantMessage = {type: 'assistant'; message: BetaMessage; parent_tool_use_id: string | null; error?: SDKAssistantMessageError; uuid: UUID; session_id: string;}; now type SDKAssistantMessage = {type: 'assistant'; message... [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.3.142)
- **Signature changed** `SDKResultSuccess`  

Was type SDKResultSuccess = {type: 'result'; subtype: 'success'; duration_ms: number; duration_api_ms: number; is_error: boolean; api_error_status?: number | null; num_turns: number; result: string; stop_reason: string | null... [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.3.142)
- **Signature changed** `SDKTaskProgressMessage`  

Was type SDKTaskProgressMessage = {type: 'system'; subtype: 'task_progress'; task_id: string; tool_use_id?: string; description: string; usage: {total_tokens: number; tool_uses: number; duration_ms: number;}; last_tool_name?: string... [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.3.142)
- **Signature changed** `SDKTaskStartedMessage`  

Was type SDKTaskStartedMessage = {type: 'system'; subtype: 'task_started'; task_id: string; tool_use_id?: string; description: string; task_type?: string; workflow_name?: string; prompt?: string; skip_transcript?: boolean; uuid: UUID... [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.3.142)
- **Signature changed** `SDKUserMessage`  

Was type SDKUserMessage = {type: 'user'; message: MessageParam; parent_tool_use_id: string | null; isSynthetic?: boolean; tool_use_result?: unknown; priority?: 'now' | 'next' | 'later'; origin?: SDKMessageOrigin; shouldQuery?: boolean... [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.3.142)

## @anthropic-ai/claude-agent-sdk 0.2.0 breaking changes

@anthropic-ai/claude-agent-sdk 0.2.0, released January 7, 2026: 12 breaking changes.

- **Signature changed** `AgentMcpServerSpec`  

Was type AgentMcpServerSpec = string | {\[name: string\]: McpServerConfigForProcessTransport;}; now type AgentMcpServerSpec = string | Record\<string, McpServerConfigForProcessTransport>. [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.2.0)
- **Signature changed** `EXIT_REASONS`  

Was const EXIT_REASONS: string\[\]; now const EXIT_REASONS: readonly \["clear", "logout", "prompt_input_exit", "other", "bypass_permissions_disabled"\]. [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.2.0)
- **Signature changed** `ExitReason`  

Was type ExitReason = (typeof EXIT_REASONS)\[number\]; now type ExitReason = 'clear' | 'logout' | 'prompt_input_exit' | 'other' | 'bypass_permissions_disabled'. [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.2.0)
- **Signature changed** `HookEvent`  

Was type HookEvent = (typeof HOOK_EVENTS)\[number\]; now type HookEvent = 'PreToolUse' | 'PostToolUse' | 'PostToolUseFailure' | 'Notification' | 'UserPromptSubmit' | 'SessionStart' | 'SessionEnd' | 'Stop' | 'SubagentStart' | 'SubagentStop' |... [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.2.0)
- **Signature changed** `JsonSchemaOutputFormat`  

Was type JsonSchemaOutputFormat = BaseOutputFormat & {type: 'json_schema'; schema: Record\<string, unknown>;}; now type JsonSchemaOutputFormat = {type: 'json_schema'; schema: Record\<string, unknown>;}. [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.2.0)
- **Signature changed** `JsonSchemaOutputFormat.type`  

Was type: OutputFormatType; now type: 'json_schema'. [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.2.0)
- **Signature changed** `McpServerStatus`  

Was type McpServerStatus = {name: string; status: 'connected' | 'failed' | 'needs-auth' | 'pending'; serverInfo?: {name: string; version: string;};}; now type McpServerStatus = {name: string; status: 'connected' | 'failed' | 'needs-auth' |... [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.2.0)
- **Signature changed** `SDKResultMessage`  

Was type SDKResultMessage = {type: 'result'; subtype: 'success'; duration_ms: number; duration_api_ms: number; is_error: boolean; num_turns: number; result: string; total_cost_usd: number; usage: NonNullableUsage; modelUsage: {\[modelName... [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.2.0)
- **Signature changed** `SDKUserMessage`  

Was type SDKUserMessage = SDKUserMessageContent & {uuid?: UUID; session_id: string;}; now type SDKUserMessage = {type: 'user'; message: APIUserMessage; parent_tool_use_id: string | null; isSynthetic?: boolean; tool_use_result?: unknown... [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.2.0)
- **Signature changed** `SDKUserMessageReplay`  

Was type SDKUserMessageReplay = SDKUserMessageContent & {uuid: UUID; session_id: string; isReplay: true;}; now type SDKUserMessageReplay = {type: 'user'; message: APIUserMessage; parent_tool_use_id: string | null; isSynthetic?: boolean... [npmjs.com](https://www.npmjs.com/package/@anthropic-ai/claude-agent-sdk/v/0.2.0)

And 2 more in this version. [Sign up to see every change](https://app.since.dev/login?mode=signup&src=package-page)

## Related packages

- [@anthropic-ai/claude-code](https://since.dev/packages/npm/@anthropic-ai/claude-code.md)
- [@anthropic-ai/sdk](https://since.dev/packages/npm/@anthropic-ai/sdk.md)

## Check your code

These are the changes. To see which of them reach your code, [scan a public repository](https://since.dev/scan.md), or have your coding agent call `check_code` with your manifest or lockfile over [MCP](https://since.dev/docs.md#mcp). [The API](https://since.dev/docs.md#api) reads every change in every version. A fix pull request opens for the changes that reach a connected repository. Nothing merges or deploys.

## Put your code on continuous maintenance.

Scan a public repository now, or give your agent one line.

[Scan a repository](https://since.dev/scan.md). Any public GitHub repository. No sign-in.

### Tell your agent what changed since it was trained.

`claude mcp add --transport http since https://api.since.dev/mcp`

[Get an API key](https://app.since.dev/login?mode=signup)

Codex, Cursor and any MCP client use https://api.since.dev/mcp.

---

Every page on this site as Markdown: https://since.dev/sitemap.md. For agents: https://since.dev/llms.txt.
