Skip to main content
The Answer API is deprecated and sunsets on December 17, 2026. See Migrate from Answer.
Answer retrieves information and returns a synthesized response with citations. Use it for a focused question or a structured answer inside your application. Choose Search to handle synthesis yourself, or DeepResearch for an asynchronous investigation.

Ask a question

Common options

There is no per-request fee. Each answer is billed for the search results, page contents and AI processing it used, and cost.total_deduction_dollars is the amount charged. A result is billed once per answer, even if several searches return it. Use data_max_price to cap search cost and fast_mode for lower latency.

Streaming

Enable streaming to receive the answer progressively. The stream sends search results first, then content chunks, then metadata.
Chunk types: search_results (sources, streamed first), content (partial answer text), metadata (final costs, tokens, full results), done, error.

Structured output

Pass a JSON schema in structured_output to get a parseable object back instead of prose:
Keep schemas shallow, mark essential fields required, add description fields to guide the AI, and use maxItems to bound arrays.

Response format

Illustrative response. Values below are examples, not a live result.
Without structured_output, contents is a string. When you pass a structured_output schema, contents is instead a structured object matching that schema - in Python, check with isinstance(response.contents, dict).

Next steps

API reference

Complete parameter documentation

Python SDK

Python integration

TypeScript SDK

TypeScript integration

Integrations

LangChain, LlamaIndex, and more