
Now supporting mainland China on ChatGPT, Gemini and Google
Set country to CN or HK on CHATGPT, GEMINI and GOOGLE tasks to get the answers users in mainland China and Hong Kong see.

Capture the Perplexity answer to any prompt in your market, with its numbered sources, the searches it ran and the follow-up questions it suggests.
text and markdown: the full answer, as plain text and formatted.sources: the numbered sources behind the answer, each with URL, title and a short description.related_queries: the follow-up questions Perplexity suggests next.Perplexity answers every question with a web search, and its numbered sources show exactly where each statement comes from. Each task asks your prompt from the country you set and returns the answer and its sources as people in that market see them.
Set include.searchQueries to also receive the searches Perplexity ran, which reveal how it breaks a question down into research steps.
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": "PERPLEXITY",
"payload": {
"prompt": "Recommend 3 wireless earbuds for commuting. Compare noise cancellation and battery life in a short table, with sources. Keep it under 180 words.",
"country": "US",
"include": { "markdown": true }
}
}'taskTypestringRequiredCHATGPT or GOOGLE.payload.promptstringRequiredpayload.countrystringUS, KR or JP. Default US.payload.include.markdownbooleantrue adds markdown: the answer with its headings, lists, tables and links.payload.include.searchQueriesbooleantrue adds searchQueries: the web searches the engine ran to write the answer.webhook.urlstringidempotencyKeystringA finished task looks like this, trimmed for length.
{
"success": true,
"task": {
"id": "67030796-8ecd-4aed-b2c4-6ced6639a313",
"taskType": "PERPLEXITY",
"status": "COMPLETED",
"createdAt": "2026-09-10T02:34:24.023Z"
},
"credits": { "creditsToCharge": 1, "creditsCharged": 1 },
"response": {
"text": "For commuting, I’d choose **Sony for strongest all-around isolation**, **Bose for maximum ANC comfort**, or **AirPods for Apple integration**.",
"markdown": "| Earbuds | Noise cancellation | Battery life* | Best for |\n|---|---|---:|---|\n| **Sony WF-1000XM5** | Excellent; measured 32 dB attenuation in key transit-noise frequencies | 8h / 24h case | Android and mixed devices |\n…",
"sources": [
{
"position": 1,
"url": "https://www.rtings.com/headphones/reviews/best/wireless-earbuds",
"label": "The 6 Best Wireless Earbuds of 2026 - RTINGS.com",
"description": "The best wireless earbuds we've tested are the Sony WF-1000XM6. These buds offer top-tier ANC performance."
},
{
"position": 2,
"url": "https://www.businessinsider.com/guides/tech/best-earbuds",
"label": "The best earbuds of 2026, tested by audio experts - Business Insider",
"description": "The best wireless earbuds offer great audio quality in a compact design. These are our top picks from Sony, Bose, Technics, Anker, Apple, and JLab."
}
]
}
}task.statusstringQUEUED, PROCESSING, then COMPLETED with the answer or FAILED with error.credits.creditsChargedintegerresponse.textstringresponse.markdownstringresponse.sourcesarrayposition, url and label.response.searchQueriesarrayThe 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"Each completed Perplexity task uses 1 credit.

Set country to CN or HK on CHATGPT, GEMINI and GOOGLE tasks to get the answers users in mainland China and Hong Kong see.

Set payload.location on GOOGLE, AIMODE and GOOGLE_SERP tasks to get the AI Overview, AI Mode answer and search results a user at that place sees.
Get new product updates in your inbox.