Openrouter Fails when Using Anthropic Models

I am using openrouter by overriding OpenAI Base URL, like this:

When I use an Anthropic model, I get this error:

This does not happen when I use another provider like OpenAI.

From the error message above, “Problem reaching Anthropic”, it appears that the request is NOT sent to Openrouter, but to Anthropic. The error also looks like it is sent from Anthropic.

This bug is related to the following post, but more specific to Anthropic only:

This is my Cursor version:
Version: 0.36.2
VSCode Version: 1.89.1
Commit: 9a6d781540ba2732cf26551c07629e68121c6580
Date: 2024-07-07T21:57:45.723Z
Electron: 28.2.8
ElectronBuildId: undefined
Chromium: 120.0.6099.291
Node.js: 18.18.2
V8: 12.0.267.19-electron.0
OS: Windows_NT x64 10.0.19045