Skip to content

根据任务 ID 获取 Google Reviews 结果

本接口使用 GET 方法,通过任务 ID 获取 Google Reviews 任务结果:

GET https://api.seermartech.cn/v3/reviews/google/task_get/$id

返回结果与创建任务时指定的本地商家名称、搜索引擎、地区和语言参数对应。本平台会尽可能准确地模拟指定地区和搜索引擎,以确保返回结果接近任务创建时的搜索结果。

你可以访问返回结果中的 check_url,并使用无痕模式进行核验。系统不会考虑用户偏好、搜索历史及个性化搜索因素,因此这些因素不会反映在返回结果中。

计费说明

  • 创建任务时计费。
  • 任务创建后的 30 天,可获取该任务结果。
  • 该接口本身不重复收取结果查询费用。
  • 实扣费以响应头 X-SeerMarTech-Charge-CNY 为准。

请求参数

接口通过 URL 路径接收任务 ID,无需请求体。

参数类型说明
idstring任务唯一标识符,UUID 格式。任务创建后 30 天可使用该 ID 随时获取结果。

请求示例:

text
GET /v3/reviews/google/task_get/04011058-0696-0199-0000-2196151a15cb

响应结构

API 返回 JSON 数据, tasks 任务数组。

顶层字段

字段类型说明
versionstring当前 API 版本。
status_codeinteger请求级状态码。
status_messagestring请求级提示信息。
timestring请求执行耗时,单位为秒。
costfloat平台原始 USD 成本兼容字段;人民币实扣以 X-SeerMarTech-Charge-CNY 为准。
tasks_countintegertasks 数组中的任务数量。
tasks_errorintegertasks 数组中返回错误的任务数量。
tasksarray任务数组。

tasks 字段

字段类型说明
idstring任务唯一标识符,UUID 格式。
status_codeinteger任务状态码,通常在 1000060000 范围。
status_messagestring任务状态说明。
timestring任务执行耗时,单位为秒。
costfloat平台原始 USD 成本兼容字段;人民币实扣以 X-SeerMarTech-Charge-CNY 为准。
result_countintegerresult 数组中的结果数量。
patharray当前请求的 URL 路径。
dataarray创建任务时提交的参数,通常与 POST 请求体中的参数一致。
resultarray任务结果数组。

系统可能返回请求级或任务级错误,接方应根据 status_codestatus_message 处理异常。

result 结果字段

商家评论摘要字段

字段类型说明
keywordstring创建任务时提交的。返回时会对编码后的 %## 进行解码,+ 会被解码为空格。
typestring创建任务时提交的搜索引擎类型。
se_domainstring创建任务时提交的搜索引擎域名。
location_codeinteger创建任务时提交的地区代码。
language_codestring创建任务时提交的语言代码。
check_urlstring对应搜索结果页面的直接 URL,可用于核验返回结果。
datetimestring获取结果的日期和时间,UTC 格式:yyyy-mm-dd hh-mm-ss +00:00。例如:2019-11-15 12:57:46 +00:00
titlestringSERP 中评论模块的标题,通常为收集评论的本地商家名称。
sub_titlestringSERP 中评论模块的副标题,例如商家地址等补信息。
ratingarray本地商家的综合评分信息。
feature_idstringSERP 中评论模块的唯一标识符。
place_idstringSERP 中评论模块的 XPath。
cidstringGoogle 定义的商家客户端 ID,即本地商家的唯一标识符。可合 Google Reviews 接口获取完整评论列表。
reviews_countinteger商家的评论总数。
items_countinteger当前结果中的评论条目数量。通过创建任务时增加 depth 参数,可以获取更多评论。
itemsarray获取到的评论列表。

综合评分 rating

字段类型说明
rating_typestring评分类型,可取 Max5PercentsCustomMax
valuefloat基于评论计算的平均评分。
votes_countinteger评分票数。
rating_maxinteger当前评分类型的最大值。

items 评论字段

字段类型说明
typestring评论类型,目前可能为 google_reviews_search
rank_groupinteger在相同 type素组中的排名。不同类型不会计该排名。
rank_absoluteinteger评论在评论列表中的绝对排名。
positionstring评论在 SERP 中的对齐位置,目前可能为 right
xpathstring评论在 SERP 中的 XPath。
review_textstring评论正文。
time_agostring评论发布时间的相对时间描述。
timestampstring评论发布时间,UTC 格式:yyyy-mm-dd hh-mm-ss +00:00。例如:2019-11-15 12:57:46 +00:00
ratingarray评论提交的评分。
reviews_countinteger评论提交的评论总数。
photos_countinteger评论提交的总数。
local_guideboolean是否拥有本地向导身份。
profile_namestring评论的个人资料名称。
profile_urlstring评论的个人资料 URL。
profile_image_urlstring评论的个人资料头像 URL。
owner_answerstring商家对该评论的回复。
owner_time_agostring商家回复的相对发布时间。

评论评分 items.rating

