ChangelogNew

Now supporting ChatGPT

ChatGPT
A ChatGPT answer comparing wireless earbuds next to its JSON result with sources and search queries

Ask ChatGPT any prompt from the market you choose and receive the answer a real visitor there sees, with every cited source, as JSON.

What you get

  • text and markdown: the full answer, as plain text and with its formatting.
  • sources: every page the answer cites, in order, with its URL and title.
  • searchQueries: the web searches ChatGPT ran while answering, so you see how it researched your prompt.
  • model: the model that answered in that session.

How it works

Each task opens a fresh ChatGPT session in the country you set and asks your prompt exactly as written. You receive the answer a first-time visitor in that market gets, so the brands it recommends and the pages it cites reflect what your customers read.

Every run is a new observation. Repeat the same prompts on a schedule and compare runs to see how the answer, the recommended brands and the cited pages change over time.

Where it helps

  • Check whether ChatGPT recommends your brand for the questions your buyers ask.
  • Find the pages ChatGPT cites in your category and plan content around them.
  • Compare the answer to the same prompt across countries.

Send a request

Send the request with your API key in the Authorization header.

curl -X POST https://api.querying.ai/v1/async/task \
  -H "Authorization: Bearer $QUERYING_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "taskType": "CHATGPT",
    "payload": {
      "prompt": "Search the web and recommend 3 wireless earbuds for commuting. Compare noise cancellation and battery life in a short table, with source links. Keep the answer under 180 words.",
      "country": "US"
    }
  }'

Request fields

taskTypestringRequired
The engine to run, such as CHATGPT or GOOGLE.
payload.promptstringRequired
The question, written the way a user types it into the chat. Up to 100,000 characters.
payload.countrystring
Two-letter country code of the market to ask from, such as US, KR or JP. Default US.
payload.locationstring
A place inside country, such as a station, district or street address, up to 200 characters. The engine answers as a user standing there. For CHATGPT, GEMINI, GOOGLE, AIMODE and GOOGLE_SERP.
payload.include.markdownboolean
Returns markdown, the answer with its headings, lists, tables and links. On by default.
payload.include.searchQueriesboolean
Returns searchQueries, the web searches ChatGPT ran for the answer. On by default.
payload.include.shoppingboolean
Returns the product cards ChatGPT shows as shoppingCards. On by default.
payload.include.rawResponseboolean
true adds the engine’s raw output next to the structured result, for your own parsing. Off by default.
webhook.urlstring
An HTTPS address on your server. The finished task is posted there the moment it completes.
idempotencyKeystring
Your own ID for the request. Each key creates one task per account, so a retried send stays a single task.

Response

A finished task looks like this, trimmed for length.

JSON
{
  "success": true,
  "task": {
    "id": "8bafb0ff-3cc7-4bc4-99bf-32dbacaf7736",
    "taskType": "CHATGPT",
    "status": "COMPLETED",
    "createdAt": "2026-09-10T02:34:15.604Z"
  },
  "credits": { "creditsToCharge": 2, "creditsCharged": 2 },
  "response": {
    "text": "For commuting, I’d prioritize strong ANC (trains, buses, traffic) and 6+ hours of playback. These three are top picks:",
    "markdown": "| Earbuds | Noise cancellation | Battery life (ANC on) |\n|---|---|---|\n| Bose QuietComfort Ultra Earbuds (2nd Gen) | Excellent — among the strongest ANC available | ~6 hrs (24 hrs with case) … |\n…",
    "sources": [
      {
        "position": 1,
        "url": "https://www.wired.com/gallery/best-noise-canceling-earbuds/",
        "label": "Best Noise-Canceling Earbuds: Bose, Sony, Apple, and More | WIRED",
        "attribution": "WIRED",
        "datePublished": "March 29, 2026"
      },
      {
        "position": 2,
        "url": "https://www.tomsguide.com/audio/earbuds/best-noise-canceling-earbuds",
        "label": "Best noise-canceling earbuds in 2026: Tested and reviewed | Tom's Guide",
        "attribution": "Tom's Guide",
        "datePublished": "July 24, 2026"
      }
    ],
    "searchQueries": [
      "best wireless earbuds commuting noise cancellation battery life Sony Bose Apple"
    ]
  }
}
task.statusstring
QUEUED, PROCESSING, then COMPLETED with the answer or FAILED with error.
credits.creditsChargedinteger
Credits charged for the finished task. A failed task charges 0.
response.textstring
The answer as plain text.
response.markdownstring
The answer with its formatting: headings, lists, tables and links.
response.sourcesarray
The pages the answer cites, in the engine’s order, each with position, url and label.
response.searchQueriesarray
The web searches the engine ran to write the answer.
response.shoppingCardsarray
Product cards shown with the answer: title, price, store, rating and product link.

Receive the result

The request returns the task right away with status QUEUED. Poll GET /v1/async/task/{id} until status is COMPLETED or FAILED, or add webhook.url and the finished task arrives at your server with the same task, credits and response. Results stay available for 24 hours after a task finishes.

curl https://api.querying.ai/v1/async/task/$TASK_ID \
  -H "Authorization: Bearer $QUERYING_API_KEY"

Pricing

Each completed ChatGPT task uses 2 credits.

More updates

Stay in the loop

Get new product updates in your inbox.

RSS feed