更新日志新功能

获取 Google AI Mode 的对话式回答

Google AI Mode
关于无线耳机的 Google AI Mode 回答及其 JSON 结果

在你选择的市场向 Google AI Mode 提问,获取它的对话式回答及引用页面。

获得的结果

  • text:AI Mode 的完整回答,通常比 AI Overview 更长、更详细。
  • sources:回答引用的页面,附带 URL 和标题。
  • 独立的任务类型 AIMODE,把 AI Mode 和 AI Overview 作为两个界面分别衡量。

工作原理

AI Mode 是 Google 的对话式搜索:一个问题会得到一篇完整的书面回答,并附上背后页面的链接。每个任务都会从你设定的国家在 AI Mode 中提问,按当地用户看到的样子返回回答和来源。

AI Mode 会深入回答比较和推荐类问题,并直接点出它推荐的品牌。与 AI Overview 一起追踪,就能看到同一个搜索词在两个界面上的表现。

应用场景

  • 追踪 AI Mode 会点名品牌的推荐和比较类搜索词。
  • 比较同一搜索词下 AI Mode 与 AI Overview 引用的页面。

发送请求

在 Authorization 请求头中带上 API 密钥发送请求。

curl -X POST https://api.querying.ai/v1/async/task \
  -H "Authorization: Bearer $QUERYING_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "taskType": "AIMODE",
    "payload": {
      "query": "best robot vacuum for pet hair",
      "country": "US"
    }
  }'

请求字段

taskTypestring必填
要运行的引擎,例如 CHATGPT 或 GOOGLE。
payload.querystring必填
按用户在搜索框中输入的方式写的搜索词。
payload.countrystring
提问所在市场的两位国家代码,例如 US、KR、JP。默认 US。
webhook.urlstring
你服务器上的 HTTPS 地址。任务完成后立即把结果推送到这里。
idempotencyKeystring
你为请求设定的 ID。每个键在账户内对应一个任务,因此重试发送后仍是同一个任务。

响应

完成的任务如下所示,已截取部分内容。

JSON
{
  "success": true,
  "task": {
    "id": "937d9eb6-4b33-49fd-b164-df8e2911b964",
    "taskType": "AIMODE",
    "status": "COMPLETED",
    "createdAt": "2026-10-02T17:16:57.384Z"
  },
  "credits": { "creditsToCharge": 2, "creditsCharged": 2 },
  "response": {
    "markdown": "The **Dreame X50 Ultra** is the overall **best robot vacuum for pet hair**, offering a massive **20,000Pa of suction** and an anti-tangle dual-brush system specifically designed to prevent pet hair wrap.\n\nWhen shopping for a pet hair-focused robot vacuum, comparing suction power, brush design, and price helps identify the right model for your home and budget.\n\n| Model | Key Pet Hair Features | Approx. Price | Best For |\n| --- | --- | --- | --- |\n| **Dreame X50 Ultra** | 20,000Pa suction, Detangling DuoBrush | ~$900 | Heavy shedding & thick carpets |\n| **Roborock Saros Z70** | 5-axis mechanical arm, ultra-thin 7.98 cm body | ~$1,000 | Moving pet toys & low furniture |\n…",
    "shoppingCards": [
      {
        "position": 1,
        "title": "Dreame X50 Ultra",
        "price": { "raw": "$899.99", "value": 899.99, "currency": "$" },
        "store": "Dreametech",
        "rating": 4.5,
        "reviews": "538"
      }
    ],
    "inlineProducts": [
      {
        "position": 1,
        "title": "Dreame X50 Ultra",
        "productLink": "https://www.google.com/search?ibp=oshop&prds=pvt:hg,…"
      }
    ]
  }
}
task.statusstring
依次为 QUEUED、PROCESSING,最终为附带回答的 COMPLETED 或附带 error 的 FAILED。
credits.creditsChargedinteger
已完成任务扣除的积分。失败的任务为 0。
response.textstring
纯文本形式的回答。
response.markdownstring
保留标题、列表和表格的回答,每个结果都包含。
response.sourcesarray
回答引用的页面,按引擎展示的顺序排列,含 position、url 和 label。
response.shoppingCardsarray
与回答一同展示的商品卡片:标题、价格、商店、评分和商品链接。
response.inlineProductsarray
回答句子中带链接的商品名,含 position 和 productLink。

获取结果

请求会立即返回 status 为 QUEUED 的任务。用 GET /v1/async/task/{id} 轮询,直到 status 变为 COMPLETED 或 FAILED;或者加上 webhook.url,在服务器上接收同样的 task、credits 和 response。任务结束后,结果保留 24 小时供查询。

curl https://api.querying.ai/v1/async/task/$TASK_ID \
  -H "Authorization: Bearer $QUERYING_API_KEY"

价格

每个完成的 AI Mode 任务消耗 2 个积分。

更多更新

接收最新消息

通过邮件接收产品更新。

RSS 订阅