Claude Agent SDK
Changelog
Anthropic Agent SDK, showing TypeScript releases
This page shows at most the 60 most recent releases from official sources. It does not claim to be a complete version history.
Latest Releases (76)
v0.3.296New
v0.3.296
October 9, 2026
- •Added
claude_code_versionto theinitializecontrol response so clients know the CLI version before the first turn - •Added
autoCompactWindowtoAgentDefinition, so a subagent can auto-compact earlier than the main conversation's window - •Fixed the
sandboxoption discarding an inlinesettings.sandboxblock: the two now merge, the option's values win, and deny and credential lists from both sides are combined - •Changed the default limit on MCP tool descriptions sent up front and on MCP server instructions, in-process SDK servers included, from 2,048 to 4,096 characters
- •Changed permission answers that arrive after a restart to be parsed like live ones: over 4,096
updatedPermissionsentries count as a denial, and a malformed list is ignored as a whole - •Updated to parity with Claude Code v2.1.296
v0.3.295New
v0.3.295
October 8, 2026
- •Added
overageEnabledtoSDKRateLimitInfo: on usage-limit warnings, whether the account has extra usage turned on - •Fixed an MCP server added with
mcp_set_serverssometimes keeping an outdated tool list when another server in the same request connected later - •Fixed assistant text blocks losing their
citationsin streamed responses - •Fixed Claude being told "disabled by the user" about an in-process MCP server that was switched off with
toggleMcpServer() - •Fixed
rate_limit_eventwith statusallowed_warningomittingoverageStatus,overageResetsAtandoverageDisabledReason, whichallowedandrejectedevents already carry - •Changed MCP tool descriptions the model loads through tool search, including those from in-process SDK servers, to be cut at 16,384 characters instead of 2,048
- •Changed a permission answer whose
updatedPermissionsholds over 4,096 updates, rules and directories to count as a denial - •Changed
tool_result_meta[].non_execution_kindto be absent when a mod withheld the result of a tool that ran without error; it waspermission-rule - •Changed
pasted_contenton user messages to be ignored when it holds over 1,000 entries and blocks in all - •Changed how the SDK passes option values to Claude Code: the values of its named options are now sent in the same argument as their flag (
--flag=value) - •Changed
tool_use_resultfor MCP Apps tools:structuredContentor_metaover 8,388,608 JSON characters is left off, and_meta.uiwith noui://resource no longer lifts the ordinary caps - •Changed
tool_use_resultfor MCP tools: when a long result is saved to a file, or cut because it could not be, the text kept past 500,000 characters is dropped, with a note of how much - •Changed
tool_use_resultfor MCP tools: a result_metaover 1,048,576 JSON characters is left off, except for SDK-server tools; so is text blocks'_metathat totals over 65,536 - •Updated to parity with Claude Code v2.1.295
v0.3.292New
v0.3.292
October 6, 2026
- •Added
agent_idto theassistantandusermessages a subagent produces; it equals thetask_idon that subagent's task events and stays the same when the subagent is resumed - •Added
parent_task_idtotask_startedevents andbackground_tasks_changedentries, naming the subagent task that launched a task - •Added
run_idto background task events andorigin.runIdto task notifications, so a host can tell a resumed task's runs apart - •Added typed
sectionsandnotesto theListAgentstool'stool_use_result, so hosts can list agents without parsing its text - •Added
recipient_kindto SendMessagetool_useinputs on assistant messages, and their top-levelapproveis now always a boolean, so hosts no longer infer them from the raw input - •Added two optional fields to the
ReadNotificationstool output:read_at, when the tool read the session's queued notifications, andarrived_aton each notification, when it reached the session - •Fixed subagents with a declared auto permission mode having their tool calls decided by the auto-mode classifier instead of the canUseTool callback when auto mode is unavailable
- •Changed
background_tasks_changedfor a finishing background task to arrive after that task'stask_updatedandtask_notification - •Changed
canUseTooloptions to carrysuppressAlwaysAllowRule: truefor connector tools that an organization set to require approval, so hosts can hide their "always allow" choice - •Updated to parity with Claude Code v2.1.292
v0.3.290New
v0.3.290
October 6, 2026
- •Added an optional
offsetfield to the WebFetch tool input for reading on through long pages - •Fixed failed Claude in Chrome tool calls dropping the result's
_meta: when the result has one,tool_use_resultis now{ content, _meta }, as for other MCP tools - •Fixed deny and ask rules missing
toolAliasestools when written with a wildcard (Bash*), a match-all pattern (Bash(**), also on the mapped name), or an input field also indisallowedTools - •Fixed a user message sent again under the same
uuidbeing replayed (--replay-user-messages) while the first copy still waited for its turn; its replay now comes when a turn takes it - •Fixed
includePartialMessagesstreams leaving a message withoutmessage_stopwhen the stream was cut, interrupted or fell back to non-streaming - •Changed
user_message_uuid,user_message_uuidsandresume_reasonto also be set on a turn a restarted worker resumes from a permission answer or from tool calls still in flight - •Updated to parity with Claude Code v2.1.290
v0.3.287
v0.3.287
October 1, 2026
- •Added optional remote-session latency fields (
first_text_post_queue_wait_ms,first_text_post_queued_behind) to the success result message - •Fixed
includePartialMessagesstreams sending a cut-short reply'smessage_stoplate or never, so apps could show the reply as still in progress - •Fixed the error for a revoked claude.ai login, which now reads "Failed to authenticate: OAuth token revoked" instead of a generic or "does not have access" message
- •Fixed a tool call to an in-process MCP server being left waiting after
toggleMcpServer()disabled the server orsetMcpServers()removed it - •Fixed
commands_changedarriving beforeinit, or twice, at session start: theinitializeresponse now includes commands registered at startup - •Changed
tool_use_resultfor a WebFetch or WebSearch call that steps aside for a priority "now" message to{ detachedToolCall: true }; the result follows in a later turn - •Changed
tool_use_resultfor MCP tools:structuredContentover 1,048,576 JSON characters is left off andstructuredContentOmitted: trueset, except for SDK-server and MCP Apps tools - •Updated to parity with Claude Code v2.1.287
v0.3.286
v0.3.286
September 30, 2026
- •Added the initialize response field
sdk_mcp_manifests_parkedand thesystem/initcapabilitiessdk_mcp_manifestsandsdk_mcp_tools_list_changed - •Fixed foreground subagents sometimes not receiving the task-tracking tools listed in
toolsorallowedTools - •Fixed an SDK MCP server listing no tools when one tool's schema cannot be converted to JSON Schema; that tool is now left out with a warning naming it
- •Fixed
toggleMcpServer()not disconnecting, and failing to re-enable, an in-process MCP server created withcreateSdkMcpServer(), except one namedclaude-in-chrome - •Changed a person's priority
nowmessage to move running shell commands, agents and MCP calls to the background and join the running turn instead of stopping it - •Changed the TypeScript Agent SDK to leave an omitted
permissionModeto Claude Code, so a settingsdefaultModenow applies and, on third-party providers or with telemetry off, the session starts in auto mode likeclaude -p; passpermissionMode: 'default'for manual approvals - •Updated to parity with Claude Code v2.1.286
v0.3.285
v0.3.285
September 29, 2026
- •Added an optional
read.title(the artifact's stored title) to the Artifact tool's structured read result - •Added
provider_not_allowedtostartup_failure_reasonandallowedProvidersto theSettingstype - •Fixed sessions with
CLAUDE_CODE_FORK_SUBAGENT=1: a subagent's own Agent call now runs in the foreground, so the subagent gets the child's result - •Fixed
getSessionMessages()leaving out a message sent while Claude was working when the process stopped before the reply, or when another prompt followed it with no reply in between - •Fixed
toggleMcpServer(name, false)leaving the connection open for a server that had not yet connected when the session started, or whose config was edited after it connected - •Fixed
rewind_conversationleaving a backgrounded MCP tool call running after the message that started it was removed - •Changed Bash/PowerShell
timeoutto bound arun_in_backgroundcommand (was ignored; default 30 min, max 2 h); thestoppedtask notification for a stop at that limit says why - •Changed
getSubagentMessages()to also return the messages a subagent read while it ran, such as a message sent to it;offsetandlimitcount these rows - •Updated to parity with Claude Code v2.1.285
v0.3.284
v0.3.284
September 28, 2026
- •Added a renamed skill's directory name to its
SlashCommandaliaseswhen the name is plain and Claude Code ships no command by that name - •Added
applied.ultracodeAvailableandapplied.ultracodeRequestedtogetSettings(): whether this session can run Ultracode, and whether it is requested, independent of whether it is in effect - •Fixed
forkSession()copies reading back the wrong history when cut at a progress row or fork briefing after a rewind, or when the session was compacted with some messages kept - •Fixed
getSessionMessages()leaving out messages from other agents, sessions and channels that the CLI transcript shows - •Fixed
{ decision: 'block' }returned by Elicitation and ElicitationResult hook callbacks being ignored; it now declines the MCP elicitation - •Fixed
query()closing stdin before a follow-up turn woken by a finished background agent, which failed that turn's hooks,canUseTooland SDK MCP calls with "Stream closed" - •Changed the first turn to still wait up to 2s for connecting MCP servers named in
allowedToolsor by anmcp_toolhook, even withCLAUDE_CODE_MCP_STARTUP_WAIT_MSset to0 - •Changed
applyFlagSettings({ ultracode: true })to keep the current effort level instead of switching toxhigh; aneffortLevelthat changes the level withoutultracodeturns Ultracode off - •Updated to parity with Claude Code v2.1.284
v0.3.283
v0.3.283
September 25, 2026
- •Added
plugin_errorsto theSDKSystemMessagetype (system/init), includingpathfor a--plugin-direntry that did not load - •Fixed
getSessionMessages()returning, andforkSession()copying, a rewound-away branch when the newest branch ends at a meta row or a local command's rows - •Changed stream-json output to include warnings and notices raised during a turn as
system/informationalmessages; it previously dropped them - •Changed the
set_max_thinking_tokenscontrol request: omittingmax_thinking_tokensnow leaves the session's thinking budget unchanged; sendnullto reset it to the session default - •Updated to parity with Claude Code v2.1.283
v0.3.282
v0.3.282
September 24, 2026
- •Added support for
strictKnownMarketplacesandblockedMarketplacesin host-suppliedmanagedSettings: the allowlist applies only where admin policy sets none; the blocklist adds to the admin's - •Added
@anthropic-ai/claude-agent-sdk/core, a smaller entry point for apps that bundle the SDK (query, MCP tool helpers, session mutations,resolveSettings); it uses your installed zod and MCP SDK - •Added
prewarm()andSpareProcess.claim()(alpha): start a Claude Code process before its session is known and bind it to a folder and its per-session options later - •Fixed
readMcpResource()relaying content_metakeys under the CLI-reservedcom.anthropic/prefix; they are now dropped, as for tool results - •Updated to parity with Claude Code v2.1.282
v0.3.281
v0.3.281
September 23, 2026
- •Added optional
trigger,user_message_uuidandtimestampfields to theconversation_resetmessage so clients can tell what reset the conversation, match a /clear to its message, and show when the reset happened - •Fixed permission and dialog callbacks still being invoked for requests that arrived after
close() - •Fixed control requests issued after a query closed hanging or leaking, and permission prompts that could not be cancelled after a cancelled request was redelivered
- •Fixed
session_state_changedstaying atrequires_actionafter an overlapping permission prompt and sandbox network-access prompt were both answered - •Improved SDK package size and load time:
sdk.mjsno longer bundles unused dependencies (1.47 MB → 0.97 MB) - •Improved startup time for
query()sessions with in-process MCP servers (createSdkMcpServer) by running their handshake inside the SDK;initializemay now wait up to 250 ms for them - •Improved SDK session start-up: the CLI now answers the host's initialize request before starting its background start-up work
- •Changed the
Settingstype'sattributionfield toboolean | {...}; TypeScript code that readsattribution.commitfrom returned settings needs a type narrow - •Updated to parity with Claude Code v2.1.281
v0.3.280
v0.3.280
September 22, 2026
- •Added optional
fireReasonto the task-notificationSDKMessageOrigin; a local host's declared scheduled-task fire is honored only in a process it started withCLAUDE_CODE_HOST_SCHEDULED_RUN=1 - •Added
verbatimPromptsoption: prompts are delivered as written — no@pathexpansion, no slash-command dispatch and, on current CLIs, no ambient attachments with the prompt (Claude Code 2.1.248+) - •Added
_metatomcpServerStatus()tool entries, carrying a tool's MCP Appsuimetadata so a host can find itsui://resource - •Added
readMcpResource()(alpha) to read an MCP Appsui://resource from an MCP server that Claude Code connected - •Improved
askSideQuestion(): asked while a turn is running, it now sees that turn (its prompt, replies and finished tool results so far) instead of only the last completed turn - •Improved unattended retry (
CLAUDE_CODE_RETRY_WATCHDOG): a usage-limit wait emitsrate_limit_event(rejected,resetsAt) as it begins;api_retryheartbeats continue while sub-agent work waits - •Changed
session_state_changedevents (CLAUDE_CODE_EMIT_SESSION_STATE_EVENTS=1) to reportrequires_actionwhile an MCP elicitation waits on the user, as for permission prompts - •Changed headless sessions to cancel an MCP server's pending form question when the tool call that drew it ends
- •Updated to parity with Claude Code v2.1.280
v0.3.277
v0.3.277
September 18, 2026
- •Added an optional
builtinfield toSlashCommand, set when a command is built into Claude Code - •Added
pasted_contenttoSDKUserMessage: text the user pasted rather than typed, appended after the typed prompt - •Added optional remote-session latency fields (
first_text_post_ms,first_text_post_wall_ms,first_stream_post_queue_wait_ms,first_stream_post_queued_behind) to the success result message - •Added
'userSettings'as anupdateSettings()source, accepting onlyeffortLevel, which is saved for the session's current model as/effortsaves it - •Fixed a resumed or forked session's
total_cost_usd,modelUsageandget_usagetotals starting at zero instead of continuing from the earlier turns (maxBudgetUsdis unchanged) - •Changed
SDKUsageReportusage rows to always carryseverityandis_active: the report relays only rows from a live server reply, and none while the usage fetch is failing - •Updated to parity with Claude Code v2.1.277
v0.3.275
v0.3.275
September 18, 2026
- •Fixed a deferred tool call's result being emitted with internal keys such as
toolUseResultinstead oftool_use_resultwhen the tool re-runs at the start of a resumed turn - •Fixed
getSessionMessages()andforkSession()sometimes missing a turn's assistant message when called right after the turn'sresultmessage - •Fixed
forkSession({ upToMessageId })rejecting a client-suppliedSDKUserMessage.uuidthat is not in UUID format - •Fixed
forkSessionrejecting the id thatgetSessionMessagesreturns for a message sent while Claude was working, and a fork showing a re-run prompt twice - •Fixed
getSessionMessages()omitting a task notification or other queued message that Claude read while running a tool; it now comes back where Claude read it - •Updated to parity with Claude Code v2.1.275
v0.3.274
v0.3.274
September 17, 2026
- •Added
startup_failure_reasonto the error result a stream-json run writes before exiting on a known startup failure - •Added
mcpServer: {name, source}tocanUseTooloptions,mcp_serverto tool hook inputs, andsourceto MCP server status rows, so hosts can key trust onsource === "sdk" - •Added
CLAUDE_CODE_MCP_STARTUP_WAIT_MS(pass viaenv) to bound or disable (0) the first-turn wait for connecting MCP servers - •Added
CLAUDE_CODE_EMIT_STARTUP_TIMING=1for stream-json hosts: the session's firstsystem/initthen carries the per-phasestartup_timingbreakdown that cloud sessions already emit - •Fixed
getSessionMessages()omitting a message the user sent while Claude was running a tool; it now comes back as a user message where Claude read it - •Fixed missing
origin: {kind: 'task-notification'}on the replayed user message when a background task finishes during a running turn (--replay-user-messages) - •Improved startup: the first turn no longer waits up to 2s for connecting MCP servers from settings files or plugins whose tools tool search defers;
options.mcpServersservers are still awaited - •Changed queued background-task completions to share one model call: each still gets its own
result, all but the last empty withnum_turns: 0 - •Updated to parity with Claude Code v2.1.274
v0.3.273
v0.3.273
September 15, 2026
- •Added a
usage_reportsibling (SDKUsageReport: session totals, the plan's usage rows as the server sends them, extra usage) on the assistant message that delivers a headless/usageresult - •Added
reason: "worker_restart"totask_notificationmessages when a background task was stopped by a worker process restart - •Added a one-line transcript notice when the SDK host's
StoporSessionStarthook callback times out, shown once until the host answers again - •Fixed a
Stop,SubagentStoporSessionStarthook callback that exceeds its timeout being reported as a hook failure and discarding other hooks' decisions; it now counts as no decision - •Fixed the browser SSE transport dropping the live slash-command list update (
system/commands_changed) - •Updated to parity with Claude Code v2.1.273
v0.3.271
v0.3.271
September 15, 2026
- •Added optional
omitClaudeMdtoAgentDefinitionin theagentsoption, so a subagent can run without user, project and local CLAUDE.md files; managed policy files still load - •Fixed
listSessions,getSessionMessagesandgetSessionInfowithdiron Windows not finding sessions for a directory on a mapped network drive or SUBST drive - •Fixed
sessionStoreresume losing the global config when it is stored under the legacy.config.jsonname or an OAuth-suffixed file name - •Removed
persistentfrom theMonitorInputtool type - •Updated to parity with Claude Code v2.1.271
v0.3.269
v0.3.269
September 11, 2026
- •Changed
user_message_uuid,user_message_uuidsandresume_reasonto be stamped on a turn's first complete assistant message as well as its first stream event when partial messages are on - •Fixed
result.permission_denialsomitting Read, Edit and Write calls blocked by a path-scoped deny rule - •Fixed interrupts and permission responses being delayed while a host-started MCP server OAuth sign-in waited on a slow authorization server
- •Fixed missing
tool_use_idontask_started/task_notificationwhen the CLI resumes a background subagent on its own; they now carry the agent's last call id - •Changed plan mode to route writes through
canUseTooleven whenallowDangerouslySkipPermissionsis set; the flag now only enables switching tobypassPermissionslater - •Updated to parity with Claude Code v2.1.269
v0.3.268
v0.3.268
September 10, 2026
- •Added
result_indexto result messages: the result's position in delivery order within the run, from 0 - •Added
local_commandto the result message of a turn that ran a slash command without entering the model loop, carrying the command's name - •Added
hold_on_cache_impactto thereload_pluginscontrol request (Query.reloadPlugins({ holdOnCacheImpact: true })): holds a reload that would invalidate the session's prompt cache - •Added
resume_reasonto assistant, stream-event and result messages, set only on the automatic re-run of a turn a host restart interrupted - •Added
kind(used, free, buffer, deferred) to each category in theget_context_usagecontrol response, matching the/contextresult'scontext_usagerows - •Added optional
defaultToNoandsuppressAlwaysAllowRulehints tocanUseTooloptions: the prompt should open on its decline option, or offer no persistent "always allow" choice - •Changed
setModel()to confirm a model id the CLI doesn't know locally with the API the first time a session uses it, instead of refusing it as unrecognized - •Changed
user_message_uuidon the automatic re-run of an interrupted turn to name that turn's last user prompt - •Changed the
initializesuccess response to always includepending_permission_requests(empty when nothing is pending), so clients can tell that apart from an older CLI - •Changed the task-tracking tools (TaskCreate/Get/Update/List, TodoWrite) to be default tools only on Claude 3.x, Opus 4.0–4.7, Sonnet 4.0–4.6 and Haiku 4.5; elsewhere list them in
tools/allowedTools - •Updated to parity with Claude Code v2.1.268
v0.3.267
v0.3.267
September 9, 2026
- •Added
getCcrEvent(query, message)andgetSseLastSequenceNum(query)to the browser SDK's SSE transport, plusfromSequenceNum,onCatchUpTruncatedandonDeliveryUpdateSSE options - •Changed
systemPromptrecording to default on for custom prompts and appends (a mid-session prompt change takes effect at the next compaction); passsnapshot: falseto keep per-request rendering - •Updated to parity with Claude Code v2.1.267
Showing 30 of 76