Invalid JSON Encoding in API Request Body
Resolved 💬 3 comments Opened Jun 16, 2025 by stavarc Closed Aug 22, 2025
Bug Description
getting this error for every query: "API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"The request body is not valid JSON: no low surrogate in string: line 1 column 245595
(char 245594)"}}"
Environment Info
- Platform: linux
- Terminal: cursor
- Version: 1.0.24
- Feedback ID: fc62d9bd-f53a-4664-92db-4f6a6ff6d9eb
Errors
[{"error":"Error: 1: 1 The setuid sandbox is not running as root. Common causes:\n * An unprivileged process using ptrace on it, like a debugger.\n * A parent process set prctl(PR_SET_NO_NEW_PRIVS, ...)\nFailed to move to new namespace: PID namespaces supported, Network namespace supported, but failed: errno = Operation not permitted\n[975930:0616/183149.576575:FATAL:zygote_host_impl_linux.cc(207)] Check failed: . : Invalid argument (22)\n\n at pP6 (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1355:4495)\n at async dP6 (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1355:2578)","timestamp":"2025-06-16T15:31:49.724Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"The request body is not valid JSON: no low surrogate in string: line 1 column 245595 (char 245594)\"}}\n at h6.generate (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1329:12578)\n at Lw.makeStatusError (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1344:2082)\n at Lw.makeRequest (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1344:5257)\n at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n at async ME2.K11.showErrors (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:22008)\n at async K11 (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:12203)\n at async ME2 (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:21854)\n at async file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:17103\n at async yt1 (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:5151)\n at async Fu (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:17073)","timestamp":"2025-06-16T15:31:54.112Z"},{"error":"Error: 400 {\"type\":\"error\",\"error\":{\"type\":\"invalid_request_error\",\"message\":\"The request body is not valid JSON: no low surrogate in string: line 1 column 245595 (char 245594)\"}}\n at h6.generate (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1329:12578)\n at Lw.makeStatusError (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1344:2082)\n at Lw.makeRequest (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1344:5257)\n at process.processTicksAndRejections (node:internal/process/task_queues:95:5)\n at async ME2.K11.showErrors (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:22008)\n at async K11 (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:12203)\n at async ME2 (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:21854)\n at async file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:17103\n at async yt1 (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:5151)\n at async Fu (file:///usr/local/lib/node_modules/@anthropic-ai/claude-code/cli.js:1698:17073)","timestamp":"2025-06-16T15:32:05.210Z"}]This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