Claude Code WebSearch
简介
Claude Code WebSearch
原始描述
Free web search using Claude Code CLI or Codex CLI's built-in WebSearch tool — no Tavily, Brave, or Exa API key required. Activate when the user says "websea...
通过你的 Agent 添加
安装目录:claude-websearch/(目录名取自 SKILL.md 的 frontmatter name,不是 URL 里的 slug)。
点「快速安装」复制一段指令贴给你的 Agent:它会先下载到 /tmp、把文件清单和校验值给你看,你确认之后才解压安装。不会一步装完、也不改系统其它位置。
或者手动安装
包是「根级 SKILL.md + 作者附带的文件」,解压到上面的 <slug>/ 目录即可;
目录名不用换,也不要把包直接解压到 skills 根目录。
技能申请的权限由作者决定:装之前先看清单里有没有脚本、它会读写什么。
技能正文
name: claude-websearch
description: >
Free web search using Claude Code CLI or Codex CLI's built-in WebSearch tool — no Tavily,
Brave, or Exa API key required. Activate when the user says "websearch", "搜一下", "search the web",
or when Tavily/Brave quota is exhausted and you need to search the web.
metadata:
openclaw:
emoji: 🔍
requires:
anyBins:
- claude
- codex
Claude WebSearch Skill
Use the bundled script to search the web via Claude Code CLI (primary) or Codex CLI (fallback). Both CLIs expose a native WebSearch tool — no third-party search API key needed.
When to Use
- Tavily / Brave / Exa quota is exhausted
- User says "websearch搜一下X", "search for X", "查一下X"
- Any web search need where no API key is configured
Quick Usage
# Primary (Claude Code CLI — fast, recommended)
scripts/websearch.sh "your query"
# With result count
scripts/websearch.sh "your query" --max 3
# Explicit backend
scripts/websearch.sh "your query" --backend codex
# Primary (Claude Code CLI — fast, recommended)
scripts/websearch.sh "your query"
# With result count
scripts/websearch.sh "your query" --max 3
# Explicit backend
scripts/websearch.sh "your query" --backend codex
Or use the global alias (if installed):
ccws "your query"
How It Works
Backend
CLI flag
Notes
claude (default)
--allowedTools "WebSearch"
Fast (~5s), clean output
codex
--search + reasoning_effort=low
Slower (~30-60s), use as fallback
| Backend | CLI flag | Notes |
|---|---|---|
claude (default) |
--allowedTools "WebSearch" |
Fast (~5s), clean output |
codex |
--search + reasoning_effort=low |
Slower (~30-60s), use as fallback |
The script auto-detects which CLI is available; claude is preferred when both exist.
Setup (one-time)
Install the global alias ccws for quick access:
ln -sf "$(pwd)/scripts/websearch.sh" ~/.local/bin/ccws
Troubleshooting
Problem
Fix
claude: command not found
Install Claude Code CLI: npm install -g @anthropic-ai/claude-code
codex: command not found
Install Codex CLI: npm install -g @openai/codex
Claude returns empty output
Check claude auth status; re-login if expired
Codex times out
Normal — use --backend claude instead
Not inside a trusted directory (Codex)
Script handles this by running from a temp dir
| Problem | Fix |
|---|---|
claude: command not found |
Install Claude Code CLI: npm install -g @anthropic-ai/claude-code |
codex: command not found |
Install Codex CLI: npm install -g @openai/codex |
| Claude returns empty output | Check claude auth status; re-login if expired |
| Codex times out | Normal — use --backend claude instead |
Not inside a trusted directory (Codex) |
Script handles this by running from a temp dir |
正文来自原始发布页, 版权归作者所有,许可未标注。 权利人认为有不妥,可申请下架。