Codex image requests return 400 through proxy: base64 inflation or invalid detail
Quick fix
If image history causes context overflow, upgrade to v3.19.0; if detail original is invalid, disable supports_image_detail_original for the affected model.
Symptom
Section titled “Symptom”CC Switch local proxy failed while handling Codex endpoint /responses. Provider: DouBaoSeed; model: doubao-seed-2-1-pro-260628; upstream_status: HTTP 400; cause: The parameter `messages.content.image_url.detail` specified in the request are not valid: invalid value: `original`, supported values are: `low`, `high`, `xhigh`, and `auto`. Request id: ...These issues all involve Codex image requests triggering upstream HTTP 400 after conversion by the CC Switch local proxy, but the causes differ: In #4465, a Responses image tool result was converted to base64 plain text, causing token inflation and context overflow; the maintainer confirmed this was fixed in v3.19.0. In #6495, the proxy passed `detail: "original"` through to a Doubao upstream that does not support that value; a comment recommends disabling this capability through `supports_image_detail_original` in the model catalog. #4723 reports that the upstream does not support the `reasoning` parameter; the thread gives inconsistent information about the AgentPlan and CodingPlan URL and does not provide a confirmed fix, so it cannot be classified as an image issue or addressed with the image fix.
If the error says the `original` value for `image_url.detail` is invalid, set `supports_image_detail_original` to `false` for the affected model in `cc-switch-model-catalog.json`. This is a temporary workaround suggested in an issue comment.
If image history causes request context overflow, upgrade to v3.19.0; the maintainer said this version extracts images from tool results and forwards them in native image format.
If the error says the upstream does not support the `reasoning` parameter, the issue thread does not provide a confirmed working configuration fix; verify the provider and interface type before continuing troubleshooting.
Affected Versions
Section titled “Affected Versions”Source Issues
Section titled “Source Issues”This page is distilled from 3 real issues
- Can upgrading to v3.18.0 fix Responses image forwarding?
- Comments on #4465 say the fix is in v3.19.0; another comment on #4465 also notes that v3.18.0 does not yet include the related media extraction change.
- What is a temporary workaround if Doubao does not support `detail: "original"`?
- A comment on #6495 recommends setting `supports_image_detail_original` to `false` for the affected model in `cc-switch-model-catalog.json`.
- Why does it still say reasoning is unsupported after removing `model_reasoning_effort`?
- In #4723, the reporter said the error persisted after removing this setting, but the discussion did not confirm an effective remedy; a comment also notes that AgentPlan and CodingPlan use different URLs.
Related problems
Section titled “Related problems”This is an unofficial community wiki with no affiliation to the cc-switch authors or the project itself. Its content is compiled from the project's public GitHub issues. This site distributes no software.