AI/TLDR

Anthropic · 2026-06-22 · major

Claude Code 2.1.186 — MCP login CLI plus auto-reply to bash commands

Claude Code v2.1.186 adds claude mcp login/logout for CLI-based MCP server auth, makes ! bash commands auto-prompt Claude to respond, and fixes 20+ background-agent and post-sleep streaming bugs.

GitHub release page for Claude Code v2.1.186 by Anthropic

Anthropic's terminal coding agent ships v2.1.186 with CLI auth for MCP servers and an automatic Claude reply to every ! bash command.

Key specs

Version2.1.186
GitHub stars133.7K

Quick facts

MakerAnthropic
Version2.1.186
ReleasedJun 22, 2026 (20:37 UTC)
New CLIclaude mcp login / logout
Default change! bash output auto-replied by Claude
Repogithub.com/anthropics/claude-code
LicenseProprietary

What is it?

Claude Code 2.1.186 introduces claude mcp login <name> and claude mcp logout <name>, so MCP server authentication now happens from the shell instead of the interactive /mcp menu. A --no-browser flag redirects the OAuth flow through stdin for SSH sessions where opening a local browser was previously impossible.

How does it work?

Two defaults change. The ! prefix now feeds bash output back to the model for a follow-up reply (toggle with respondToBashCommands: false). And the /plugin Installed tab grows a Skills section that surfaces every loaded skill, while /workflows gets a status filter (press f) for the agent detail view. iterm2 joins auto as a teammateMode value when the it2 CLI is on PATH.

Why does it matter?

v2.1.186 closes more than twenty long-standing runtime bugs that bit power users: streaming requests dying after a laptop woke from sleep, subagent transcripts bleeding into the main view, Esc and Ctrl+C ignored while background agents were still running, and session cost hidden for usage-based Enterprise and Team plans. Unattended sessions are noticeably less fragile.

Who is it for?

Anthropic Claude Code users running the terminal CLI as a daily driver

Frequently asked questions

How do I authenticate an MCP server from the CLI now?
Claude Code 2.1.186 adds claude mcp login <name> and claude mcp logout <name> so you no longer have to open the interactive /mcp menu. A new --no-browser flag redirects stdin so the OAuth flow completes over SSH, which previously required a desktop browser session on the same machine.
Will Claude now run my bash commands and respond on its own?
In v2.1.186 a ! bash command hands its output back to Claude Code, which then replies automatically instead of just dropping the result into context. Setting respondToBashCommands to false in settings.json restores the old context-only behavior.
How does Claude Code 2.1.186 compare to the 2.1.139 release from last month?
Where 2.1.139 introduced the Agent View for cross-session visibility, 2.1.186 hardens the agent runtime — long background sessions now survive sleep/wake, Esc and Ctrl+C work while subagents are running, and Workflow agent({schema}) calls abort after 5 validation failures instead of looping forever.
What changes for /review <pr> in this release?
Claude Code 2.1.186 routes /review <pr> through the same engine that powers /code-review medium, so PR reviews now use the same finding-style and effort tiers as your local working-diff reviews. Behavior on individual files is unchanged.

Try it

claude update  (or download v2.1.186 from github.com/anthropics/claude-code/releases)

Sources · 2 outlets

Tags

  • claude-code
  • anthropic
  • coding-agent
  • cli
  • mcp
  • release
  • skills
  • workflows

← All releases · Learn AI