Enabling your API in Deepsek

Where does the bug appear (feature/product)?

Cursor IDE

Describe the Bug

Enabling your API in Deepsek

Steps to Reproduce

Cursor Settings → API keys →

  1. Open API key
  2. Override OpenAI Base URL
  3. deepseek-reasoner - > add model

Expected Behavior

Work

Screenshots / Screen Recordings

Operating System

Windows 10/11

Version Information

Version: 2.5.17

Additional Information

Request ID: d604133b-2d85-4337-8467-60064ceca72d
{"error":"ERROR_PROVIDER_ERROR","details":{"title":"Provider Error","detail":"We're having trouble connecting to the model provider. This might be temporary - please try again in a moment.","isRetryable":false,"additionalInfo":{},"buttons":[],"planChoices":[]},"isExpected":true}
Provider Error We're having trouble connecting to the model provider. This might be temporary - please try again in a moment.
sXt: Provider Error We're having trouble connecting to the model provider. This might be temporary - please try again in a moment.
    at cpA (vscode-file://vscode-app/c:/Users/%D0%9D%D0%B8%D0%BA%D0%B8%D1%82%D0%B0/AppData/Local/Programs/cursor/resources/app/out/vs/workbench/workbench.desktop.main.js:32115:39729)
    at opA (vscode-file://vscode-app/c:/Users/%D0%9D%D0%B8%D0%BA%D0%B8%D1%82%D0%B0/AppData/Local/Programs/cursor/resources/app/out/vs/workbench/workbench.desktop.main.js:32115:38717)
    at ppA (vscode-file://vscode-app/c:/Users/%D0%9D%D0%B8%D0%BA%D0%B8%D1%82%D0%B0/AppData/Local/Programs/cursor/resources/app/out/vs/workbench/workbench.desktop.main.js:32116:5088)
    at lol.run (vscode-file://vscode-app/c:/Users/%D0%9D%D0%B8%D0%BA%D0%B8%D1%82%D0%B0/AppData/Local/Programs/cursor/resources/app/out/vs/workbench/workbench.desktop.main.js:32116:9098)
    at async ort.runAgentLoop (vscode-file://vscode-app/c:/Users/%D0%9D%D0%B8%D0%BA%D0%B8%D1%82%D0%B0/AppData/Local/Programs/cursor/resources/app/out/vs/workbench/workbench.desktop.main.js:44360:7632)
    at async fOl.streamFromAgentBackend (vscode-file://vscode-app/c:/Users/%D0%9D%D0%B8%D0%BA%D0%B8%D1%82%D0%B0/AppData/Local/Programs/cursor/resources/app/out/vs/workbench/workbench.desktop.main.js:44408:8884)
    at async fOl.getAgentStreamResponse (vscode-file://vscode-app/c:/Users/%D0%9D%D0%B8%D0%BA%D0%B8%D1%82%D0%B0/AppData/Local/Programs/cursor/resources/app/out/vs/workbench/workbench.desktop.main.js:44408:9837)
    at async ALe.submitChatMaybeAbortCurrent (vscode-file://vscode-app/c:/Users/%D0%9D%D0%B8%D0%BA%D0%B8%D1%82%D0%B0/AppData/Local/Programs/cursor/resources/app/out/vs/workbench/workbench.desktop.main.js:32182:15752)
    at async Tr (vscode-file://vscode-app/c:/Users/%D0%9D%D0%B8%D0%BA%D0%B8%D1%82%D0%B0/AppData/Local/Programs/cursor/resources/app/out/vs/workbench/workbench.desktop.main.js:43415:4779)

Does this stop you from using Cursor

No - Cursor works, but with this issue

Hello!

In this case, DeepSeek returned a 400 error in response to the API request.

Unfortunately, there is limited action we can take on our end, as we do not have visibility into the specific cause of the failure. To give you an example of what we see returned:

Failed to deserialize the JSON body into the target type: tools[0]: missing field `type` at line 1 column 15135

Cursor’s agent mode constructs requests in OpenAI-compatible format, but some providers have different parsers that reject certain valid patterns.

We’d recommend reaching out to DeepSeek’s support to confirm their API’s compatibility with the OpenAI chat completions format, specifically around tool call messages!

There are also some open source projects around this, like GitHub - danilofalcao/cursor-deepseek: A high-performance HTTP/2-enabled proxy server designed specifically to enable Cursor IDE's Composer to use DeepSeek's and OpenRouter's language models. This proxy translates OpenAI-compatible API requests to DeepSeek/OpenRouter API format, allowing Cursor's Composer and other OpenAI API-compatible tools to seamlessly work with these models.