Tooling · 2026-08-30

Zed on an OpenAI-compatible endpoint
Add a provider in Agent Settings

As of 2026-10-07, Zed's openai_compatible provider takes api_url https://api.qcode.cc/openai/v1 for GPT and GLM / DeepSeek models (e.g. gpt-6-sol, glm-5.3). Claude cannot use the OpenAI-compatible endpoint: add an anthropic_compatible provider with api_url https://api.qcode.cc/api. Copy model ids from /models.

Updated 2026-10-07

Point this tool at the QCode endpoint — one key for Claude, GPT and Chinese models.

#zed#openai_compatible#api_url#BYOK

Takeaways

4

Fields you fill

Official OpenAI-compatible section: provider name, API URL, model id, and context window. Keys go in the settings UI or an env var — not settings.json.

2026-10-07

Docs fetched

zed.dev/docs/ai/use-api-access, first fetched 2026-08-30, re-checked 2026-10-07.

/openai/v1

api_url shape

The official example is https://example.com/v1. QCode's OpenAI-compatible endpoint is https://api.qcode.cc/openai/v1; Zed appends /chat/completions itself, so do not paste it into the URL field, and leave off the trailing slash.

tools

Default capability

openai_compatible defaults tools: true and images: false. Follow the official capabilities table.

What API access means in Zed

Zed is a graphical editor with built-in Agent and Inline Assistant. Official docs call it API access when you have a provider API key or usage billing and wire it in Agent Settings. OpenAI-compatible endpoints are one documented path — not a client-id hack.

What people still search

In 2026-08 threads Zed shows up next to Cursor and OpenCode in “point the editor at an OpenAI-compatible gateway” recipes. This site still had no Zed page. This page answers how the official custom endpoint works, then what to do after you paste QCode.

Timeline

Docs as shipped

Use API Access lists OpenAI-compatible endpoints. Add them in the UI (agent: open settings) or under language_models.openai_compatible in settings.json.

Where keys live

Keys saved in the settings UI go to the system keychain. openai_compatible env vars are generated from the provider id (my-gateway → MY_GATEWAY_API_KEY). Do not put keys in settings.json.

2026-08-30

That wording still holds on this fetch. custom_headers can add extra HTTP headers; headers Zed manages (including Authorization) are ignored with a warning if you try to override them.

Confirmed vs watch-outs

Confirmed

Zed documents openai_compatible and anthropic_compatible: custom api_url, model id, context window. Keys via UI or env. openai_compatible defaults to tools: true. Docs re-checked 2026-10-07.

Watch-outs

Official: do not put API keys in settings.json. custom_headers cannot override Authorization. External Agents and Terminal Threads often configure models in the agent itself — a different path from Zed-owned AI features.

Which path

openai_compatible (this page)

Use this when you have a custom base URL. For QCode enter https://api.qcode.cc/openai/v1 and use it for GPT and GLM / DeepSeek models only; Claude goes through anthropic_compatible (https://api.qcode.cc/api).

First-party providers

Anthropic / OpenAI / Google AI keys still use their own blocks. A ChatGPT Plus subscription is not an API key; official docs split subscription vs API access.

What to do next

① Open Agent Settings (agent: open settings), click Add Provider under LLM Providers, and fill a provider name, API URL https://api.qcode.cc/openai/v1, a GPT or GLM / DeepSeek model id from /models (e.g. gpt-6-sol, glm-5.3), and the context window. ② For Claude, click Add Provider again and choose Anthropic (anthropic_compatible in settings.json), with API URL https://api.qcode.cc/api, no /v1, and a model such as claude-sonnet-5. ③ Enter the API key in the settings UI or in the env var Zed generates from the provider name (upper snake case plus _API_KEY) — never in settings.json — then pick the model in the Agent panel. Switching models is an id change.

On QCode

QCode's OpenAI-compatible endpoint is https://api.qcode.cc/openai/v1 and serves GPT and GLM / Kimi / DeepSeek / Qwen; Claude only runs on the Anthropic endpoint https://api.qcode.cc/api, and mixing them up returns model_not_available_on_endpoint. One key works on both. Which model ids work is the live /models list — this page does not freeze a catalog as always-on-sale.

FAQ

Can Zed talk to a custom OpenAI-compatible gateway?

Yes. Use API Access has an OpenAI-compatible endpoints section. UI or settings.json.

How far down should api_url go?

Stop at /openai/v1: https://api.qcode.cc/openai/v1. Zed appends /chat/completions itself. For Claude via anthropic_compatible, use https://api.qcode.cc/api without /v1.

Can I put the key in settings.json?

Official docs say no. Use the settings UI (keychain) or an environment variable.

Does ChatGPT Plus count as an API key?

Official docs split ChatGPT subscriptions from OpenAI API access. This page is the API-key / compatible-endpoint path.

Can I override Authorization with custom_headers?

Official observation: Zed-managed headers including Authorization are ignored with a warning if you try to override them. This page is not a bypass recipe.

Where do model ids come from?

The live /models catalog. Copy the id into available_models.name.

Sources

Zed Use API Access (zed.dev/docs/ai/use-api-access), fetched 2026-08-30 and re-checked 2026-10-07. Sections: OpenAI-compatible endpoints, Anthropic-compatible endpoints, API Keys and Environment Variables, Custom Headers. QCode endpoint values follow the docs.qcode.cc Zed and endpoints pages (fetched 2026-10-07).

Add a provider in Zed

GPT and GLM: openai_compatible + https://api.qcode.cc/openai/v1. Claude: anthropic_compatible + https://api.qcode.cc/api.

Try first, then decide

Not sure which tier? Start with Starter ($8.57/mo) and upgrade when you're happy — the unused value of the old plan goes back to your balance.