LobeChat / LobeHub

Configure shared server credentials or a personal OpenAI provider in LobeChat / LobeHub.

Install and prepare

For a private instance, install Docker and follow LobeHub’s current Docker deployment. Complete its required database, object storage and authentication configuration before adding model variables. Keep the release’s Compose files and existing secrets; the snippet below is an addition to the application environment, not a complete deployment. Open your instance and sign in. Obtain a routerra.ai key and an exact model ID available to it.

Configure the connection

For server-managed access, set OPENAI_API_KEY=YOUR_API_KEY, OPENAI_PROXY_URL=https://routerra.ai/v1 and OPENAI_MODEL_LIST=-all,+YOUR_MODEL_ID on the Lobe application service, then recreate it. -all hides built-in models and + adds your exact ID; it does not grant permissions at the gateway. The server key serves users allowed by your instance. For a personal key instead, open Settings → Language Model → OpenAI, enable the provider, enter your API Key and custom API Proxy Address https://routerra.ai/v1, then add/enable the exact model in model management.

OPENAI_API_KEY=YOUR_API_KEY
OPENAI_PROXY_URL=https://routerra.ai/v1
OPENAI_MODEL_LIST=-all,+YOUR_MODEL_ID

Select a model and resolve errors

Choose OpenAI and YOUR_MODEL_ID in a new conversation and send text. A missing model usually means the provider or model is disabled, or the application was not recreated after changing environment variables. If personal settings still point elsewhere, correct that provider’s saved proxy/key before retrying. For 401 errors, distinguish instance sign-in from the gateway key. Check application container logs for upstream errors; enabling vision/tools in the UI does not add those capabilities to a model.