Unauthorized User API key with custom openai api key/url

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

Tried to use custom OpenAI provider url and API key, and can not use any model besides gpt-4.1.

Attempted to make API call directly just to see if token is working and see no issues.

Steps to Reproduce

Set custom OpenAI base url and API key, try to use any model, for example gpt-5-mini

Expected Behavior

Expected the model to work

Operating System

MacOS

Current Cursor Version (Menu → About Cursor → Copy)

Version: 1.5.9 (Universal)
VSCode Version: 1.99.3
Commit: de327274300c6f38ec9f4240d11e82c3b0660b20
Date: 2025-08-30T21:02:27.236Z
Electron: 34.5.8
Chromium: 132.0.6834.210
Node.js: 20.19.1
V8: 13.2.152.41-electron.0
OS: Darwin arm64 24.5.0

Additional Information

Tried this with my team plan, can not disable privacy mode there, but here is the requestId:a8cc4ecb-3181-4ab8-9945-256682b1de40

Created a free personal account to reproduce the issue, same behavior, and privacy mode is not enabled, here is a requestId: 3ad7a234-c09b-403f-91a1-8bc6ffd40e36

Does this stop you from using Cursor

Sometimes - I can sometimes use Cursor

Hey, thanks for the report. Could you please let me know what base URL you have set in your settings?

Can I DM it to you somehow? don’t want to share the URL in public.