Cursor
Cursor is an AI code editor. Its OpenAI settings accept any OpenAI-compatible API, so you can use Entrim models in Cursor's chat and agent.
Before you start
Cursor's custom API settings come with a few limits:
- Custom models work in chat and agent. Tab completion always uses Cursor's own models.
- Cursor sends every request through its own servers, which then call Entrim, so your prompts and your API key pass through Cursor on the way.
- The base URL override applies to all models in Cursor, including Cursor's built-in ones. While it's on, only your custom models work. To use Cursor's models again, turn it off.
Prerequisites
To follow this guide, you need:
Set up Cursor
1. Open the model settings
Open Cursor Settings with the gear icon in the top-right corner, then select Models.
2. Add your Entrim API key
Under API Keys, turn on OpenAI API Key and paste your Entrim API key. Cursor labels the field "OpenAI", but the key goes to whichever base URL you set in the next step.
3. Point Cursor at Entrim
Turn on Override OpenAI Base URL and enter:
https://api.entrim.ai/v1
Don't add a trailing slash or /chat/completions. Cursor appends the path itself.
4. Add the model
Select + Add Custom Model, enter the model ID and make sure its toggle is on:
zai-org/GLM-5.3-Flash
The ID must match an ID from GET /v1/models exactly, including upper and lower case.
5. Chat with the model
Open the chat with Cmd+L on macOS or Ctrl+L on Windows and Linux, choose zai-org/GLM-5.3-Flash in the model menu and send a message.
Switch back to Cursor's models
While Override OpenAI Base URL is on, Cursor sends requests for its built-in models to Entrim too, and they fail. To use Cursor's models, turn the override off in Cursor Settings > Models. Turn it on again when you want to use Entrim.
Troubleshooting
| Problem | Fix |
|---|---|
"Invalid API key" or 401 errors | Paste the full key again from the dashboard, with no spaces around it. |
400 "Invalid model name" | The custom model name doesn't match an Entrim model ID. Compare it with GET /v1/models. |
| Cursor's own models stopped working | The base URL override is on. Turn it off to use them. |
| There's no Override OpenAI Base URL option | Update Cursor. Whether the option is shown can also depend on your Cursor plan. |