[BUG] API Error: 400 messages.68.content.6.text: cache_control cannot be set for empty text blocks

Resolved 💬 1 comment Opened May 23, 2026 by vini10-blue Closed Jun 23, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

While using Claude Code, after a couple of messages I get this error. Usually after sending a screenshot.

What Should Happen?

receive normal reply from claude

Error Messages/Logs

Steps to Reproduce

  1. initiate a chat with Claude Code
  2. exchange some messages
  3. add a screenshot
  4. API Error: 400 messages.68.content.6.text: cache_control cannot be set for empty text blocks

Claude Model

None

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

2.1.150

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

_No response_

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