Cursor can send OpenAI-family model requests to XiuRouter through its OpenAI base URL override. The override is global, so record the existing setting and test Ask before relying on Agent.
Before you start
- Update Cursor to the current stable release.
- Create a dedicated XiuRouter API key for Cursor.
- Select an exact OpenAI-family model ID from the current XiuRouter catalogue.
- Do not add a workstation IP restriction to this key; Cursor can send requests from its own service.
Configure the connection
- Open Cursor Settings → Models.
- Record the current OpenAI API key source and base URL when replacing an existing connection.
- Paste the XiuRouter key into OpenAI API Key.
- Turn on Override OpenAI Base URL.
- Enter:
https://router-api.xiu.ai/v1- Select Verify.
- Add and select the exact XiuRouter model ID in the same page.
If Cursor already lists the same model ID, select that entry instead of creating a duplicate.
What the override changes
- Ask requests for eligible OpenAI-family models use
/v1/chat/completions. - The override applies globally; Cursor does not provide a different custom provider per model.
- Claude-family and Gemini-family model IDs do not use this OpenAI override.
- Tab completion and features that depend on Cursor-specific models continue through Cursor’s own infrastructure.
- Agent depends on Cursor’s streamed ApplyPatch tool. A model can answer in Ask and still fail to edit files.
Verify in stages
- Ask a short question in Ask mode.
- In XiuRouter’s request verification panel, confirm the same key, model,
/v1/chat/completions, and successful status. - Ask Agent to inspect one file without changing it.
- Make one small reversible edit and inspect the diff.
Do not treat the Verify button alone as proof that Agent tools work with the selected model.
Common failures
| Symptom | Action |
|---|---|
| Key verification fails | Confirm the key is active, includes the selected model, has the correct group scope, and has available credit |
| Ask works but Agent cannot edit | Update Cursor, create a new conversation, and test a model with more reliable tool calling |
| Cursor’s built-in models stop working | Turn off Override OpenAI Base URL to return those models to Cursor’s routing |
| XiuRouter records no matching request | Confirm the conversation was created after enabling the override and uses an eligible OpenAI-family model |
Roll back
Turn off Override OpenAI Base URL, restore the previous key source and model, and create a new conversation. Confirm traffic has returned to the previous route before revoking the Cursor-specific XiuRouter key.
Sources and review date
This page was checked against the current XiuRouter Cursor integration and Cursor’s public model documentation on August 22, 2026. No real key was used to run a billable Cursor Agent edit during this review.