字段类型说明
rating_typestring评分类型,目前为 Max5
valuefloat评论提交的评分值。
votes_countinteger该评论获得的反馈或票数。
rating_maxinteger评分最大值;当 rating_typeMax5 时,最大值为 5

cURL 示例

bash
id="04011058-0696-0199-0000-2196151a15cb"

curl --location --request GET \
  "https://api.seermartech.cn/v3/reviews/google/task_get/${id}" \
  --header "Authorization: Bearer smt_live_YOUR_KEY" \
  --header "Content-Type: application/json"

TypeScript 示例

typescript
import axios from "axios";

const taskId = "02231934-2604-0066-2000-570459f04879";

axios
  .get(
    `https://api.seermartech.cn/v3/reviews/google/task_get/${taskId}`,
    {
      headers: {
        // 使用本平台 API Key 进行 Bearer 认证
        Authorization: "Bearer smt_live_YOUR_KEY",
        "Content-Type": "application/json",
      },
    }
  )
  .then((response) => {
    // 处理任务结果
    console.log(response.data);
  })
  .catch((error) => {
    // 处理 HTTP 或 API 错误
    console.error(error.response?.data || error.message);
  });

Python 示例

python
import requests

task_id = "04011058-0696-0199-0000-2196151a15cb"

url = f"https://api.seermartech.cn/v3/reviews/google/task_get/{task_id}"

headers = {
    # 使用本平台 API Key 进行 Bearer 认证
    "Authorization": "Bearer smt_live_YOUR_KEY",
    "Content-Type": "application/json",
}

response = requests.get(url, headers=headers, timeout=60)
response.raise_for_status()

data = response.json()

if data.get("status_code") != 20000:
    print(
        f"请求失败,状态码:{data.get('status_code')},"
        f"消息:{data.get('status_message')}"
    )
else:
    for task in data.get("tasks", []):
        if task.get("status_code", 0) >= 40000 or not task.get("result"):
            print(
                f"任务失败,状态码:{task.get('status_code')},"
                f"消息:{task.get('status_message')}"
            )
        else:
            for result in task["result"]:
                print(result)

响应示例

json
{
  "version": "3.0.0",
  "status_code": 20000,
  "status_message": "Ok.",
  "time": "0.1234",
  "cost": 0.0000,
  "tasks_count": 1,
  "tasks_error": 0,
  "tasks": [
    {
      "id": "04011058-0696-0199-0000-2196151a15cb",
      "status_code": 20000,
      "status_message": "Ok.",
      "time": "0.0987",
      "cost": 0.0000,
      "result_count": 1,
      "path": [
        "v3",
        "reviews",
        "google",
        "task_get",
        "04011058-0696-0199-0000-2196151a15cb"
      ],
      "data": [],
      "result": [
        {
          "keyword": "示例商家",
          "type": "google",
          "se_domain": "google.com",
          "location_code": 1000,
          "language_code": "en",
          "check_url": "https://www.google.com/search?q=example",
          "datetime": "2019-11-15 12:57:46 +00:00",
          "title": "示例商家",
          "sub_title": "示例地址",
          "rating": {
            "rating_type": "Max5",
            "value": 4.5,
            "votes_count": 120,
            "rating_max": 5
          },
          "feature_id": "example_feature_id",
          "place_id": "example_xpath",
          "cid": "example_cid",
          "reviews_count": 120,
          "items_count": 1,
          "items": [
            {
              "type": "google_reviews_search",
              "rank_group": 1,
              "rank_absolute": 1,
              "position": "right",
              "xpath": "example_review_xpath",
              "review_text": "这是一条示例评论。",
              "time_ago": "2 周前",
              "timestamp": "2019-11-15 12:57:46 +00:00",
              "rating": {
                "rating_type": "Max5",
                "value": 5,
                "votes_count": 3,
                "rating_max": 5
              },
              "reviews_count": 8,
              "photos_count": 2,
              "local_guide": true,
              "profile_name": "示例用户",
              "profile_url": "https://example.com/profile",
              "profile_image_url": "https://example.com/profile/image.jpg",
              "owner_answer": "感谢您的反馈!",
              "owner_time_ago": "1 周前"
            }
          ]
        }
      ]
    }
  ]
}

实用场景

  • 监控本地商家评分与评论数量,及时发现评分变化和口碑趋势,为门店运营和声誉管理提供依据。
  • 抓取竞争对手的最新评论,分析用户对价格、服务、环境等方面的反馈,支持竞品研究和运营优化。
  • 提取评论与商家回复信息,评估商家互动频率和客户响应质量,本地 SEO 与客户体验分析。
  • 结合 cid 获取指定商家的完整评论列表,建立商家级评论数据库,用于长期口碑追踪和感分析。
  • 使用 check_url 校验采集结果,核对特定地区和语言下的搜索展示,提升 SEO 报告与本地排名分析的可信度。

统一入口:官网 · LLM API · 控制台