> ## Documentation Index
> Fetch the complete documentation index at: https://docs.qoder.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Forward Mode 概述

> 更低门槛把 Agent 落地到业务场景的模式层，基于「企业 / 模板 / 用户」三级配置体系交付 Agent 能力。

Forward Mode 是构建在 [Build Mode](/zh/cloud-agents/api/agents/list) 之上的受管交付层。管理员通过三级配置体系(企业 / 模板 / 身份)预设好 Agent 形态与可用资源,调用方只需传入 `template_id` 与 `identity_id` 即可使用 Agent,无需关注底层运行时细节。

Forward Mode 自带 IM 渠道接入、定时触发(Schedules)和终端用户身份隔离(Identities),适合 SaaS 产品方、业务集成方,以及面向 C 端或大量调用方的团队。

## 基础 URL

所有 Forward 端点均使用生产网关:

```text theme={null}
https://api.qoder.com/api/v1/forward
```

## 认证

所有 Forward 端点都需要 Qoder PAT 认证:

| 头部              | 必选 | 说明             |
| --------------- | -- | -------------- |
| `Authorization` | 是  | `Bearer <PAT>` |

有副作用的 `POST` 端点可接受 `Idempotency-Key` 头。

## 资源族

| 资源                     | 说明                                      |
| ---------------------- | --------------------------------------- |
| **Templates**          | 可复用的 Agent 形态基线,定义默认 Agent 与 Session 配置 |
| **Identities**         | 终端用户身份,支持按身份的配置覆盖与隔离                    |
| **Sessions**           | 基于模板 + 身份发起的对话或任务运行                     |
| **Schedules**          | Cron 或一次性触发的执行                          |
| **Schedule runs**      | Schedules 产生的执行记录                       |
| **Channels**           | 接入外部 IM 渠道                              |
| **Resources Registry** | 将共享资源注册到 Forward                        |

## 错误信封

错误使用 Forward 错误信封:

```json theme={null}
{
  "type": "error",
  "request_id": "req_xxx",
  "error": {
    "type": "invalid_request_error",
    "code": "invalid_request_body",
    "message": "invalid request body"
  }
}
```

## 相关

<CardGroup cols={2}>
  <Card title="创建 Template" icon="file-plus" href="/zh/cloud-agents/api/forward/templates/create" />

  <Card title="创建 Session" icon="comment" href="/zh/cloud-agents/api/forward/sessions/create" />
</CardGroup>
