Skip to content
All news
ReleaseAI-written

Claude Code 2.1.331 adds terminal platform support for Code Mode and OIDC group reading

Claude Code 2.1.331 introduces terminal session support for Code Mode on Amazon Bedrock, Google Cloud Agent Platform, Microsoft Foundry and Claude Platform on AWS, adds OIDC group reading via oidc.groups_jsonpath, and expands API diagnostics with the claude doctor command reporting HTTP status.

Claude Code 2.1.331 was released on 2026-11-23. The update enables Code Mode to run in terminal sessions on Amazon Bedrock, Google Cloud Agent Platform, Microsoft Foundry and Claude Platform on AWS. It also adds OIDC group information reading through the new oidc.groups_jsonpath setting and expands API diagnostics via the claude doctor command.

The Claude apps gateway can now read OIDC group data using oidc.groups_jsonpath, which supports a subset of JSONPath. To preserve IdP hostname transmission when a proxy respects NO_PROXY, the environment variable CLAUDE_GATEWAY_IDP_CONNECT_BY_HOSTNAME=1 must be set.

The claude doctor command includes an API connectivity section that reports the HTTP status or error when checking the API endpoint. The environment variable CLAUDE_CODE_DISABLE_RESPONSE_COMPRESSION allows users to request uncompressed model responses when a proxy blocks compressed data.

Trace spans for claude_code.llm_request now contain gen_ai.usage.*, gen_ai.response.model and gen_ai.operation.name, and input token counts include prompt cache tokens. Plugin manifests now support optionalDependencies, enabling plugins to be installed as optional components that can be disabled or removed independently.

Startup time improves because a new session after another no longer waits for the model list, and sessions outside a git repository skip git checks. Code Mode sessions resumed with --resume or --continue retain their original limits and thinking state, preventing loss of prompt cache. The CLI avoids freezing on certain replies and ensures quoted text is neither missing nor duplicated. A notice appears when tap‑mode voice dictation stops after 15 seconds of silence or reaches its two‑minute limit.

VSCode integration adds quick‑fix actions such as "Fix with Claude Code" and new menu items for adding cells or files to the chat.

  • Breaking change: set CLAUDE_GATEWAY_IDP_CONNECT_BY_HOSTNAME=1 to maintain IdP hostname handling when using a proxy with NO_PROXY.
  • Breaking change: after 2026-11-30, managed plugin marketplaces will auto‑update by default; set "autoUpdate": false to opt out.