﻿# 快速开始

Flux 是统一的大语言模型接口：通过统一的 API Key 在各类客户端中调用主流大模型。

::: details For AGENTS
批量读取 Markdown 文档时，可直接使用 [markdown-sitemap.xml](https://docs.tryflux.net/markdown-sitemap.xml)。单页读取时，直接在不以 `/` 结尾的文档 URL 后追加 `.md` 即可，例如 `/docs/quickstart.md`。
:::

## 接入流程

1. 在下方选择客户端，到 [模型广场](https://tryflux.net/models) 确认目标模型所在分组支持所需协议和客户端。
2. 查看 [计费说明](https://docs.tryflux.net/docs/flux/billing.md)，确认价格后前往 [充值中心](https://tryflux.net/purchase) 充值账户余额。
3. [创建 API Key](https://docs.tryflux.net/docs/flux/create-apikey.md)，选择已确认的分组。
4. 按下方客户端教程填入 Key、端点和模型 ID。
5. 发送一条消息，核对回复和使用记录，[确认接入成功](#确认接入成功)。

分组、号池、账户余额计费等术语见 [核心概念](https://docs.tryflux.net/docs/concepts.md)。

## 客户端选型

<DocsTabs default-tab="agent">
  <DocsTab title="Agent" name="agent">

适合在终端工作、有编程需求或希望使用 AI Agent 辅助开发的用户。

按所用客户端查看对应教程。需要统一管理 Claude Code、Codex 等客户端的供应商配置时，可选用 [CC-Switch](https://docs.tryflux.net/docs/agents/cc-switch.md)；它不是接入的前置条件。

| 客户端教程                              | 适用场景                     |
| --------------------------------------- | ---------------------------- |
| [Claude Code](https://docs.tryflux.net/docs/agents/claude-code.md) | Anthropic 官方 CLI，终端编程 |
| [Codex](https://docs.tryflux.net/docs/agents/codex.md)             | OpenAI 官方 CLI 与桌面端     |
| [Codex++](https://docs.tryflux.net/docs/agents/codex-plus-plus.md) | 给 Codex 加装增强能力        |
| [OpenCode](https://docs.tryflux.net/docs/agents/opencode.md)       | 开源终端 Agent，多模型切换   |
| [Pi](https://docs.tryflux.net/docs/agents/pi.md)                   | 可扩展的终端编程 Agent       |
| [Hermes](https://docs.tryflux.net/docs/agents/hermes.md)           | 轻量终端 Agent               |

  </DocsTab>

  <DocsTab title="ChatBot" name="chatbot">

适合偏好图形界面、移动端或以日常对话为主要使用场景的用户。

| 客户端教程                                   | 适用场景                                      |
| -------------------------------------------- | --------------------------------------------- |
| [Cherry Studio](https://docs.tryflux.net/docs/chatbot/cherry-studio.md) | 桌面端（Windows / macOS / Linux），多模型切换 |
| [RikkaHub](https://docs.tryflux.net/docs/chatbot/rikkahub.md)           | Android 手机端，OpenAI 兼容                   |

在客户端设置里添加 Flux 作为自定义服务商，填入 API Key 和 [API 端点](https://docs.tryflux.net/docs/flux/endpoints.md)，获取模型列表后即可开始对话。

  </DocsTab>
</DocsTabs>

## 确认接入成功

1. 在客户端中选择目标模型，新建对话并发送「只回复 OK」。这会产生模型调用费用。
2. 确认收到模型的文本回复，而不只是看到模型列表或「配置已保存」。
3. 在 [使用记录](https://tryflux.net/usage) 中找到本次请求，核对使用的 Key、模型及扣费；分组与创建 Key 时的选择一致。

这只能确认本次文本对话成功。需要工具调用、图片或其他能力时，再验证对应功能。没有回复或记录与预期不符时，见 [排障](https://docs.tryflux.net/docs/troubleshooting.md)。

## 进阶用法

接入完成后可按需使用：

- [创作台](https://tryflux.net/creative) — 无需客户端与 API 配置，网页端在线生成图片
- [复合 Key](https://docs.tryflux.net/docs/flux/composite-key.md) — 一个 Key 绑定多个分组，用前缀切换
- [Fast 模式](https://docs.tryflux.net/docs/flux/fast-mode.md) — 在 Key 上强制开启高优先级通道
- [团队](https://docs.tryflux.net/docs/flux/team.md) — 多人共用所有者的余额，各自建 Key
- [邀请返利](https://docs.tryflux.net/docs/flux/referral.md) — 邀请好友获得充值返利

## 遇到问题

- [排障](https://docs.tryflux.net/docs/troubleshooting.md) — 按症状定位，含反馈模板
- [错误码](https://docs.tryflux.net/docs/errors.md) — 完整错误码清单
- [FAQ](https://docs.tryflux.net/docs/faq.md) — 模型检测等常见问题
- [API 端点](https://docs.tryflux.net/docs/flux/endpoints.md) — 端点选择与废弃线路迁移
- [使用政策](https://docs.tryflux.net/docs/tos/usage-policy.md) — 哪些用法会导致封禁
