Source · release
Claude Code release 2.1.307
Summary
Claude Code 2.1.307 (2026-10-21, from the GitHub release feed) arrived on the same day as
Claude API version 2026-10-21. It adds a bundled skill command that moves Claude API
code to the new version, an OpenTelemetry event for every blocked or prompted tool call,
and a Code Review command that ends an "always review" subscription. Most of the rest
fixes MCP reliability, autocompaction, and self-hosted runners. The Agent SDKs were
released the same day to match it (TypeScript 0.3.307, Python 0.2.171).
Key points
- API version migration: run
/claude-api api-versionin a project that calls the Claude API. It rewrites the code for API version2026-10-21. See API version 2026-10-21 for what changes. - Safety telemetry: a new
claude_code.safety_eventOpenTelemetry event is emitted each time a permission rule, auto mode, a safety check, a hook, or the sandbox stops, prompts, or sends back a tool call. It needs OpenTelemetry export to be set up, and lets you see in a dashboard why agents were blocked. - Code Review: comment
@claude review stop(oroff/pause) on a pull request to end an@claude review alwayssubscription without starting a new review. - MCP fixes: HTTP MCP tool calls are no longer sent twice when the connection drops
mid-call, because only read-only or idempotent tools are retried. Servers no longer
stay "timed out" in headless runs after the computer sleeps. On macOS,
claude -pnow says why a server "needs authentication" when the keychain is locked. A turn no longer starts without an SDK MCP server's latest tools. - Robustness: an unparseable tool call is retried up to twice before the turn fails. Fewer "Autocompact is thrashing" errors in turns that read many PDF pages or images. Forks launched together are each told which launch is theirs, so they are less likely to do each other's work.
- Settings:
axScreenReaderandCLAUDE_AX_SCREEN_READERin a settingsenvblock now apply only from user, managed, or--settingssettings, not from project files. - Self-hosted runners: checkout hooks now stop after 30 minutes by default and fail
setup. Raise
--checkout-hook-timeout-min, or set it to0, if yours take longer. - Agent SDK (TypeScript) 0.3.307: adds
wakeup_source(andscheduled_for) to thecommand_lifecyclestart frame, so a host can tell whether a scheduled wakeup or a task fired. It also addssupportedDialogKindsto the browser SDKquery().
Why it matters
The /claude-api api-version command is the quickest way to move a codebase to the
new API version, which removes temperature, top_p, and top_k. The safety event
lets teams measure how often guardrails fire. That is useful when tuning auto mode or
hooks.