Claude Code v2.1.247: SendFeedback Tool, /claude-api cost-optimize, and a Full 1M Auto-Compact Window for Sonnet 5
Claude Code v2.1.247 adds a SendFeedback tool for drafting feedback reports, /claude-api cost-optimize, and custom spinner tips for organizations, and moves Sonnet 5's auto-compact window to its full 1M context.
Claude Code v2.1.247 is a large release with 33 changelog entries. It introduces a SendFeedback tool that drafts feedback reports for you to review, a /claude-api cost-optimize command, and richer spinnerTipsOverride options for organizations, and it moves Sonnet 5’s default auto-compact window to its full 1M context. The release also hardens plugin marketplaces and terminal hyperlinks and fixes issues across sub-agents, hooks, background and cloud sessions, and keyboard input.
What’s New
SendFeedback Tool
When something goes wrong in a session, Claude can now use the new SendFeedback tool to draft a feedback report for you to review and send from /feedback. You can turn this off with the feedbackDrafts setting.
/claude-api cost-optimize and Admin API Coverage
The new /claude-api cost-optimize profiles an existing project’s Claude API spend and works through cost levers (caching, token hygiene, batch, effort, model choice) one measured change at a time. The /claude-api skill also gains Admin API coverage: organization members, invites, workspaces, API keys, rate limit reports, workload identity federation, and CMEK.
Organization Spinner Tips
spinnerTipsOverride now accepts {id, text, cooldownSessions, priority} entries, a tipsFile, and a label, so organizations can rotate their own tips alongside the built-in ones.
Auto Mode Shortcut on Bash Permission Prompts
Bash permission prompts now show a tip pointing to auto mode, with a one-keystroke “Yes, and switch to auto mode” option.
Sonnet 5 Auto-Compacts Later
Sonnet 5’s default auto-compact window is now its full 1M context, so sessions on the 1M window auto-compact at about 967K tokens instead of about 934K.
Collapsed Cross-Session Messages
Cross-session peer messages now collapse by default to a one-line Message from @<sender>: <first line> preview; Ctrl+O expands the full body.
Fixes and Improvements
- Security hardening: Plugin marketplace names containing control or invisible characters are now rejected, and marketplace-supplied text in
/pluginandclaude pluginoutput is escape-safe. Terminal hyperlinks in rendered markdown whose targets point at a network or automounter path, contain a control character, or lead with an invisible character now render as plain text. - Sub-agents: Sub-agents no longer die on a first-call model 404; they now use the session’s fallback model chain, and the error returned to the parent includes the error type, status, request id, and model.
- Hooks and background output: A hook or background agent that prints megabytes of error output can no longer overflow the conversation and wedge the session on “Prompt is too long”. Memory no longer grows without bound when a hook’s or background task’s output file cannot be written; the file now notes where output was lost.
- Keyboard input: Fast arrow-key + Enter sequences no longer act on the row above the one you navigated to in history search,
/config,/mcp,/skills, background tasks, and/model. Ctrl keyboard shortcuts now fire under non-Latin (e.g. Cyrillic) keyboard layouts in kitty-protocol terminals. - Dotfile-managed configuration: The Bash sandbox’s after-command cleanup no longer deletes a dotfile-managed
~/.claude/settings.jsonsymlink (nix/home-manager, stow) when it is repointed outside the sandbox’s writable area./terminal-setupno longer overwrites your entire Zedkeymap.jsoninstead of merging in its keybinding. - Compaction with
--agent:/compactand “Summarize from here” in sessions started with--agentnow summarize under the conversation’s own system prompt instead of the default one. - Background and cloud sessions: A background session no longer shows “opening…” forever in
claude agentsafter its terminal host process died; the row now fails within seconds with the reason, and Enter restarts it. Cloud sessions no longer go silent when the container restarts between turns while a background agent, shell, or monitor is still running; the resumed session now reports the lost work. - MCP on Bedrock, Vertex, and Foundry: In these sessions, and in any session with telemetry disabled, Claude is now told when a configured MCP server failed to connect instead of concluding its tools don’t exist.
- Remote Control and self-hosted runner: Remote Control sessions started with
/remote-controlnow report the working-tree diff to connected clients. Self-hosted runner sessions no longer reportrunningbefore Claude Code has started, which could trigger a premature “Claude is waiting for your input” notification from the Claude desktop app. - Sign-in and managed settings: First-run setup no longer exits with “Unable to connect to Anthropic services” when managed settings configure Claude apps gateway sign-in and Anthropic endpoints are unreachable. Organization sign-in enforcement now exits at start when the administrator’s managed settings cannot be read, even if host-supplied or per-user Windows registry settings exist, and analytics now stay off from startup when managed settings force gateway login or a custom OAuth deployment is configured.
This release contains 33 changes in total; see the official changelog linked below for the complete list.
How to Update
- Check your installed version:
claude --version - Update in place:
claude update - If you don’t want Claude to draft feedback reports with the new
SendFeedbacktool, turn off thefeedbackDraftssetting.