Reads real pages
Every run fetches and reads source pages and PDFs, not just snippets. Set 10m, 30m, or 60m to control depth.
Deep Research API · Perplexity Agent API compatible
Perplexity Agent API compatible. POST to /v1/agent, poll for the result. Works with the Perplexity SDK and the OpenAI SDK out of the box.
Focused, Thorough, and Comprehensive use 1, 2, and 4 prepaid credits per run.
# Submit a research question (async-only: every create returns queued) curl -X POST https://pocketsearch.ai/v1/agent \ -H "Authorization: Bearer $POCKET_SEARCH_KEY" \ -H "Content-Type: application/json" \ -d '{"input": "State of solid state battery manufacturing, 2026", "preset": "high"}' # {"id": "resp_7f3d…", "status": "queued", "output": []} # Poll /v1/agent/resp_7f3d… until terminal, read .output
Three research grades
Every run fetches and reads source pages and PDFs, not just snippets. Set 10m, 30m, or 60m to control depth.
The completed response includes a cited report that can be stored, rendered, or passed to another system without conversion.
The search_results output item carries every query and source the research examined. The Markdown report links to the cited subset.
Every report goes through a final editing pass that cleans up process artifacts and produces reader-ready prose.
Research continues on the server if a process exits or the network drops. Finished results remain available for 24 hours.
Every terminal response carries a research_receipt under usage.pocket_search. It lists queries run with their surfaced results and source investigations.
SDK compatibility
The API implements the Perplexity Agent API format. Point your existing SDK at Pocket Search by changing the base URL and API key. The same endpoints serve both SDKs.
// baseURL: no /v1 suffix // (the SDK bakes /v1 into paths) import Perplexity from '@perplexity-ai/perplexity_ai'; const client = new Perplexity({ apiKey: POCKET_SEARCH_KEY, baseURL: "https://pocketsearch.ai", }); const res = await client.responses .create({ preset: "high", input: "Solid state batteries…", }); // Every create is async: res comes back "queued" with an id. // Poll until terminal, then read the answer. let out = res; while (!["completed", "failed", "incomplete", "cancelled"].includes(out.status)) { await new Promise((r) => setTimeout(r, 15000)); out = await client.responses.retrieve(res.id); } console.log(out.output_text);
// baseURL: include /v1 suffix // (the SDK expects it in baseURL) import OpenAI from 'openai'; const client = new OpenAI({ apiKey: POCKET_SEARCH_KEY, baseURL: "https://pocketsearch.ai/v1", }); const res = await client.responses .create({ model: "default", input: "Solid state batteries…", }); // Same pattern: create returns "queued" with an id; poll retrieve(). let out = res; while (!["completed", "failed", "incomplete", "cancelled"].includes(out.status)) { await new Promise((r) => setTimeout(r, 15000)); out = await client.responses.retrieve(res.id); } console.log(out.output_text);
Both SDKs surface response.output_text on the poll. Credit cost, duration, refunds, and the research_receipt live under usage.pocket_search.
Pricing
Focused, Thorough, and Comprehensive use 1, 2, or 4 prepaid credits. Packs start at $6. See every pack on the pricing page.
Get a key
Request a key and we'll send you a quickstart guide.
Enter your email for API access updates.
FAQ
Yes. Request a key above and we'll send you a quickstart guide.
Three grades: Focused (up to 10 min), Thorough (up to 30 min), and Comprehensive (up to 60 min). Set mode to 10m, 30m, or 60m on each request.
Focused, Thorough, and Comprehensive use 1, 2, and 4 credits. With the $35 pack, that's about $0.29, $0.58, or $1.17 per report.
Every POST /v1/agent returns a response ID immediately — the API is async-only. Research continues on the server if the client disconnects. Poll GET /v1/agent/{id} until status is terminal, then read the output.
A Perplexity Agent API compatible response with an output array: a search_results item with every query and source examined, and a message item with the Markdown report. Usage includes a research_receipt with queries run, sources opened, and source investigations. Timestamps and status are included.
Send your API key as a Bearer token in the Authorization header. Keys are issued directly by Pocket Search.
Yes. The API implements the Perplexity Agent API format at /v1/agent (aliased at /v1/responses for OpenAI SDK compatibility). Point your existing SDK at Pocket Search by changing the base URL and API key.
Failed runs return their reserved credits automatically. The response includes credits_charged and credits_refunded so billing can be verified in code.
24 hours after a run finishes. Poll the same run ID during that window to retrieve the result.