跳转到内容
Alpha
  • 模型
  • 排行榜
  • Ori
联系销售

页脚

OpenRouterOpenRouter
© 2026 OpenRouter, Inc

产品

  • 聊天
  • 排行榜
  • 基准测试
  • 应用
  • 发现
  • 模型
  • Ori
  • 合集
  • 提供商
  • 工具
  • 定价
  • Business
  • Enterprise
  • 实验室

公司

  • 关于
  • 博客
  • 客户
  • 招聘
    招聘
  • 隐私
  • 服务条款
  • 信任中心
  • 支持
  • 兼容 OR
  • 数据
  • 品牌

开发者

  • 文档
  • API 参考
  • 开发者平台
  • 状态
  • AI 站点地图

连接

  • Discord
  • GitHub
  • LinkedIn
  • X
  • YouTube
所有服务器工具

Web search

openrouter:web_search

文档试用此工具

让任何模型都能在请求过程中搜索网页。模型决定何时搜索以及查询什么,OpenRouter 在配置的引擎上执行搜索并返回标题、URL 和摘要,模型再将这些内容整合到回答中并附上引用。

文档试用此工具
工作原理提供商和定价使用此工具基准测试常见问题相关工具

工作原理

适用于需要最新信息的问题,例如本周新闻或今日价格。

  1. 1

    您的模型 判断搜索会有帮助,并编写查询。

  2. 2

    OpenRouter 在配置的引擎上运行它,并返回标题、URL 和摘要。

  3. 3

    您的模型 提供带引用的回答,并可在同一请求中再次搜索。

提供商与定价

默认引擎 auto 会在声明支持原生搜索的端点上使用模型提供商的原生搜索,否则回退到 Exa。显式设置 engine 可固定使用某个提供商。

  • https://exa.ai 的网站图标

    Exa

    US$0.007 / request

    instant, fast, auto (默认) 模式

    搜索并突出显示相关页面内容。

    instant, fast, auto (默认) 模式
    US$0.007 / request
    deep-lite, deep 模式
    US$0.012 / request
    deep-reasoning 模式
    US$0.015 / request
    前 10 之后的每个 result(最多额外 15)
    US$0.001 / result
  • https://parallel.ai 的网站图标

    Parallel

    US$0.005 / request

    basic (默认), advanced 模式

    支持快速模式和高级模式的网页搜索。

    turbo, fast 模式
    US$0.001 / request
    basic (默认), advanced 模式
    US$0.005 / request
    前 10 之后的每个 result(最多额外 15)
    US$0.001 / result
  • https://perplexity.ai 的网站图标

    Perplexity Search

    US$0.005 / request

    支持域名筛选的排序网页结果。

  • https://firecrawl.dev 的网站图标

    Firecrawl

    US$0.005 / request

    使用 Firecrawl 搜索。

    前 0 之后的每个 result(最多额外 25)
    US$0.0125 / result
  • https://openai.com 的网站图标

    OpenAI

    原生
    提供商定价

    GPT-4.1、GPT-5 及后续版本、o3 和 o4-mini 的内置网页搜索。

    通过 OpenAI, Azure

  • https://anthropic.com 的网站图标

    Anthropic

    原生
    提供商定价

    Claude 3.5 Haiku、Claude 3.7 Sonnet 以及 Claude 4 及更新版本上的内置网页搜索。

    通过 Anthropic, Claude Platform on AWS, Amazon Bedrock, Google Vertex

  • https://ai.google.dev 的网站图标

    Google

    原生
    提供商定价

    Gemini 3 及更高版本上的搜索事实依据功能。

    通过 Google AI Studio, Google Vertex

  • https://x.ai 的网站图标

    xAI

    原生
    提供商定价

    Grok 4 及后续版本内置网页搜索和 X 搜索。

    通过 xAI

每个请求均按标准模型 token 费用计费。

使用此工具

OpenRouter 在请求期间运行工具并将结果返回给模型,因此无需客户端工具循环。

支持的 API:Chat Completions, Responses, and Anthropic Messages。

shell
curl https://openrouter.ai/api/v1/chat/completions \
  -H "Authorization: Bearer $OPENROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "model": "openai/gpt-5.2",
  "tools": [
    {
      "type": "openrouter:web_search"
    }
  ],
  "messages": [
    {
      "role": "user",
      "content": "What were the major AI announcements this week?"
    }
  ]
}'

文档中提供了设置、参数和示例。

阅读集成指南

基准测试

  • BrowseComp

    实时网页上难以查找的事实,根据持续的多步骤研究表现评分。

  • DeepSearchQA

    答案为列表的问题,评分侧重检索的完整性,不允许凑数。

  • HLE

    将 Humanity's Last Exam 用作搜索基准测试:通过实时搜索回答专家级问题。

  • WideSearch

    填写整张表格;答案项准确率会对部分匹配计分。

常见问题

The default engine is auto. It uses the provider’s native search on endpoints that advertise it (OpenAI, Anthropic, Google, and xAI models on their first-party providers) and falls back to Exa on every other endpoint, so the same model can route to either depending on the provider chosen.

The web plugin runs once per request before the model answers. The web search server tool is called by the model zero or more times, so it only searches when the prompt needs it and can search repeatedly within one request.

相关工具

搜索与网页

  • Web fetch

    Fetch and extract content from URLs

    搜索与网页