微算力 · API 导航与自营网关
API 接入 EN
未登录登录
✨

Serper Web Search

Serper Web Search · v1.0.0
安全 unknown 级 作者 oakcoderx 公开目录收录
1.2k 下载 0 安装 5.7k 收藏 7 浏览

简介

Serper Web Search

原始描述

Performs Google web searches using the Serper API and returns structured search results when provided a valid Serper API key.

通过你的 Agent 添加

点「快速安装」复制一段指令,粘给你正在用的 Agent(Claude Code、Codex、OpenClaw 等),它会自己完成安装。

或者手动安装

Claude Codeunzip -o skill.zip -d ~/.claude/skills/serper-web-search/
其它 Agent解压到它自己的 skills 目录,目录名用 serper-web-search

包里是 SKILL.md 加作者附带的文件,解压后目录名就是技能名。 技能申请的权限由作者决定,装之前请确认它能读什么、能执行什么。

技能正文


name: serper description: Google search via Serper API. Use when you need to search the web and the user has a Serper API key. Triggers on: (1) user asks to search the web, (2) user wants Google search results, (3) user provides a Serper API key. metadata: { "openclaw": { "emoji": "🔍", "requires": { "bins": ["curl"], "env": ["SERPER_API_KEY"] } } }

Serper Search

Use Serper API for Google search results.

API Details

  • Endpoint: https://google.serper.dev/search
  • Method: POST
  • Headers: X-API-Key: $SERPER_API_KEY, Content-Type: application/json
  • Body: {"q": "your query here"}

Usage

With API Environment Key in

SERPER_API_KEY="your-key" curl -s -X POST "https://google.serper.dev/search" \
  -H "X-API-Key: $SERPER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"q": "your query"}'

With Inline Key

curl -s -X POST "https://google.serper.dev/search" \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"q": "your query"}'

Script

Use the bundled search script:

./scripts/search "your query"

Response Format

Returns JSON with:

  • organic[] - Search results (title, link, snippet)
  • searchParameters.q - Original query
  • credits - Credits used

Example result:

{
  "searchParameters": {"q": "test", "type": "search"},
  "organic": [
    {"title": "Result Title", "link": "https://...", "snippet": "Description...", "position": 1}
  ],
  "credits": 1
}

Getting an API Key

  1. Visit https://serper.dev
  2. Sign up for an account
  3. Get your API key from the dashboard
  4. Set SERPER_API_KEY environment variable or pass the key inline

正文来自原始发布页, 版权归作者所有,许可未标注。 权利人认为有不妥,可申请下架。

标签

没有标签

同类 Skill