Send prompts to Google AI Mode and reliably extract the AI Overview / AI Mode response - including the full answer text and its source citations - at scale, without blocks.
Powered by the NetNut LLM Scraper API. NetNut handles the proxy rotation, headless rendering, anti-bot handling, and throttling, so you just send a prompt and get back clean, structured JSON.
- How it works
- Who is this for?
- Getting started
- Request sample
- Request parameters
- Output sample
- Response structure
- Code examples
- Testing
- Use cases
- Why choose NetNut
- FAQ
- Learn more
- You send a
POSTrequest to the NetNut LLM Scraper API endpoint with a prompt and thegoogle-ai-modeengine. - NetNut runs the prompt against Google AI Mode using its residential proxy network and rendering infrastructure.
- You receive structured JSON containing the AI response text and any citations Google attached to it. No HTML parsing required.
Endpoint
POST https://llm-scraper.netnut.io/search
Authentication - HTTP Basic Auth using your NetNut Scraper API credentials:
Authorization: Basic <base64(username:password)>
This API is designed for SEO platforms, AI visibility and GEO tools, agencies, competitive intelligence providers, and enterprises that need to track, analyze, and monitor Google AI Mode results at scale.
-
Get NetNut LLM Scraper API credentials. Start here or contact NetNut.
-
Copy the example environment file and add your own credentials:
cp .env.example .env # then edit .env and set NETNUT_USERNAME / NETNUT_PASSWORDπ Never commit credentials.
.envis git-ignored. All examples read credentials from theNETNUT_USERNAMEandNETNUT_PASSWORDenvironment variables - nothing is hardcoded. -
Pick your language from
examples/and run it (see each example's notes below).
import os, requests
payload = {
"prompt": "What are the leading SEO tips in 2025?",
"engine": "google-ai-mode",
"country": "us",
}
response = requests.post(
"https://llm-scraper.netnut.io/search",
auth=(os.environ["NETNUT_USERNAME"], os.environ["NETNUT_PASSWORD"]),
json=payload,
timeout=120,
)
print(response.json())| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
prompt |
string | Yes | β | The prompt/question to send to Google AI Mode. Max length: 4096 characters. |
engine |
string | Yes | google-ai-mode |
The engine to scrape. Use google-ai-mode for Google AI Mode. |
country |
string | No | β | Target country for geo-relevant results (e.g. us, uk, de). |
{
"timestamp": "2026-06-15T10:45:04.560Z",
"traceID": "947ccf8a-6495-4904-ad9e-8bad19ee2e2a",
"request_duration": 5.93,
"process_duration": 5.93,
"scraper": "Google-AI-Mode",
"response": {
"prompt": "best running shoes for beginners",
"text": "Top Beginner Running Shoes\nThis shoe stands out as the ultimate multi-purpose option for new runners ...",
"citations_found": true,
"citations": [
{
"id": 1,
"url": "https://runrepeat.com/uk/guides/best-for-beginners-running-shoes",
"title": "RunRepeat (+3) β View related links",
"description": "",
"section": "citations"
}
],
"tables": [],
"inline_citations": []
}
}The above is a trimmed, real response.
tablesandinline_citationsare always present and populate when Google AI Mode includes comparison tables or inline source links.
| Field | Type | Description |
|---|---|---|
timestamp |
string | ISO 8601 timestamp of the response. |
traceID |
string | Unique identifier for the request (useful for support/debugging). |
request_duration |
number | Total request time in seconds. |
process_duration |
number | Processing time in seconds. |
scraper |
string | The scraper used - Google-AI-Mode. |
response.prompt |
string | The prompt that was sent. |
response.text |
string | The full Google AI Mode response text. |
response.citations_found |
boolean | Whether Google attached citations to the answer. |
response.citations |
array | List of citation objects (see below). |
response.tables |
array | Comparison tables extracted from the answer (empty if none). |
response.inline_citations |
array | Inline source links referenced within the answer text (empty if none). |
Citation object
| Field | Type | Description |
|---|---|---|
id |
number | Citation index. |
url |
string | Source URL. |
title |
string | Source title. |
description |
string | Short description of the source. |
section |
string | Section the citation belongs to. |
Ready-to-run examples live in examples/. Every example reads credentials from
environment variables and prints the structured JSON response.
| Language | Path | Notes |
|---|---|---|
| Python | examples/python |
Uses requests. |
| Node.js | examples/nodejs |
Uses built-in fetch (Node 18+). |
| Go | examples/go |
Standard library only. |
| PHP | examples/php |
Uses cURL extension. |
| Java | examples/java |
Uses java.net.http (Java 11+). |
| C# | examples/csharp |
.NET 8+. |
| Shell | examples/shell |
curl one-liner. |
Set your credentials first:
# macOS / Linux
export NETNUT_USERNAME="your-username"
export NETNUT_PASSWORD="your-password"# Windows PowerShell
$env:NETNUT_USERNAME = "your-username"
$env:NETNUT_PASSWORD = "your-password"Each example ships with a unit test suite that runs without making any live network calls.
| Language | Run command | Requirements |
|---|---|---|
| Python | cd examples/python && python -m pytest -v |
pip install -r requirements.txt |
| Node.js | cd examples/nodejs && npm test |
npm install (no extra deps) |
| Go | cd examples/go && go test ./... |
Go 1.21+ |
| PHP | cd examples/php && php test_main.php |
PHP 8.1+ with cURL extension |
| Java | cd examples/java && java MainTest.java |
Java 21+ |
| Shell | cd examples/shell && bash test.sh |
bash, grep |
Tests validate credential enforcement, request construction, Base64 auth encoding, error handling, and JSON output - without touching the network.
- AI search visibility (GEO/AEO). Track whether and how your brand appears in Google AI Mode answers.
- Citation/source monitoring. See which domains Google cites for the prompts that matter to you.
- Competitive intelligence. Compare how AI Mode describes you vs. competitors across countries.
- Content optimization. Learn what AI Mode surfaces so you can optimize content to be cited.
- Datasets & research. Collect AI responses at scale for analysis or model evaluation.
- 100M+ residential IPs - access one of the world's largest owned residential proxy networks.
- Petabytes of monthly traffic - infrastructure built to support large-scale public web data operations.
- #1 web data provider on G2 - recognized by customers for performance, reliability, and support.
- NASDAQ-listed (ALAR) - backed by the transparency, stability, and accountability of a public company.
- Built for enterprise scale - trusted by Fortune 500 companies and leading AI organizations.
What is Google AI Mode? Google AI Mode is Google's AI-generated answer experience. This Scraper API returns the AI response text and the sources cited.
Do I need my own credentials? Yes. This repository contains no credentials. Bring your own NetNut LLM Scraper API credentials and set them as environment variables.
Is there a prompt length limit? Yes - prompts can be up to 4096 characters.
Can I target a specific country?
Yes, pass country (e.g. us, uk, de).
What format is returned? Always structured JSON - never HTML.
Questions or need higher volume? Contact NetNut.
This project is licensed under the MIT License.
