Skip to main content
Glama

Google Search Results (SERP)

google_serp_scrape

Google organic results for 247 countries, each with a default language (most also accept others). Credits: 5 per Google results page fetched live, 0 per page served from cache; live pages also count toward the plan's daily live-page allowance (DAILY_LIVE_LIMIT when used; cached results are still served). A fresh result usually takes 20-35 seconds and can take up to 2 minutes. If a call times out, repeat the identical call: the search keeps running server-side and the repeat returns the finished result from cache at no charge, without a second acquisition. For long or batch work, call it with background true and collect it with scraper_run_get. Read requested_depth, results_returned, complete and partial_reason together: fewer results than requested is a whole answer when complete is true (every results page asked for was fetched and Google's pages held fewer than ten organic results each; results_note says so). requested_at is when Google was asked, cache_age_seconds how old a stored copy is, served_at when this response was made; execution_time_ms is how long this request took, and original_execution_time_ms, on a stored copy, how long collecting the page took. When Google answers another query than the keyword ("Showing results for ..."), query_correction and executed_query say so, verified_depth is absent, and a position or absence in the page is not recorded as the keyword's rank; repeat with exact_query true to ask for the keyword as typed (exact_query_applied says whether the source could). verified_depth is the N for which a site that is not in items is proven to be outside Google's top N (often a little less than the depth asked for, because a results page carries eight to ten organic results); when it is absent the list proves no absence. One search has one current observation whatever tool made it: a request is answered from the newest stored page that covers it, and when only a shallower newer one exists the response is the older copy with newer_observation saying so (ask for freshness "fresh" to collect the list again). query_check says whether the page answers the search that was requested (confirmed, or unconfirmed when the source did not name the search, or corrected when Google answered another query, executed_query naming it; a page for another search is never returned). Each item's url_source says how its url was found: result_link (the result's own link), page_data (the page's embedded data), goto_resolved (Google's /goto link asked where it leads, on the site the result displays), matched_source (another block of the page links the same site with the same title) or token_decoded (the link token carried it in the clear); absent when url is empty. market_check says whether the country the results are for is confirmed: confirmed (market_evidence.method says by what: page_data or page_footer, Google's own page states it; provider_echo, the search provider states the country it searched), or unconfirmed (nothing states it; the page is returned but never recorded as a rank observation). A page produced for another country is discarded and fetched again; MARKET_MISMATCH means no fetch gave the requested country. With project_id, only a page fetched for the call is recorded as an observation of the project's saved keywords: a page answered from storage (cache_hit) is not a new observation, and project_link.note says so; freshness "fresh" observes now. Each item's url_source says how its url was found: result_link (the result's own link), page_data (the page's data names it), goto_resolved (the browser session that rendered the page asked Google's redirect link where it leads; the answer is on the displayed site), matched_source or token_decoded; url_error says why when url is empty. keyword_difficulty is DataFluxor's own estimate of how hard the search is to rank for (score 0-100, band, confidence, the signals it rests on), computed from this results page; it is not a backlink-based or Google figure. This tool returns no search volume or CPC: for those use keyword_research (search volume, CPC and competition for a seed and its ideas) or domain_overview (volume per keyword a domain ranks for), both priced per request. The result is returned here and may also be kept for up to 30 days as a completed run: retained.run_id reads it again for free with scraper_run_get (retained.available false says why it was not kept). Saved synchronous results can be evicted earlier when storage is needed; set background true (with an idempotency_key) to start the work as a saved run at once. If the call would outlast the connection (many items, deep or fresh SERPs) or the platform has no free capacity, it is not failed: the result is an accepted answer (accepted true, run_id, state, next_step) and the work runs as a saved run; ask scraper_run_get about run_id (view status) as often as retry_after_seconds says. A batch tool's run is charged item by item as each item finishes (failed items are free); any other run once, when it completes. The same idempotency_key prevents a second charge during its retry window; a later new call may be charged.

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": {
      "keyword": "<keyword>",
      "country": "<country>"
    },
    "name": "google_serp_scrape"
  }
}

Input Schema

