Invalid Base64 Image Input in API Request
Resolved 💬 3 comments Opened Jul 27, 2025 by ramiVeted Closed Aug 15, 2025
Bug Description
API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"messages.126.content.0.image.source.base64:
image cannot be empty"}}
Environment Info
- Platform: darwin
- Terminal: cursor
- Version: 1.0.61
- Feedback ID: 51e1dd36-31b1-4c90-b76e-2e88cc0ecccf
Errors
[{"error":"Error: Command failed: security find-generic-password -a $USER -w -s \"Claude Code\"\nsecurity: SecKeychainSearchCopyNext: The specified item could not be found in the keychain.\n\n at genericNodeError (node:internal/errors:983:15)\n at wrappedFn (node:internal/errors:537:14)\n at checkExecSyncError (node:child_process:882:11)\n at execSync (node:child_process:954:15)\n at i7 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:865:5106)\n at file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:777:49649\n at Q (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:674:14420)\n at kJ (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:777:47087)\n at XH (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:777:45954)\n at Y9 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:777:52275)","timestamp":"2025-07-27T11:45:41.681Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"messages.126.content.0.image.source.base64: image cannot be empty\"}}\n at i4.generate (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1317:7796)\n at DP.makeStatusError (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1334:2101)\n at DP.makeRequest (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1334:5315)\n at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n at async UvB.kG1.showErrors (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2902:14365)\n at async kG1 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2345:5642)\n at async UvB (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2902:14216)\n at async file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2902:9271\n at async bL0 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2902:1690)\n at async ne (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2902:9241)","timestamp":"2025-07-27T11:45:47.816Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"messages.126.content.0.image.source.base64: image cannot be empty\"}}\n at i4.generate (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1317:7796)\n at DP.makeStatusError (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1334:2101)\n at DP.makeRequest (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1334:5315)\n at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n at async UvB.kG1.showErrors (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2902:14365)\n at async kG1 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2345:5642)\n at async UvB (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2902:14216)\n at async file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2902:9271\n at async bL0 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2902:1690)\n at async ne (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2902:9241)","timestamp":"2025-07-27T11:46:53.326Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"messages.126.content.0.image.source.base64: image cannot be empty\"}}\n at i4.generate (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1317:7796)\n at DP.makeStatusError (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1334:2101)\n at DP.makeRequest (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:1334:5315)\n at process.processTicksAndRejections (node:internal/process/task_queues:105:5)\n at async UvB.kG1.showErrors (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2902:14365)\n at async kG1 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2345:5642)\n at async UvB (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2902:14216)\n at async file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2902:9271\n at async bL0 (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js:2902:1690)\n at async ne (file:///opt/homebrew/lib/node_modules/@anthropic-ai/claude-code/cli.js
Note: Error logs were truncated.
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