Composer 2.5 error "This model does not support custom API keys"

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

When I am using “Override OpenAI Base URL” in settings, it makes agent with selected “Composer 2.5” model throw an error:

This model does not support custom API keys

This does not happen when “Auto” model selection is on.
The override itself, for OpenAI models is working fine.

Steps to Reproduce

  1. Enable in Settings/Models "Override OpenAI Base URL and set any url (not relevant for reproducing bug)
  2. Enable OpenAI API Key and set any key (not relevant for reproducing bug)
  3. Send any message to Composer 2.5 agent (not Auto)

Expected Behavior

OpenAI models and/or manually added model identifiers to be routed to OpenAI Base URL override, while the Composer 2.5 model to work as usual, as with override turned off.

Operating System

MacOS

Version Information

Version: 3.7.36
VS Code Extension API: 1.105.1
Commit: 776d1f9d76df50a4e0aeca61819a88e7c1b861e0
Date: 2026-06-13T00:31:56.287Z
Layout: glass
Build Type: Stable
Release Track: Default
Electron: 39.8.1
Chromium: 142.0.7444.265
Node.js: 22.22.1
V8: 14.2.231.22-electron.0
xterm.js: 6.1.0-beta.256
OS: Darwin arm64 25.5.0

For AI issues: which model did you use?

Composer 2.5

Does this stop you from using Cursor

No - Cursor works, but with this issue

hey @vladpazych, you cannot use composer model or other non supported model via your api key when you turned on Overide OpenAI Base URL, this is by default, every call made to all model needs to pass through your OpenAI api sub, if you want to regain access to composer model and be billed via Cursor subscription, you need to turn off this toggle, quick tips, to not have to re enter your api key everytime, you can just disable the OpenAI API Key toggle, it won’t delete either the api key or the url.

Hey, thanks for the report. This isn’t a bug, it’s the current by design behavior.

Composer (1, 1.5, 2, 2.5) are Cursor’s own models, and they don’t work with BYOK keys. When OpenAI API Key / Override OpenAI Base URL is enabled, the key gets attached to all requests, including Composer, so you’ll see the error “This model does not support custom API keys”. On Auto, this doesn’t happen because the key isn’t attached to those requests.

Workaround:

  • Turn off the OpenAI API Key toggle with Cmd+Shift+0 while using Composer. This won’t remove your key or URL, so you won’t need to re-enter them.
  • Or use Auto.

What you described in Expected Behavior, per-model routing so the key is automatically removed for Cursor models, is a known QoL improvement. It’s on our radar, but there’s no ETA yet.