Zed
Add Merge Gateway as an OpenAI-compatible provider in Zed’s Assistant Panel.
Zed supports any OpenAI-compatible provider via a language_models.openai_compatible block in settings.json. Point it at Merge Gateway and every Gateway model (OpenAI, Anthropic, Google, Kimi, and more) becomes available in the Assistant Panel and inline assists.
Before you start
- Grab an API key from gateway.merge.dev/settings/api-keys.
- Pick the Gateway models you want to expose in Zed (you’ll list them in
available_models). Model names use theprovider/modelformat, e.g.anthropic/claude-opus-4.6.
Configure Zed
Open settings.json
In Zed, run the command zed: open settings (via the command palette) to open your user settings.json.
Add Gateway as a provider
Add the following under language_models. The top-level key (Merge Gateway in this example) is the display name that appears in Zed’s model picker.
Set the API key
Zed reads the API key from an environment variable named after the provider. Take the provider name, uppercase it, replace non-alphanumeric characters with underscores, and add an _API_KEY suffix.
For "Merge Gateway":
Add the export to your shell profile so Zed inherits it on next launch.
Restart Zed and pick the model
Restart Zed so it picks up the new env var. Open the Assistant Panel, click the model picker, and select one of your Gateway models. Send a test message and the request will appear in your Gateway dashboard.
Caveats
Model capabilities are declared by you
Zed trusts the capabilities block you write. If you set "tools": true for a route that doesn’t support tool calling, Zed will try to use it and the request will fail at the provider. Use GET /v1/models and check vendors.<vendor>.capabilities.supports_tool_calling on the route you plan to use.
API keys go through environment variables, not settings.json
Zed reads custom-provider API keys from environment variables only. Don’t paste your Gateway key into settings.json.
Responses API vs chat completions
The provider block above uses Gateway’s chat completions endpoint, which Zed drives by default. If you need to force the Responses API for a specific model, set "chat_completions": false on that model entry.