Skip to main content
Glama
scraperapi-mcp-server

scraperapi-mcp-server

Official
by scraperapi

Google AI Mode (Beta)

google_ai_mode
Read-onlyIdempotent

Query Google AI Mode with a question or URL to return its parsed AI-generated answer and cited source links, supporting brand visibility and AI search monitoring.

Instructions

Beta: success rate and response time can vary; retry failed requests.

Ask Google AI Mode a question and retrieve its parsed AI-generated answer.

Returns the AI-generated answer as structured data, with the sources (links) it cites, for a query or for a Google AI Mode URL (a Google search URL that contains udm=50).

When to use:

  • Seeing what Google's AI answers for a query, and which sources it cites

  • Brand visibility or AI search monitoring on Google, with geo-targeting and language options

When NOT to use:

  • Classic organic Google results (use 'google_search')

  • Answers from the Gemini chat app (use 'google_gemini')

  • Answers from ChatGPT (use 'chatgpt_search')

  • Answers from Perplexity (use 'perplexity_search')

Args: params (GoogleAiModeParams): either query or url (one is required), plus optional localization (tld, country_code, uule, hl, gl), include_html, and output_format.

Returns: str: JSON (default) or CSV containing the structured AI answer.

Raises: ToolError: If the API key is missing, the rate limit is exceeded, or the request fails.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "params": "<params>"
    },
    "name": "google_ai_mode"
  }
}

Input Schema

NameRequiredDescriptionDefault
paramsYes

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv1.2.0

TDQS

A4.8/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond the readOnly/openWorld annotations it discloses the beta instability caveat, a retry recommendation, the required API key, rate-limit and failure modes (ToolError), and that include_html inflates response size. The annotations cover safety, and the description adds the operational reality an agent needs.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loads the beta warning, then purpose, then when/when-not, then args, returns and raises — a clean structure with no filler. The 'Raises' and 'Returns' sections are slightly boilerplate but still informative.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

An output schema exists, so the description need not detail the returned structure, and it correctly confines itself to stating JSON/CSV output plus cited sources. With annotations covering safety and the call contract spelled out, nothing an agent needs is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Although the top-level params object carries no schema description, the description states the query-or-url exclusivity rule ('one is required') and enumerates the optional localization fields (tld, country_code, uule, hl, gl) plus include_html and output_format that the schema defines nested. It does not explain the tradeoff between gl/hl/tld/uule choices, so it stops short of full compensation.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Ask Google AI Mode a question and retrieve its parsed AI-generated answer') and pins the scope to a query or a udm=50 URL. The sibling tools are named and each is disambiguated by the answer source it represents.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicit 'When to use' bullets (AI answer monitoring, brand visibility, geo/language targeting) and a 'When NOT to use' list that routes to google_search, google_gemini, chatgpt_search and perplexity_search by name. The condition selecting each alternative is stated, not merely implied.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.