google-search
Use when the user wants Google Search results through Frevana, including organic results, related searches, related questions, knowledge graph, answer boxes, localized country/language results, pagination offsets, safe search, result count, or device-specific Google results.
How do I install this agent skill?
npx skills add https://github.com/finpeakinc/frevana-skills --skill google-searchIs this agent skill safe to install?
- Gen Agent Trust Hubpass
The skill allows the agent to perform Google searches via the Frevana API. It uses a bash script to handle network requests and JSON validation. The skill follows secure practices for token management and temporary file handling. The only noted security risk is the potential for indirect prompt injection from untrusted search result content.
- Socketpass
No alerts
- Snykwarn
Risk: MEDIUM · 1 issue
What does this agent skill do?
Google Search
Search Google results through Frevana.
Purpose
This skill is for finding regular Google Search results.
Inputs:
q- optional
location - optional
gl - optional
hl - optional
num - optional
start - optional
safe - optional
device - optional
no_cache(boolean; omitted by default)
Output:
- validated response JSON with Google Search results
- the same validated JSON saved to a local file on every successful run
This skill validates that the response is JSON, saves it to disk, and returns it unchanged on stdout. Do not rewrite or reshape the returned data unless the user explicitly asks for a transformation.
What This Skill Needs
- user-provided
q - optional
location - optional
gl - optional
hl - optional
num - optional
start - optional
safe - optional
device - optional
no_cache FREVANA_TOKENin the environment variables, or an explicit--tokenoverride for the current runcurlbashpython3
Execution Order
Use this flow so the request stays simple and reliable:
- Confirm the user has provided
qor an equivalent Google search query. - Prefer the script over ad hoc
curlcommands. - Let the script read
FREVANA_TOKENfirst. - In interactive shell usage, if
FREVANA_TOKENis missing, the script may prompt for it. - In non-interactive or agent workflows, fail fast if the token is missing and tell the user to set
FREVANA_TOKENor pass--tokenexplicitly. - Run the script once. It prints the validated JSON to stdout and saves the same JSON to a file.
- Use the saved JSON file for any follow-up parsing or summarization instead of calling the search API again.
- Return the validated response JSON, or summarize the most relevant search results if the user does not need the full payload.
Commands
Basic Google search
bash <skill-path>/scripts/search_google.sh \
--q "coffee"
--query is accepted as an alias for --q.
Search with country, language, and location
bash <skill-path>/scripts/search_google.sh \
--q "coffee" \
--location "Austin, Texas, United States" \
--gl us \
--hl en
Search with pagination, result count, safe search, and device
bash <skill-path>/scripts/search_google.sh \
--q "coffee" \
--num 20 \
--start 20 \
--safe off \
--device mobile
Bypass the search cache
bash <skill-path>/scripts/search_google.sh \
--q "coffee" \
--no-cache true
--no-cache accepts only true or false and sends a JSON boolean. Omit it for ordinary searches unless fresh results are requested by the user or required by the calling workflow. This requires a Frevana Server version that supports GoogleSearchDto.no_cache; deploy that support before relying on cache bypass.
Save response JSON to a specific file
bash <skill-path>/scripts/search_google.sh \
--q "coffee" \
--gl us \
--hl en \
--output ./out/google-search-result.json
Token override for the current run
bash <skill-path>/scripts/search_google.sh \
--q "coffee" \
--token "your bearer token"
Fixed Request Shape
The script sends this payload shape, omitting optional fields that were not provided:
{
"q": "coffee",
"location": "Austin, Texas, United States",
"gl": "us",
"hl": "en",
"num": 20,
"start": 20,
"safe": "off",
"device": "mobile",
"no_cache": true
}
Only q is required. Do not invent location, gl, hl, num, start, safe, or device values when the user did not provide them.
The Frevana endpoint schema exposes only q, location, gl, hl, num, start, safe, device, and no_cache; do not pass unsupported passthrough fields such as engine, api_key, output, async, or zero_trace, and do not pass other unsupported Google Search fields unless the Frevana endpoint schema is expanded first.
Response Shape
The API returns Frevana JSON. Common fields include:
search_metadatasearch_parameterssearch_informationorganic_resultsrelated_questionsrelated_searchesknowledge_graphanswer_boxpagination
Output
- Success: the script validates that the response body is JSON, writes it to a file, prints the saved path to stderr, and prints the JSON to stdout
- Default file path:
./out/google-search-<UTC timestamp>-<pid>.json - With
--output: the same JSON is written to the specified file path instead of the default path - Failure: the script prints the response body or parsing error and exits non-zero
Notes
- Require
--qor--query - Do not call the script twice just to save and summarize results. It always saves the same JSON that it prints.
- Use
--locationwhen the user requests a city, state, or country search origin - Use
--glwhen the user requests a country or region code - Use
--hlwhen the user requests a language code - Use
--numonly for result counts from1to100 - Use
--startwhen the user requests pagination by result offset - Use
--safeonly foractiveoroff - Use
--deviceonly fordesktop,mobile, ortablet - If
curlis missing, stop and tell the user to installcurl - If
python3is missing, stop and tell the user to installpython3 - Do not echo the Bearer token back to the user
- Summarize the search results the user actually cares about instead of dumping raw JSON unless they ask for the full payload
Example Prompts
中文
- "搜索 Google 上的 coffee"
- "查一下 Google 搜索 q=coffee,location=Austin, Texas, United States,gl=us,hl=en"
- "Google 搜索 coffee,第 3 页,移动端结果,并保存原始 JSON"
English
- "Search Google for coffee"
- "Look up Google results for coffee with location=Austin, Texas, United States, gl=us, hl=en"
- "Search Google for coffee on mobile with start=20 and save the raw JSON"
How can the creator link this skill?
Add the canonical catalog link to the repository README so users can inspect current installs and available audits. The publishing guide covers the complete discovery path.
<a href="https://skillzs.dev/skills/finpeakinc/frevana-skills/google-search">View google-search on skillZs</a>