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

# 网页搜索

> 为任何模型的响应提供实时网络数据支撑。使用 web 插件或 :online 后缀 — 或迁移到 Server Tools 以实现模型驱动的搜索。

<Warning>
  `web` 插件和 `:online` 模型后缀已**废弃**。它们仍可继续使用，但新集成应改用 [Server Tools](/zh/guides/features/server-tools/overview)。
</Warning>

ARouter 支持为任何模型提供网页搜索接地能力。通过在模型标识符后附加 `:online` 或使用 `web` 插件来激活。

## 快速开始

```json theme={null}
{"model": "openai/gpt-5.4:online"}
```

或：

```json theme={null}
{"model": "openai/gpt-5.4", "plugins": [{"id": "web"}]}
```

## 自定义 web 插件

```json theme={null}
{
  "model": "openai/gpt-5.4",
  "messages": [...],
  "plugins": [{"id": "web", "max_results": 3}]
}
```

| 参数                | 类型         | 默认值  | 说明                                     |
| ----------------- | ---------- | ---- | -------------------------------------- |
| `id`              | `string`   | —    | 必须为 `"web"`                            |
| `max_results`     | `number`   | `5`  | 最大搜索结果数量                               |
| `engine`          | `string`   | auto | 搜索引擎：`"native"`、`"exa"` 或 `"parallel"` |
| `include_domains` | `string[]` | —    | 仅返回来自这些域名的结果                           |
| `exclude_domains` | `string[]` | —    | 排除来自这些域名的结果                            |

## 迁移到 Server Tools

请参阅 [Server Tools — 网页搜索](/zh/guides/features/server-tools/overview) 获取迁移指南。
