Call it
curl https://api.peume.com/v1/call/get-google-ai-overview \
-H "Authorization: Bearer $PEUME_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": {
"q": "coffee shops in Austin",
"ludocid": "1234567890123456789",
"kgmid": "/m/0k8z",
"location": "Austin, Texas, United States",
"lat": 30.2672,
"lon": -97.7431
}
}'const res = await fetch("https://api.peume.com/v1/call/get-google-ai-overview", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.PEUME_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"input": {
"q": "coffee shops in Austin",
"ludocid": "1234567890123456789",
"kgmid": "/m/0k8z",
"location": "Austin, Texas, United States",
"lat": 30.2672,
"lon": -97.7431
}
}),
});
const { output, cost_usd } = await res.json();import os, requests
res = requests.post(
"https://api.peume.com/v1/call/get-google-ai-overview",
headers={"Authorization": f"Bearer {os.environ['PEUME_API_KEY']}"},
json={
"input": {
"q": "coffee shops in Austin",
"ludocid": "1234567890123456789",
"kgmid": "/m/0k8z",
"location": "Austin, Texas, United States",
"lat": 30.2672,
"lon": -97.7431
}
},
)
print(res.json()["output"])Answer: {"id": "run_…", "status": "completed", "cost_usd": …, "output": {…}}. Long jobs answer 202 with a run id to read later. From an AI agent, connect the MCP server and ask for this by name: get-google-ai-overview.
Parameters
qstringSearch query, up to 2,048 characters. Required unless ludocid or kgmid is supplied.
Example: coffee shops in Austin
ludocidstringDecimal Google CID for a local entity search. Can replace q.
Example: 1234567890123456789
kgmidstringGoogle Knowledge Graph machine ID, such as /m/0k8z. Can replace q.
Example: /m/0k8z
locationstringHuman-readable search location, up to 512 characters. Use only one of location, uule, or lat and lon.
Example: Austin, Texas, United States
uulestringPre-encoded Google location token, up to 2,048 characters. Use only one of location, uule, or lat and lon.
latnumberLatitude between -90 and 90. Supply with lon; conflicts with location and uule.
Example: 30.2672
lonnumberLongitude between -180 and 180. Supply with lat; conflicts with location and uule.
Example: -97.7431
radiusnumberSearch radius in meters around location or lat and lon, which it requires. 1 to 199 on desktop, 1 to 1,000 on tablet or mobile.
lsigstringOpaque Google local or Knowledge Graph signature, up to 4,096 characters.
sistringOpaque cached Google search context, up to 4,096 characters.
ibpstringGoogle layout or expansion control, up to 4,096 characters.
udsstringOpaque Google filter token, up to 4,096 characters.
color_schemestringGoogle's light or dark result presentation.
light · dark
google_domainstringA Google domain from Google's supported list, such as google.com or google.co.uk.
Example: google.com
glstringLowercase two-letter country code used to localize results.
Example: us
hlstringGoogle interface and result language, such as en, en-US, or de. Defaults to en.
Example: en
crstringCountry restriction: one or more countryXX values joined with |, such as countryUS.
Example: countryUS
lrstringLanguage restriction: one or more lang_xx values joined with |, such as lang_en.
Example: lang_en
devicestringGoogle returns its real layout for the selected device: desktop, tablet, or mobile.
desktop · tablet · mobile
Example: desktop
tbsstringGoogle search-filter string, such as qdr:w, up to 4,096 characters.
safestringGoogle adult-content filtering: active or off.
active · off
nfprstringSet 1 to disable Google spelling auto-correction, or 0 to allow it.
0 · 1
filterstringGoogle similar-results filtering: 0 or 1.
0 · 1
pwsstringGoogle personalization flag: 0 or 1. 0 asks for non-personalized results.
0 · 1
peek_pwsstringGoogle personalization companion flag: 0 or 1, forwarded to Google unchanged.
0 · 1
tbmstringGoogle vertical: lcl, vid, nws, shop, or pts. Google Images (isch) is rejected with 400 unsupported_search_vertical.
lcl · vid · nws · shop · pts
startintegerResult offset for pagination. Defaults to 0.
Example: 10
numintegerRequested result count, 1 to 10. A best-effort hint: Google may return fewer rows, and results are never padded.
as_dtstringInclude (i) or exclude (e) the as_sitesearch host. Requires as_sitesearch.
i · e
as_epqstringExact phrase the results must contain, up to 2,048 characters.
as_eqstringWords the results must not contain, up to 2,048 characters.
as_lqstringReturn pages that link to this complete HTTP(S) URL.
as_nlointegerLower bound of a number range. Supply with as_nhi.
as_nhiintegerUpper bound of a number range. Supply with as_nlo.
as_oqstringAdditional terms of which any may match, up to 2,048 characters.
as_qstringAdditional terms that must all match, up to 2,048 characters.
as_qdrstringDate range: d, w, m, or y with an optional positive count, such as m3 for the past three months.
Example: m3
as_rqstringReturn pages related to this complete HTTP(S) URL.
as_sitesearchstringHostname to include or exclude, such as example.com. A hostname, not a URL.
Example: example.com
oqstringOriginal query text from a Google URL, up to 2,048 characters; forwarded unchanged.
gs_lpstringOpaque Google autocomplete-session value from a Google URL, up to 4,096 characters; forwarded unchanged.
sclientstringGoogle client label such as gws-wiz-serp: up to 64 letters, digits, dots, underscores, or hyphens.
timeoutnumberOptional budget for the entire request in seconds, measured from gateway receipt until the response is ready to send. Includes admission, queueing and settlement. Must be greater than 0 and at most 90. On expiry, the call is not billed and returns 503 request_deadline_exceeded with retryable=true and a request ID. Omit to retain the standard server deadline.
Other ways to do it
Same job, other sources, cheapest first.
