NezhaGateNezhaGate

LobeHub can add custom AI providers. Choose the OpenAI request format with the address up to /v1 and every NezhaGate model is available; self-hosted instances can use environment variables instead.

Written against LobeHub 2.2

Add a custom provider

  1. Open App Settings → AI Providers and click Add Custom Provider.
  2. Give a lowercase Provider ID (lowercase letters, digits, - and _; it cannot be changed later), choose OpenAI as Request Format, enter https://nezhagate.com/v1 as Proxy URL and your key as API Key, then click Create.
  3. On the provider page click Fetch models, or add models by hand with Add Model, setting the maximum context window and ticking tool calling and vision where the model has them.
  4. Enable the models you want and pick one in a chat.
Proxy URLhttps://nezhagate.com/v1

Keep Use Client Request Mode off (the NezhaGate API does not accept cross-origin browser requests), and keep Use Responses API Specification off as well.

Claude (optional)

Add a second custom provider with Anthropic as Request Format and https://nezhagate.com/anthropic as Proxy URL.

Self-hosted: environment variables

A self-hosted LobeHub can be pointed at NezhaGate with environment variables:

.env
OPENAI_API_KEY=YOUR_API_KEY
OPENAI_PROXY_URL=https://nezhagate.com/v1
OPENAI_MODEL_LIST=-all,+gpt-5.5,+claude-sonnet-5
ANTHROPIC_API_KEY=YOUR_API_KEY
ANTHROPIC_PROXY_URL=https://nezhagate.com/anthropic

In OPENAI_MODEL_LIST, -all hides every built-in model, +model-id adds a NezhaGate model, and +model-id=Display name also sets its display name.

Test

In Connectivity Check on the provider page, pick a model and click Check (it sends one short message); Check passed means you are done.

Troubleshooting

No reply, or an empty reply

The proxy URL must include /v1: https://nezhagate.com/v1.

Failed to fetch models

Check the key and the proxy URL; you can also add models by hand with Add Model.

CORS errors in the browser console

Switch Use Client Request Mode off so the requests go out from LobeHub's server.

More integrations