← Back to Skills Marketplace
leohuang8688

Google Web Search

by ClawMem.com · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ⚠ suspicious
248
Downloads
0
Stars
0
Active Installs
1
Versions
Install in OpenClaw
/install google-search-2
Description
Perform global web searches using Google Custom Search API with customizable result counts and high-quality results.
README (SKILL.md)

🔍 Google Web Search Skill

Google 网页搜索技能 - 使用 Google Custom Search API 进行全球网络搜索


📋 Overview

Property Value
Name google-web-search
Version 1.0.0
Author PocketAI for Leo
License MIT
Category Search
Required Env Vars GOOGLE_API_KEY, GOOGLE_CX

🔐 Required Environment Variables

This skill requires the following environment variables:

Variable Description Required How to Get
GOOGLE_API_KEY Google Custom Search API key ✅ Yes https://console.cloud.google.com/
GOOGLE_CX Custom Search Engine ID ✅ Yes https://programmablesearchengine.google.com/

Configuration:

export GOOGLE_API_KEY="your_google_api_key"
export GOOGLE_CX="your_search_engine_id"

✨ Features


✨ Features

  • 🔍 Google Web Search - 使用 Google Custom Search API
  • 🌍 Global Coverage - 全球搜索覆盖
  • 📊 Customizable Results - 可定制返回结果数量
  • 🚀 Easy Integration - 易于集成到 OpenClaw
  • 🎯 High Quality - 高质量搜索结果

🚀 Quick Start

Installation

cd ~/.openclaw/workspace/skills
# Already installed at: google-web-search/

Configuration

Option 1: Using .env file (Recommended)

# Copy the example .env file
cp .env.example .env

# Edit .env and add your API keys
nano .env  # or use your favorite editor

Option 2: Using environment variables

export GOOGLE_API_KEY="your_google_api_key"
export GOOGLE_CX="your_search_engine_id"

Basic Usage

from src.google_search import google_search

# Search with default 10 results
result = google_search("AI trends 2026")
print(result)

# Search with custom result count
result = google_search("electric vehicles", count=5)
print(result)

CLI Usage

# Search with default 10 results
python3 src/google_search.py "AI trends 2026"

# Search with custom result count
python3 src/google_search.py "electric vehicles" 5

📖 API Usage

Python API

from src.google_search import GoogleSearch, google_search

# Method 1: Simple search
result = google_search("OpenClaw AI", count=10)
print(result)

# Method 2: Using client
searcher = GoogleSearch(
    api_key="your_api_key",
    cx="your_cx_id"
)
results = searcher.search("OpenClaw", count=10)

for result in results:
    print(f"Title: {result['title']}")
    print(f"URL: {result['url']}")
    print(f"Snippet: {result['snippet']}")
    print(f"Source: {result['display_link']}\
")

⚙️ Configuration

Environment Variables

Variable Description Required
GOOGLE_API_KEY Google Custom Search API key ✅ Yes
GOOGLE_CX Custom Search Engine ID ✅ Yes

Getting Google API Key

  1. Visit Google Cloud Console
  2. Create a new project or select existing
  3. Enable "Custom Search API"
  4. Go to APIs & Services → Credentials
  5. Create API Key

Creating Search Engine

  1. Visit Programmable Search Engine
  2. Click "Add" to create a new search engine
  3. Configure search scope (entire web or specific sites)
  4. Get the Search Engine ID (CX)

📁 Project Structure

google-web-search/
├── src/
│   └── google_search.py    # Main search client
├── SKILL.md                 # This file
└── README.md                # Documentation

🎯 Use Cases

1. News Search

result = google_search("latest tech news 2026")

2. Research

result = google_search("AI healthcare applications research")

3. Product Search

result = google_search("smartphone reviews 2026")

4. Academic Search

result = google_search("machine learning papers site:arxiv.org")

📝 Response Format

Search Result Structure

{
  "title": "Page Title",
  "url": "https://example.com/page",
  "snippet": "Page description snippet",
  "display_link": "example.com"
}

Example Output

🔍 Google Search Results for: AI trends 2026

Found 10 results:

1. **Top AI Trends to Watch in 2026**
   Source: forbes.com
   URL: https://forbes.com/ai-trends-2026
   Artificial intelligence continues to evolve rapidly...

2. **The Future of AI in 2026**
   Source: mit.edu
   URL: https://mit.edu/ai-future-2026
   MIT researchers predict major breakthroughs...

⚠️ Limitations

  • API Quotas: Free tier: 100 queries/day
  • API Key Required: Must have valid Google API key
  • Search Engine Required: Must create Custom Search Engine
  • Results Limit: Maximum 10 results per query

💰 Pricing

Free Tier

  • 100 queries per day
  • Suitable for development and testing

Paid Tier

  • $5 per 1000 queries
  • Suitable for production use

📞 Support


📄 License

MIT License - See LICENSE file for details.


Happy Searching! 🔍


Last Updated: 2026-03-17
Version: 1.0.0
Author: PocketAI for Leo

Usage Guidance
This skill appears to actually be a straightforward Google Custom Search client, but the registry metadata omits the fact that it requires GOOGLE_API_KEY and GOOGLE_CX — a manifest/documentation mismatch. Before installing: (1) confirm you are comfortable providing a Google API key and CX, (2) prefer storing keys in a secure secrets store rather than plaintext .env files in the workspace, (3) review the included src/google_search.py (it only calls Google APIs and formats results), and (4) ask the publisher or registry to correct the metadata so required credentials are declared. If you cannot verify the source or the metadata, run this skill in a sandboxed environment to limit exposure of your other workspace files.
Capability Analysis
Type: OpenClaw Skill Name: google-search-2 Version: 1.0.0 The skill is a standard implementation of a Google Custom Search API client. It uses environment variables for API credentials, includes appropriate timeouts for network requests, and contains no evidence of data exfiltration, malicious execution, or prompt injection. The code in src/google_search.py and the instructions in SKILL.md are consistent with the stated purpose of performing web searches.
Capability Assessment
Purpose & Capability
The skill's name, description, SKILL.md and code all consistently implement Google Custom Search usage (requests to Google's Custom Search API using an API key and CX). The capabilities requested by the code (GOOGLE_API_KEY, GOOGLE_CX) are appropriate for the stated purpose. However, the registry metadata incorrectly lists no required environment variables/credentials, which is a meaningful inconsistency.
Instruction Scope
SKILL.md instructs the agent to read environment variables or a .env file and to call Google's Custom Search API. The runtime instructions and the code only reference the search API, .env loading, and printing/returning search results. There is no instruction to read unrelated system files or to transmit data to unexpected endpoints. Minor issue: SKILL.md mentions copying a .env.example, but no .env.example file is present in the package.
Install Mechanism
No install script is provided (instruction-only install), so nothing will be downloaded or executed automatically beyond normal pip installing of declared dependencies. requirements.txt lists only 'requests' and 'python-dotenv', which are proportional to the task.
Credentials
The code and SKILL.md require two credentials (GOOGLE_API_KEY and GOOGLE_CX), which are reasonable and minimal for Google Custom Search. The concern is the registry metadata advertises zero required env vars/credentials; that mismatch could lead agents or platform automation to not prompt the user for the required secrets or mis-handle permissions. The code also loads a .env from the skill directory — storing keys in plaintext in a workspace is normal but has privacy implications that the user should consider.
Persistence & Privilege
The skill does not request 'always: true' and does not modify other skills or global agent settings. It only performs network calls to the Google API via requests; autonomous invocation is allowed (default) but not an additional red flag here.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install google-search-2
  3. After installation, invoke the skill by name or use /google-search-2
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.0
- Initial release of Google Web Search Skill (v1.0.0) - Provides global web search using Google Custom Search API - Supports customizable number of search results - Easy integration with OpenClaw and CLI usage - Requires GOOGLE_API_KEY and GOOGLE_CX environment variables - Suitable for news, research, product, and academic searches
Metadata
Slug google-search-2
Version 1.0.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 1
Frequently Asked Questions

What is Google Web Search?

Perform global web searches using Google Custom Search API with customizable result counts and high-quality results. It is an AI Agent Skill for Claude Code / OpenClaw, with 248 downloads so far.

How do I install Google Web Search?

Run "/install google-search-2" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is Google Web Search free?

Yes, Google Web Search is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does Google Web Search support?

Google Web Search is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created Google Web Search?

It is built and maintained by ClawMem.com (@leohuang8688); the current version is v1.0.0.

💬 Comments