Cursor access

Cursor officially supports using its own OpenAI API Key and allows overriding the OpenAI Base URL in model settings. ShangHai Do uses the OpenAI compatible Chat Completions interface, so it is configured according to the OpenAI entrance.

If not yet installed, follow Cursor download page to install the client. An agent is an assistant that can read and write files and carry out tasks.

Check the applicable scope first.

Configuration Steps

1. Open the model settings

  1. Open Cursor.
  2. Enter Cursor Settings → Models.
  3. Expand API Keys at the bottom of the page.

2. Fill in the ShangHai Do key and address

In OpenAI API Key:

  1. Open Use OpenAI API Key.
  2. Fill in the site token YOUR_API_KEY.
  3. Open Override OpenAI Base URL.
  4. Fill in:
https://shanghaido.com/v1

Click Verify. If your ShangHai Do site is not an official site, replace the domain name with your own site root address, but still keep the /v1 at the end.

3. Add model

Add the model name in the custom model area:

qwen3.8-flash

The model name must be exactly the same as id returned by GET /v1/models. Do not write it as Qwen 3.8 Flash, and do not spell /v1 into the model name. After saving, create a new Chat or Agent session and select it in the model selector.

If the Cursor version calls the button Add model or Add custom model, the meaning is the same. The model name should keep the accurate value returned by this site and do not add the claude- prefix; Cursor may use the Anthropic key entry based on this prefix.

**Override OpenAI Base URL is a global setting and cannot be filled in separately for each model. ** After it is turned on, other models using the OpenAI portal may also request the ShangHai Do address; when switching back to other services, the address, key and currently selected model must be checked at the same time.

Get started

Send a normal text first:

请回复:连接成功

After confirming that it can be returned, let the Agent read a small file. When performing project operations, please pay attention to client prompts and confirm tool permissions.

FAQ

still requests Cursor’s own model

Confirm that you have selected qwen3.8-flash in the new Chat or Agent session, and both Use OpenAI API Key and Override OpenAI Base URL are turned on. Team admins may also have Restrict Personal API Keys enabled, which hides or disables personal key entry.

Tab completion does not use ShangHai Do

This is the official current limitation of Cursor: the custom API Key only covers the chat model, and Tab completion continues to use Cursor’s built-in model. Do not judge Chat access failure based on whether the Tab changes.

Prompt model does not exist

Execute first:

curl "https://shanghaido.com/v1/models" -H "Authorization: Bearer YOUR_API_KEY"

Fill in the returned accurate model id back to the Cursor. Also confirm that the Base URL is /v1 and do not fill in /v1/chat/completions.

official information

encountered a problem

If you encounter problems with calling or configuration, please contact the site customer service and provide the model name, error time and error information to facilitate troubleshooting.