NameRequiredDescriptionDefault
depthNoNumber of results to retrieve (1-100). Every 10 results is one Google results page: 5 credits when fetched live, 0 when served from cache.
deviceNoThe device the search runs as: desktop. Mobile searches are not available on this service yet (serp_markets lists the devices searches run as); a mobile request is refused with DEVICE_UNSUPPORTED before anything is fetched or charged.desktop
countryYesTwo-letter country code (247 supported); see GET /api/v1/serp/markets
keywordYesThe search query/keyword to scrape. Non-blank text, maximum 200 UTF-8 bytes.
languageNoResult language (Google hl). Defaults to the market's own language; markets served through the managed SERP API accept any language code, e.g. en for English results in DE.
locationNoOptional city or region inside country, as a Google canonical location name ("Manchester,England,United Kingdom", "Austin,Texas,United States"). Results are localised to that place and the response's localization says which place Google reported; a page Google localised to another place is refused uncharged rather than answered with the wrong place, and a page whose place Google's own page did not confirm (localization.location_match unknown) is delivered with a warning and not charged.
freshnessNoReuse tier: standard (default) serves the stored copy within its window of 24 hours (0 credits per page) and fetches live only on a cache miss (5 credits per page); fresh is an explicit live refresh (5 credits per page). Responses carry cache_hit, credits_used, requested_at and cache_age_seconds so stored results are never presented as live.standard
verbosityNoconcise: short summary of the answer; full: the whole answer. Only shapes the output. Send idempotency_key to read the other form later without a new charge.
backgroundNoOptional. true starts this work as a saved background run and answers at once with run_id instead of the result; read it with scraper_run_get. Needs an idempotency_key: the same key returns the same run and never charges twice, for the 30 days the run is kept. Charged like the direct call, as the run's work completes. Without it, a call that would take too long is also answered as a saved run.
project_idNoOptional: a project of this organization (projects_list shows them). The result is then linked to the project's saved keywords that it observed, so saved_keyword_get can answer from it later, and it carries project_link (the saved keywords matched). Costs nothing extra. Omit it for a call that belongs to no project.
exact_queryNoResults for the keyword exactly as typed: when Google would correct it ("Showing results for ..."), ask for the uncorrected results instead. Use it for brand and product names Google takes for misspellings. Without it a corrected page says so in query_correction. The response's exact_query_applied says whether the source that answered could honour it; a page corrected all the same keeps query_correction.
idempotency_keyNoOptional retry key bound to this customer and these arguments. Matching retries replay the first result and do not reserve a second credit; the replay says so in billing (replayed true, credits_charged_this_call 0, original_credits_used).
max_age_secondsNoOldest stored results page that may answer, in seconds (60 to 86400); older pages are fetched live. Default: this tool's window (24 hours), or 6 hours (21600) when project_id is given and max_age_seconds is not, because a day-old page is not where a site ranks now.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Annotations only declare the safety profile (openWorld, non-destructive, not inherently idempotent); the description goes far beyond with credit pricing (5 live / 0 cached), the daily live-page allowance, 20-35s (up to 2 min) latency, cache-vs-live semantics, timeout retry behavior, market and query mismatch handling, and the accepted-run fallback when capacity or connection limits hit. It also discloses retention (30 days) and eviction risk, which no annotation conveys.

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

Conciseness2/5

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

It is a single sprawling block of run-on sentences mixing purpose, billing, cache semantics, output-field decoding, and project linkage, and the url_source explanation is duplicated verbatim in two separate places. The useful front-loaded summary is buried quickly under dense caveats, so an agent must re-read to extract call-shaping rules.

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?

For a 13-parameter, high-cost, cache-and-billing-sensitive scraping tool with no output schema, the description covers everything needed: cost per page, latency, retry and idempotency rules, correction and market-mismatch handling, absence proof via verified_depth, and background-run handoff. No material calling decision is left undocumented.

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?

Schema coverage is 100% and the schema already documents every parameter, so much of the description's parameter talk (depth-to-page credit math, freshness tiers) restates structured data. It does add real semantics beyond the schema in places, notably that a cache_hit page with project_id is not recorded as a new observation and that exact_query_applied may show the source could not honour the request.

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?

Opens with a concrete verb and resource plus scope: "Google organic results for 247 countries, each with a default language." It also explicitly separates itself from keyword_research and domain_overview for volume/CPC and points to scraper_run_get for background collection, so an agent can pick it over siblings without opening schemas.

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?

Names alternatives with conditions: use keyword_research or domain_overview for volume and CPC, use scraper_run_get for background runs, and set freshness "fresh" when a new observation is needed. It also states the retry rule for timeouts (repeat the identical call), when to pass exact_query, and when to use background true with an idempotency_key.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources