claude-code - 💡(How to fix) Fix /model claude-opus-4-7 fails with "thinking.type.enabled" not supported error [3 comments, 4 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#49219Fetched 2026-04-17 08:47:30
View on GitHub
Comments
3
Participants
4
Timeline
11
Reactions
6
Author
Timeline (top)
cross-referenced ×4commented ×3labeled ×3subscribed ×1

Switching to claude-opus-4-7 via the /model command fails with an API error about an unsupported thinking config format.

Error Message

API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"\"thinking.type.enabled\" is not supported for this model. Use \"thinking.type.adaptive\" and \"output_config.effort\" to control thinking behavior."},"request_id":"req_011Ca7eP18tycjccNePYz3Wy"}

Root Cause

Switching to claude-opus-4-7 via the /model command fails with an API error about an unsupported thinking config format.

Code Example

API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"\"thinking.type.enabled\" is not supported for this model. Use \"thinking.type.adaptive\" and \"output_config.effort\" to control thinking behavior."},"request_id":"req_011Ca7eP18tycjccNePYz3Wy"}
RAW_BUFFERClick to expand / collapse

Description

Switching to claude-opus-4-7 via the /model command fails with an API error about an unsupported thinking config format.

Error

API Error: 400 {"type":"error","error":{"type":"invalid_request_error","message":"\"thinking.type.enabled\" is not supported for this model. Use \"thinking.type.adaptive\" and \"output_config.effort\" to control thinking behavior."},"request_id":"req_011Ca7eP18tycjccNePYz3Wy"}

Steps to reproduce

  1. Start a session on any model (e.g. claude-sonnet-4-6)
  2. Run /model claude-opus-4-7

Expected behavior

Model switches successfully.

Actual behavior

400 error — the harness appears to be sending thinking: { type: "enabled" } in the API request, but claude-opus-4-7 requires thinking: { type: "adaptive" } with output_config.effort instead.

Environment

  • Claude Code version: 2.1.110
  • OS: macOS Darwin 25.3.0

extent analysis

TL;DR

Update the API request to use thinking: { type: "adaptive" } with output_config.effort for the claude-opus-4-7 model.

Guidance

  • Verify that the claude-opus-4-7 model requires thinking.type to be set to "adaptive" and output_config.effort to be specified.
  • Check the current API request payload and update it to replace thinking: { type: "enabled" } with thinking: { type: "adaptive" } and add the required output_config.effort parameter.
  • Test the updated API request to ensure the model switch is successful.
  • Review the documentation for the claude-opus-4-7 model to understand the valid values for output_config.effort.

Example

{
  "thinking": {
    "type": "adaptive"
  },
  "output_config": {
    "effort": "value" // replace with a valid effort value
  }
}

Notes

The exact valid values for output_config.effort are not specified in the issue, so it's essential to review the model's documentation to determine the correct value.

Recommendation

Apply workaround: update the API request to use the required thinking and output_config parameters for the claude-opus-4-7 model, as this is a specific requirement for this model and not a version-related issue.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

Model switches successfully.

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING