360 Secure SkillHub
360 安全技能中心

google-search-results-scraper-api-skill

核心功能:调用BrowserAct模板稳定抓取谷歌搜索结果,提取排名、标题、URL等多类结构化数据,可处理授权、并发等错误并支持单次重试。需配置BrowserAct API Key,输入关键词、国家、结果数量等参数。典型场景包括市场调研、竞品监控、数据集补充、报告数据收集。输出含多种结构化字段的JSON数据,适配下游分析、BI等工作流。

browseract-cli
browseract-cli
热度 14.66
最近更新 2026-09-09 00:37:22
分类:自动化依赖:代码执行 / 第三方 API / 读写文件应用场景:数据处理 / 自动化脚本 / 市场分析 / 报告撰写 ...

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add google-search-results-scraper-api-skill
Metadata
name
google-search-results-scraper-api-skill
description
This skill helps users run the Google Search Results Scraper BrowserAct template and extract structured public data. Use this skill when users ask to collect google search results scraper data, scrape google search results scraper results, export public records, enrich datasets, monitor public web data, or call this BrowserAct template by API.
metadata
{"openclaw":{"emoji":"🌐","requires":{"bins":["python"],"env":["BROWSERACT_API_KEY"]}}}

Google Search Results Scraper Automation Skill

Brief

Scrape public Google organic search results with BrowserAct. Extract ranked result titles, URLs, display URLs, domains, snippets, sitelinks, and source result pages across pagination.

Features

  1. Stable BrowserAct workflow execution: Starts the verified BrowserAct template through the v3 bots API instead of asking the Agent to improvise browser steps.
  2. Structured public data extraction: Returns the BrowserAct run payload for downstream analysis, reporting, enrichment, and monitoring.
  3. API-key guided onboarding: Directs users to the BrowserAct API Key page with this template's co-from channel.
  4. Retry-aware execution: Handles authorization, concurrency, task failure, timeout, and transient errors with clear stopping rules.
  5. Reusable CLI helper: Keeps the runnable logic in scripts/ so future Agents can call the same template repeatedly.

API Key Guide

Before running, check the BROWSERACT_API_KEY environment variable. If it is not set, do not take other measures; ask and wait for the user to provide it.

Agent must tell the user:

"Since you haven't configured the BrowserAct API Key yet, please go to the BrowserAct Console to get your Key."

Input Parameters

Configure these parameters from the user's request:

  1. keyword
    • Type: string
    • Description: BrowserAct template input keyword.
    • Example: test
    • Default: test
  2. country
    • Type: string
    • Description: BrowserAct template input country.
    • Example: 1
    • Default: 1
  3. count
    • Type: string
    • Description: BrowserAct template input count.
    • Example: 1
    • Default: 1

Invocation Method

Run the standalone script from this skill directory:

python -u ./scripts/google_search_results_scraper_api.py "test" "1" "1"

Running Status Monitoring

This task may take several minutes. The script prints timestamped status logs such as [14:30:05] Task Status: running.

  • Keep monitoring terminal output while waiting.
  • Treat new status logs as evidence that the task is still running.
  • Consider the retry rule only if the task fails, times out, or stops producing meaningful progress.

Data Output

After successful execution, the script retrieves and prints the BrowserAct API response. The returned data may include:

  • rank: Extracted rank value when available.
  • title: Extracted title value when available.
  • url: Extracted url value when available.
  • description: Extracted description value when available.
  • name: Extracted name value when available.
  • email: Extracted email value when available.
  • phone: Extracted phone value when available.
  • address: Extracted address value when available.
  • rating: Extracted rating value when available.
  • review_count: Extracted review count value when available.
  • price: Extracted price value when available.
  • date: Extracted date value when available.
  • author: Extracted author value when available.
  • summary: Extracted summary value when available.

Ground conclusions in the extracted data and handle missing fields gracefully.

Error Handling and Retry

If an error occurs during script execution, follow this logic:

  1. If the output contains "Invalid authorization", the API Key is invalid or expired. Do not retry; ask the user to re-check their BrowserAct API Key.
  2. If the output contains "concurrent" or "too many running tasks", the current subscription has reached the concurrent task limit. Do not retry; tell the user to upgrade at https://www.browseract.com/reception/recharge?co-from=google-search-results-scraper.
  3. For other transient failures, automatically retry the script once.
  4. If the second attempt fails, stop and report the specific error output.

Typical Use Cases

  1. Market research and competitive monitoring.
  2. Dataset enrichment for spreadsheets, CRMs, and BI workflows.
  3. Public web data collection for reports and trend discovery.
  4. Repeatable API automation using BrowserAct workflow results.