---
title: "Open WebUI 中转配置：添加 OpenAI 连接"
canonical: https://relayswitch.ai/zh/guides/open-webui
generated: 2026-11-12T04:32:50.970Z
source: https://api.relayswitch.io/v1/catalog
base_url: https://api.relayswitch.io/v1
---

配置教程 · 核对于 2026-10-27

# Open WebUI 中转配置

在管理员设置里加一条 OpenAI API 连接：URL 带 /v1，粘贴密钥，全部模型进同一个下拉列表。

## 配置步骤

1.  用管理员账号打开 **Settings** → **Admin** → **Connections**，在 **Manage OpenAI API Connections** 旁点 **\+ Add Connection**。
2.  **Connection Type** 选 **External**。
3.  **URL** 填 `https://api.relayswitch.io/v1`，保留 `/v1`；Open WebUI 自己拼 `/models` 和 `/chat/completions`。
4.  **API Key** 粘贴完整密钥。
5.  点 **Verify Connection**，提示连接已验证再保存；只保存不会测试。
6.  **Model IDs** 留空会自动拉取全部 id；只想显示几个，就逐个填 id 再点 `+`，例如 `claude-sonnet-5-5`。**Prefix ID** 留空，点 **Save**。

text

1`Connection Type: External`

2`URL: https://api.relayswitch.io/v1`

3`API Key: sk-relay-你的密钥`

4`Model IDs: （留空，自动拉取全部 id）`

5

6`# 或用环境变量启动`

7`OPENAI_API_BASE_URL=https://api.relayswitch.io/v1`

8`OPENAI_API_KEY=sk-relay-你的密钥`

资料来源：Open WebUI 的 [OpenAI 兼容接入文档](https://docs.openwebui.com/getting-started/quick-start/connect-a-provider/starting-with-openai-compatible/)（读取于 2026-10-27）。

## 推荐模型

id 照抄到模型字段。价格渲染时读取自目录；人民币为参考价，计费以美元为准。

| 模型 | 开发商 | 输入 / 百万 | 输出 / 百万 |
| --- | --- | --- | --- |
| [Claude Sonnet 5.5](https://relayswitch.ai/zh/models/claude-sonnet-5-5)claude-sonnet-5-5 | Anthropic | $1.20≈ ¥8.16 | $3.00≈ ¥20.41 |
| [GPT-5.5](https://relayswitch.ai/zh/models/gpt-5.5)gpt-5.5 | OpenAI | $1.80≈ ¥12.25 | $9.00≈ ¥61.24 |
| [Gemini 3.5 Flash](https://relayswitch.ai/zh/models/gemini-3.5-flash)gemini-3.5-flash | Google | $1.50≈ ¥10.21 | $9.00≈ ¥61.24 |
| [DeepSeek V4 Pro 0423](https://relayswitch.ai/zh/models/deepseek-v4-pro)deepseek-v4-pro | DeepSeek | $0.792≈ ¥5.39 | $2.376≈ ¥16.17 |
| [GLM 5.3](https://relayswitch.ai/zh/models/glm-5.3)glm-5.3 | Z.ai | $0.3178≈ ¥2.16 | $0.9987≈ ¥6.80 |

美元 / 百万 tokens，人民币参考价按 ECB 2026-11-11 汇率

## 一次会话多少钱

30 轮对话：每轮 2,000 输入 tokens、500 输出 tokens。这个大小是假设；控制台的用量页显示每次请求的真实 tokens 和费用。

| 模型 | 一次会话 |
| --- | --- |
| GLM 5.3glm-5.3 | $0.034≈ ¥0.232 |
| DeepSeek V4 Pro 0423deepseek-v4-pro | $0.0832≈ ¥0.566 |
| Claude Sonnet 5.5claude-sonnet-5-5 | $0.117≈ ¥0.796 |
| Gemini 3.5 Flashgemini-3.5-flash | $0.225≈ ¥1.53 |
| GPT-5.5gpt-5.5 | $0.243≈ ¥1.65 |

按目录实时价计算；人民币参考价按 ECB 2026-11-11 汇率。

## 验证是否接通

先用 curl 列出密钥能调用的模型 id，再在工具里发第一条消息。

bash

1`curl https://api.relayswitch.io/v1/models \`

2 `-H "Authorization: Bearer sk-relay-你的密钥"`

两条都通，剩下的问题就在工具的字段里。请求几秒内出现在控制台的用量页。

常见问题

## 常见问题

Open WebUI 接入时最常见的五个问题。

打开控制台

一分钟内拿到密钥

[获取密钥](https://app.relayswitch.io/console?lang=zh)

或发邮件至 [hello@relayswitch.io](mailto:hello@relayswitch.io)

### 

### 

### 

### 

### 

相关页面

-   [全部配置教程](https://relayswitch.ai/zh/guides)
-   [文档](https://relayswitch.ai/zh/docs)
-   [充值](https://relayswitch.ai/zh/pay)
-   [每日真实模型检测](https://relayswitch.ai/zh/proof)
-   [模型与价格](https://relayswitch.ai/zh/models)
-   [English guide](https://relayswitch.io/guides/open-webui)

## 在 Open WebUI 里用一个密钥调用全部模型

USDT 充值，按 token 预付，无订阅。Base URL https://api.relayswitch.io/v1。

[模型与价格](https://relayswitch.ai/zh/models)[获取密钥](https://app.relayswitch.io/console?lang=zh)

