@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
On this page
Latest version 0.3.337, released December 4, 2026. Source repository
Packages on npm run on Node.js. Node.js end of life dates.
@anthropic-ai/claude-agent-sdk 0.3.142 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 - 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 - 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 - 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 - 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 - 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 - 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 - 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 - 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 - 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 - 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 - 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 - 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
@anthropic-ai/claude-agent-sdk 0.2.0 breaking changes
- Signature changed
AgentMcpServerSpec
Was type AgentMcpServerSpec = string | {[name: string]: McpServerConfigForProcessTransport;}; now type AgentMcpServerSpec = string | Record<string, McpServerConfigForProcessTransport>. npmjs.com - 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 - Signature changed
ExitReason
Was type ExitReason = (typeof EXIT_REASONS)[number]; now type ExitReason = 'clear' | 'logout' | 'prompt_input_exit' | 'other' | 'bypass_permissions_disabled'. npmjs.com - 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 - 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 - Signature changed
JsonSchemaOutputFormat.type
Was type: OutputFormatType; now type: 'json_schema'. npmjs.com - 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 - 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 - 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 - 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
And 2 more in this version. Sign up to see every change
Related packages
Check your code
These are the changes. To see which of them reach your code, scan a public repository, or have your coding agent call check_code with your manifest or lockfile over MCP. The 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.
See how out of date your code is.
Tell your agent what changed since it was trained.
claude mcp add --transport http since https://api.since.dev/mcpCodex, Cursor and any MCP client use https://api.since.dev/mcp.