Back to blog
Web Scraping·August 14, 2026·8 min read

ChatGPT Scraper API: get the answers ChatGPT actually shows users

Why the official OpenAI API can't measure ChatGPT visibility, and how Anakin's ChatGPT Scraper API returns the answers users actually see - text, citations, and search queries - with per-country geo targeting for AI visibility and GEO tracking.

T

Tosh Kothari

Anakin Team

Radar diagram showing the OpenAI API returning no citations versus the real ChatGPT product returning 47 cited sources, extracted as structured JSON fields: answer_text, citations, web_search_query, and country.

Your brand shows up in some ChatGPT answers and not others, and nothing in the OpenAI developer platform tells you why. That's because ChatGPT and the OpenAI API are two different systems. The API sells you the model. chatgpt.com wraps that model in a retrieval layer that decides what to search, which sources to cite, and which brands to name (OpenAI, 2024). AI visibility lives in that layer, so if you want to measure it, you have to query the product itself.

Key takeaways

  • ChatGPT and the OpenAI API are different systems. The API serves the raw model; chatgpt.com adds a retrieval layer that runs web searches, picks sources, and cites them. GEO tracking measures that layer, and no official endpoint exposes it.
  • A ChatGPT Scraper API sends your prompt to the real ChatGPT and returns the answer a user would see - the text, the citations, and whether a web search ran.
  • Anakin's ChatGPT Scraper API is a dedicated action in the Wire catalog. One call, 2 credits, and you get back the full answer plus every source ChatGPT cited, as structured JSON.
  • The API stays stable when ChatGPT ships frontend changes, backed by reverse-engineering expertise dating back to 2017 and Wire's 99.95% uptime over the trailing 90 days. Failed calls aren't billed.
  • Pass a country code and the query runs from that market. ChatGPT answers differently by location, and you can measure each market separately.

Why the OpenAI API can't tell you what ChatGPT says

The OpenAI API returns what the model knows. ChatGPT returns what the model finds. Ask ChatGPT "best project management tool for small teams" and the product decides whether to search, runs the searches, picks the sources, and writes an answer with citations. The answer changes with the user's location and with whatever is in the index that week. None of that exists in chat/completions, because chat/completions skips the retrieval layer entirely.

This matters because the answers people act on come from the product. You can call gpt-5 with the same prompt a thousand times and never see what a ChatGPT user sees, because their answer went through retrieval and yours didn't. If you're tracking whether ChatGPT recommends your brand or cites your docs, the official API is measuring the wrong system.

AI visibility is how often, and how favorably, an AI assistant names your brand or cites your content when it answers relevant questions. Generative Engine Optimization (GEO) is the work of improving that (Princeton GEO study, 2024). Both start from the same raw input: the real answers ChatGPT gives to real questions, collected often enough to see movement. There's no official endpoint for "what would ChatGPT say", and that's the gap a scraper API closes.

What a ChatGPT Scraper API does

A ChatGPT Scraper API takes your prompt, runs it through the actual ChatGPT product, and hands back the response as structured JSON. Doing this yourself means a browser automation stack: Playwright, residential proxies, session handling, and an engineer on call, because ChatGPT streams its answers, sits behind anti-bot systems, and ships frontend changes without notice. A scraper that worked in January quietly breaks in March. For a handful of queries a day, DIY is viable. Past that, the maintenance is the product, and a managed API is how you stop paying for it in engineering time.

When you compare managed options, three numbers decide it: success rate, cost per query, and how fast the vendor recovers when ChatGPT changes something.

Anakin's ChatGPT Scraper API

ChatGPT has its own dedicated scraper in Anakin's Wire catalog - its own action, its own parameters, its own docs page. It isn't a generic scrape endpoint pointed at chatgpt.com, and it isn't bundled behind some multi-engine wrapper. You call the chatgpt action, it runs your prompt on the real product, and it returns the answer with everything around it parsed into fields. Gemini and Perplexity are separate scrapers in the same catalog, each with its own action - they get their own posts. (If you want one prompt run across several engines side by side, that's Anakin's AI Visibility product, built on top of these scrapers.)

The action takes five parameters:

  • prompt - what you'd type into ChatGPT. Required, up to 4,096 characters.
  • web_search - ask ChatGPT to search the web. The response tells you whether a search actually ran, via web_search_triggered.
  • country - a 2-letter code. The session runs through a proxy in that country, so you see the answers that market sees. Anakin's proxy network covers 207 countries.
  • additional_prompt - an optional follow-up, sent in the same conversation after the first answer.
  • include_html - adds the rendered HTML to the response. Off by default; the structured fields cover most uses.

A call costs 2 credits. Failed calls cost nothing. The API stays stable when ChatGPT ships frontend changes - that's reverse-engineering expertise dating back to 2017 doing its job, backed by Wire's 99.95% uptime over the trailing 90 days.

Calling it

curl https://api.anakin.io/v1/wire/task \
  -X POST \
  -H "X-API-Key: $ANAKIN_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "action_id": "chatgpt",
    "params": {
      "prompt": "best web scraping API for AI agents",
      "web_search": true,
      "country": "us"
    }
  }'

