---
url: 'https://docs.byesu.com/en/clients/lobechat.md'
description: >-
  Connect LobeChat / LobeHub to byesu API via UI or Docker env vars: run Claude
  5.5, GPT-6.2, Gemini 4, and DeepSeek V4 with 0.1x Claude prompt caching.
---

# Connect LobeChat (LobeHub) to byesu API

Connect **LobeChat / LobeHub** (desktop app, web app, or self-hosted Docker deployment) to **byesu** to access Claude, GPT, Gemini, DeepSeek, and Grok models with one pay-as-you-go API key — including native Anthropic `0.1x` prompt caching.

::: tip Quick configuration

* **OpenAI API Proxy URL**: `https://byesu.com/v1` (all vendors under one provider)
* **Anthropic API Proxy URL**: `https://byesu.com` (native `/v1/messages` + `0.1x` prompt cache reads)
* **API Key**: your byesu token (`sk-...`, created in the default `auto` group)
* **Recommended models**: `claude-opus-5-5`, `claude-sonnet-5-5`, `gpt-6.2-sol`, `deepseek-v4-pro`, `gemini-4-argon`
  :::

## Method 1: LobeChat / LobeHub UI Setup

1. Create an `sk-...` token in the [byesu Console](https://byesu.com) under the default **`auto`** group (see [Choosing a Group](/en/guide/groups)).
2. In LobeChat, click your avatar → **Settings → AI Service Provider** (or **Language Model**).
3. **Unified OpenAI-compatible setup (all models)**:
   * Open **OpenAI** and toggle the provider on.
   * **API Key**: paste your `sk-...` token.
   * **API Proxy Address**:
     ```text
     https://byesu.com/v1
     ```
   * Under **Model List**, add custom model IDs (`claude-opus-5-5`, `claude-sonnet-5-5`, `gpt-6.2-sol`, `gpt-6.1-sol`, `deepseek-v4-pro`, `gemini-4-argon`, `grok-4.7`).
   * Select one of those models in **Connectivity Check** and click **Check Connection**.
4. **Optional Anthropic-native setup (`0.1x` Prompt Caching)**:
   * Open **Anthropic**, paste the same `sk-...` token, and set **API Proxy Address** to `https://byesu.com` (without `/v1`).
   * Routing `claude-opus-5-5`, `claude-sonnet-5-5`, and `claude-haiku-5-5` through the native `/v1/messages` endpoint enables Anthropic Prompt Caching so repeated agent instructions and knowledge-base prefixes bill cache reads as low as **`0.1x`** ([Prompt Caching](/en/guide/prompt-caching)).

## Method 2: Self-Hosted Docker Environment Variables

Deploy a private LobeChat instance for yourself or your team pre-wired to byesu:

```bash
docker run -d --name lobe-chat -p 3210:3210 \
  -e OPENAI_API_KEY="sk-YOUR_BYESU_TOKEN" \
  -e OPENAI_PROXY_URL="https://byesu.com/v1" \
  -e OPENAI_MODEL_LIST="+claude-opus-5-5,+claude-sonnet-5-5,+gpt-6.2-sol,+deepseek-v4-pro,+gemini-4-argon" \
  -e ANTHROPIC_API_KEY="sk-YOUR_BYESU_TOKEN" \
  -e ANTHROPIC_PROXY_URL="https://byesu.com" \
  -e ACCESS_CODE="your-access-password" \
  lobehub/lobe-chat
```

* Prepend `-all,` in `OPENAI_MODEL_LIST` (e.g. `-all,+claude-opus-5-5,+claude-sonnet-5-5,+gpt-6.2-sol,+deepseek-v4-pro,+gemini-4-argon`) if you want to hide LobeChat's built-in default models and show only active byesu models.
* Need `glm-5.3`, `kimi-k3`, or image generation (`gpt-image-2`, `gemini-3.1-flash-image-ultra`)? Create tokens in the `Glm`, `Kimi`, or `media` group. Billing is pay-as-you-go per token with live rates shown in the [byesu Console](https://byesu.com) after sign-in.

## Troubleshooting & Benchmarks

* **Check Connection fails with 404 / no available channel**: LobeChat's **Check Connection** button defaults to a legacy model ID unless changed — pick `gpt-6.2-sol` or `claude-sonnet-5-5` as the test model ([no available channel](/en/errors/no-available-channel-error)).
* **401 invalid\_api\_key**: confirm `https://byesu.com/v1` for OpenAI or `https://byesu.com` for Anthropic, and verify `ACCESS_CODE` if self-hosted ([OpenAI 401 fix](/en/errors/openai-api-401-invalid-api-key)).
* **429 / benchmarks**: see [OpenAI 429 rate limit vs quota](/en/errors/openai-api-429-rate-limit-vs-quota) and [live production benchmarks](https://byesu.com/benchmarks).
