Real-time SERP data is an observation of a requested search context. Record the query, engine, market and collection time before comparing results. A fast response does not prove that a source was published recently, that Google just crawled it or that a provider bypassed its cache.
Define which time you mean
| Time or version | What it establishes |
|---|---|
| Request started / finished | When your application made and received this call |
| Source publication or update time | Only what a checked source or returned field supports |
| Google crawl time | Not established by a normal SERP response |
| Provider cache state | Only what the provider documents or explicitly exposes |
SearchCans Google searches use POST /api/v1/search, t:"google" and the query in s. Validate code and data.organic, then read each result’s link. Google Search API contract lists supported request fields. Reader rendering and wait parameters belong to URL extraction; they are not freshness controls for this search call.
Preserve the request and returned version
This pure function accepts an already received envelope. It performs no network request. Store the original JSON too: a body hash identifies a saved version, while the request context explains what that version can be compared with.
import hashlib
import json
def serp_snapshot(request_context, envelope, started_at, finished_at):
if not isinstance(envelope, dict) or envelope.get("code") != 0:
raise ValueError("Search business response failed")
data = envelope.get("data")
if not isinstance(data, dict) or not isinstance(data.get("organic"), list):
raise ValueError("Expected data.organic array")
raw = json.dumps(envelope, ensure_ascii=False, sort_keys=True)
return {"request": dict(request_context), "request_started_at": started_at,
"observed_at": finished_at, "response_sha256": hashlib.sha256(raw.encode()).hexdigest(),
"results": [{"position": r.get("position"), "title": r.get("title"), "link": r["link"]}
for r in data["organic"] if isinstance(r, dict)
and isinstance(r.get("link"), str)],
"source_publication_time": None,
"provider_cache_state": "not established by this record"}
The local fixture deliberately returns the same JSON for two markets. Its response hashes match, but the request contexts differ. Matching hashes alone therefore do not establish matching searches. The record leaves publication time unknown and does not invent a cache-off option.
Compare compatible observations
Use the same query, engine, country, language and pagination when tracking a change. Keep failures and omitted results visible. Preserve the settings actually used rather than infer them from a language in the query. A result disappearing from one snapshot is not proof that its page left Google’s index.
For latency distributions and source-version checks, use the separate latency and freshness measurement method. For domain positions across repeated snapshots, use the rank-tracking workflow. For a Python request walkthrough, use Google Search API in Python. This page supplies the observation record those workflows need.