The action runs async. With the Python SDK, polling is handled for you:

import os
from anakin import Wire

wire = Wire(api_key=os.environ["ANAKIN_API_KEY"])

result = wire.call(
    action="chatgpt",
    params={
        "prompt": "best web scraping API for AI agents",
        "web_search": True,
        "country": "us",
    },
)
print(result["answer_text"])

You can also pass a webhook_url and get the result pushed to you instead of polling.

What comes back

Here's the data field from a real completed job, run 2026-08-14 and truncated for length:

{
  "prompt": "best web scraping API for AI agents",
  "title": "Web Scraping API Search",
  "model": "gpt-5-6",
  "country": "us",
  "web_search_triggered": true,
  "web_search_query": "best web scraping API AI agents Firecrawl Browserbase Apify Bright Data ScrapingBee 2026",
  "answer_text": "If you're building AI agents that need live web access, I'd shortlist these in 2026: ...",
  "citations": [
    {
      "url": "https://www.stork.ai/blog/best-web-scraping-tools-for-ai-agents-2026",
      "title": "Best Web Scraping Tools for AI Agents in 2026 (Compared) | Stork.AI",
      "domain": "Stork",
      "date_published": "2026-07-13T00:00:00Z",
      "cited": true,
      "position": 1
    }
  ]
}

Three fields do the heavy lifting for GEO work:

  • answer_text is the complete answer a user would have read, with markdown and raw variants alongside it. This is where you check whether your brand got named.
  • citations is every source ChatGPT pulled, as structured records - URL, domain, publish date, position, and whether it was actually cited in the answer. This run returned 47 of them. If you want to know whose content ChatGPT trusts for your category, it's this list.
  • web_search_query shows you the search ChatGPT actually ran under the hood. Your prompt was "best web scraping API for AI agents"; ChatGPT searched for specific brand names. That rewrite is exactly the kind of thing GEO teams need to see, and it's a field in the response.

There are more - references, search_sources, entities, and shopping fields for commerce-style prompts - but the three above are where most tracking pipelines start.

Getting started

Create an API key from the anakin.io dashboard and the calls above work as-is. Usage is billed in credits per completed call. If you're running volume - thousands of prompts across markets on a schedule - contact Anakin for enterprise and custom plans, which come with direct support from the engineering team.

What this unlocks for AI SEO and GEO agencies

If you run an AI SEO or GEO agency, this API turns "does ChatGPT recommend my client" into a weekly number. Define the 1000s of prompts that matter for the client - "best <category> for <audience>" and its variants - run them on a schedule in each target market, and store the responses. Mention share is a pass over answer_text. Source share is a pass over citations. The trend line is the diff between weeks.

That's the deliverable: share of ChatGPT answers naming the client, per market, per week, with the answer text as evidence. And because citations shows whose content ChatGPT is pulling instead, the same data hands you the gap analysis for the next content cycle - which domains own the category today, and what they published that got cited.

Frequently asked questions

What is a ChatGPT Scraper API?

A ChatGPT Scraper API is a service that submits prompts to the real ChatGPT product and returns the answers programmatically as structured JSON. It captures the retrieval-layer behavior - web search, citations, brand mentions - that the official OpenAI API does not expose.

Why not just use the official OpenAI API?

The OpenAI API serves the model without ChatGPT's retrieval layer. It doesn't run ChatGPT's web searches, pick its citations, or vary by user location, so it can't tell you what ChatGPT actually says to users. For AI visibility tracking, the product is the thing being measured.

Is there a ChatGPT Search API?

OpenAI does not offer a public API that returns ChatGPT's search-backed product answers. The chat/completions endpoint can call web search as an explicit, opt-in tool (OpenAI API docs), but its retrieval and citation behavior is not the same system as chatgpt.com. Scraper APIs exist to close that gap.

Does the API return ChatGPT's citations?

Yes. Every search-backed answer comes with structured citation records - URL, domain, title, publish date, position, and whether the source was actually cited in the answer text. A single response can carry dozens of them, and the web_search_query field shows the search ChatGPT ran to find them.

Can I track ChatGPT answers in specific countries?

Yes. Pass a 2-letter country code and the query runs through a proxy in that country, across 207 countries. ChatGPT answers location-sensitively, so per-country tracking shows differences a single-region setup misses.

What does it cost?

A ChatGPT call costs 2 credits, and failed calls cost nothing. For comparison, cloro's paid plans start at $30/month for 37,500 credits (its free tier includes 500 credits), and SerpApi - which covers Google's AI surfaces, not ChatGPT - starts at $25/month. For high-volume or multi-market tracking, Anakin offers enterprise and custom plans.

Does Anakin cover engines besides ChatGPT?

Yes. Gemini and Perplexity are separate scrapers in the Wire catalog, each with its own action and parameters, covered in their own posts. Anakin's AI Visibility product runs one prompt across several engines side by side when you want the comparison.

71% of B2B buyers who use AI for research already turn to ChatGPT first (Semrush, 2026), and its answers are now a channel you can measure. Try Anakin's ChatGPT Scraper API and see how ChatGPT answers the questions your customers are asking - and who it cites when it does.