Cursor, Claude Code and other tools
Most AI-enabled editors, agents and chat front-ends let you bring your own provider. Because Claudech serves both the OpenAI Chat Completions format and the Anthropic Messages format with standard sk- keys, they work with Claudech without plugins or proxies. This page collects the exact settings for the most common tools.
Everything below needs the same three values:
| Value | OpenAI-format tools | Anthropic-format tools |
|---|---|---|
| Base URL | https://api.claudech.com/v1 | https://api.claudech.com |
| API key | sk-... from API keys | same key |
| Model | A slug from Models, e.g. claude-opus-5-5 | same slugs |
If the setting is called "OpenAI API key" or "OpenAI-compatible", use the first column. If it is called "Anthropic API key" or asks for an ANTHROPIC_BASE_URL, use the second. Some tools offer both; either works and is billed identically.
Cursor#
Cursor lets you route its chat and inline-edit requests to any OpenAI-compatible endpoint.
- Open Cursor Settings → Models.
- Under OpenAI API Key, paste your Claudech
sk-...key into the API Key field. - Switch on Override OpenAI Base URL and enter exactly
https://api.claudech.com/v1— with/v1, without a trailing slash, nothing after it. - Scroll to the model list. In its search box type a Claudech slug, e.g.
claude-opus-5-5, and click Add Custom Model (Cursor does not read our model list automatically; add each slug you want —claude-fable-5-1,claude-haiku-4-5,claude-opus-5). The name must be exactly our slug and must not match a built-in Cursor model. - There is no Verify button in current Cursor versions: the key is checked on your first request. Open Chat, pick the Claudech model from the model picker, and send a message. Agent mode, tool calls and multi-step edits work as with any other provider.
Requests are sent from Cursor's servers, so the base URL must be publicly reachable; a local proxy will not work. While the override is on, Cursor sends every OpenAI-family request to Claudech, including its built-in OpenAI model names — those are served by your default Claudech model (see Troubleshooting); switch the override off if you want to use Cursor's own models again. Tab completions, Cursor's router ("Auto") and background agents stay on Cursor's models regardless. Cursor requires a paid Cursor plan for custom keys and custom models.
Base URL : https://api.claudech.com/v1
API key : sk-...
Models : claude-opus-5-5, claude-fable-5-1, claude-haiku-4-5Claude Code#
Claude Code reads its endpoint from environment variables. Set them in your shell profile (or a project .env that your shell loads) and launch as normal:
export ANTHROPIC_BASE_URL="https://api.claudech.com"
export ANTHROPIC_AUTH_TOKEN="sk-..." # sent as Authorization: Bearer
export ANTHROPIC_MODEL="claude-fable-5-1" # main model
export ANTHROPIC_SMALL_FAST_MODEL="claude-haiku-4-5" # background / quick tasks
claudeANTHROPIC_API_KEY (sent as x-api-key) works too; use one or the other. You can also pin these in ~/.claude/settings.json under "env" so they apply to every session. Inside Claude Code, /model lets you switch between any Claudech slug you published (for example claude-fable-5-1, trial-flag).
Claude Code talks to POST /v1/messages, not /v1/chat/completions. Do not point ANTHROPIC_BASE_URL at the OpenAI path.
Recent Claude Code releases (2.1.154+) sometimes put hook output in messages[].role = "system". The Anthropic spec expects system text in the top-level system field only. Claudech normalizes those requests automatically so Claude Code works without a local proxy. If you still see messages.1.role: Invalid option on an older Claudech build, run claud-update on the server.
Cline and Roo Code#
Both extensions support an OpenAI Compatible provider and an Anthropic provider with a custom base URL.
- Provider: OpenAI Compatible
- Base URL:
https://api.claudech.com/v1 - API key:
sk-... - Model ID:
claude-opus-5-5(or any Claudech slug)
Enable Supports images for vision-capable models and leave Supports computer use off.
Continue#
Add Claudech to ~/.continue/config.yaml:
models:
- name: Claude Opus 5.5
provider: openai
model: claude-opus-5-5
apiBase: https://api.claudech.com/v1
apiKey: sk-...
roles: [chat, edit, apply]
- name: Claude Haiku 4.5
provider: openai
model: claude-haiku-4-5
apiBase: https://api.claudech.com/v1
apiKey: sk-...
roles: [autocomplete]Aider#
export OPENAI_API_BASE=https://api.claudech.com/v1
export OPENAI_API_KEY=sk-...
aider --model openai/claude-opus-5-5Zed#
In ~/.config/zed/settings.json:
{
"language_models": {
"openai": {
"api_url": "https://api.claudech.com/v1",
"available_models": [
{ "name": "claude-opus-5-5", "display_name": "Claude Opus 5.5", "max_tokens": 128000 }
]
}
}
}Then set the OpenAI API key in the assistant panel to your sk-... key.
Open WebUI, LibreChat and other chat front-ends#
Add a new OpenAI API connection:
- URL:
https://api.claudech.com/v1 - Key:
sk-...
The front-end will call GET /v1/models and list every Claudech model your plan allows. Nothing else needs configuring.
LiteLLM and other proxies#
If you fan out across providers with LiteLLM, add Claudech as an OpenAI-compatible backend:
model_list:
- model_name: claude-opus-5-5
litellm_params:
model: openai/claude-opus-5-5
api_base: https://api.claudech.com/v1
api_key: os.environ/CLAUDECH_API_KEYTroubleshooting#
| Symptom | Cause | Fix |
|---|---|---|
401 invalid_api_key | Key pasted with whitespace, or a revoked key | Re-copy the key; check its status under API keys |
404 model_not_found | Tool is sending a model name Claudech does not know and the unknown-model fallback is off | Use a Claudech slug from GET /v1/models; do not prefix it with a vendor name |
Response model differs from the one you asked for | The tool asked for a vendor name (e.g. gpt-4o); Claudech served your default model instead of failing | Add the Claudech slug in the tool and select it; the x-claud-model header always names the model that ran |
403 model_not_in_plan | Model is not included in your plan | Upgrade, or pick a model your plan allows |
402 insufficient_balance | Wallet is empty | Top up under Billing; no KYC or card required |
| Tool says "verification failed" or "Invalid API key" on the first message | Base URL has a trailing slash, is missing /v1, or the key has whitespace | Use exactly https://api.claudech.com/v1; re-copy the key |
| Cursor: Add Custom Model does nothing | The name matches one of Cursor's built-in models | Use the Claudech slug exactly (claude-opus-5-5), not a vendor name |
PowerShell shows I’m instead of I'm | Windows PowerShell 5.1 console encoding, not the API | Run $OutputEncoding = [Console]::OutputEncoding = [System.Text.UTF8Encoding]::new() once per session, or use PowerShell 7 |
Claude Code: messages.1.role / Invalid option: expected one of "user"|"assistant" | Claude Code 2.1.154+ sent role: "system" inside messages[] | Update Claudech (claud-update); we hoist that into the top-level system field. Base URL must be https://api.claudech.com (no /v1/chat/completions) |
Claude Code: thinking.type: Invalid option | Claude Code 2.1.221+ sends thinking: { type: "adaptive" } | Update Claudech (claud-update); we accept adaptive/enabled/disabled and map effort via output_config |
Claude Code: tools.N.description: Too big | Built-in tool schemas exceed a 4k description cap | Update Claudech (claud-update); we allow up to 80k characters per tool description |
| Cursor: "Invalid API key. Unauthorized User API key" and nothing appears in your Claudech usage | Cursor's own servers refused the request before contacting Claudech. Happens on Cursor's Free/Hobby plan (custom keys need Cursor Pro or higher), when the custom model name collides with a Cursor built-in, or when the base URL was not saved | Check your Cursor plan; rename the model to a unique id such as claude-opus-5-5; re-enter the base URL, save, restart Cursor, start a new chat. Verify with the PowerShell/curl example in the Quickstart — if that works, Claudech is fine |
| Streaming stops early | Tool timeout shorter than the response | Raise the tool's timeout or lower max_tokens |
Still stuck? Open a ticket from the Support page with the x-request-id header of a failing request and we will trace it.