Skip to main content
POST
/
search
/
answer
Synthesized answer with citations from the 9-provider fan-out
curl --request POST \
  --url https://api.lava.so/v1/search/answer \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "q": "Current state of NIST post-quantum standardization 2025-2026 — ML-KEM and ML-DSA deployment, FrodoKEM as a hedge, security margin against Module-LWE attacks"
}
'
{
  "answer": "<string>",
  "citations": [
    {
      "source": "<string>",
      "url": "<string>",
      "title": "<string>"
    }
  ],
  "results": [
    {
      "source": "<string>",
      "title": "<string>",
      "url": "<string>",
      "snippet": "<string>",
      "published_at": "2023-11-07T05:31:56Z",
      "score": 123,
      "raw": {}
    }
  ],
  "sources_failed": [
    {
      "provider": "<string>",
      "reason": "<string>"
    }
  ],
  "cost": {
    "breakdown": {},
    "llm_cost": "<string>",
    "markup": "<string>",
    "total": "<string>",
    "synthesis_error": "<string>"
  }
}

Documentation Index

Fetch the complete documentation index at: https://lava.so/docs/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

Bearer token authentication used for standard API calls. Format: 'Bearer YOUR_API_KEY'

Body

application/json
q
string
required

The query to answer

providers
string[] | null

Optional subset of providers (defaults to all 9). See /search/sources for valid ids.

max_results_per_source
integer | null
Required range: 1 <= x <= 50
since
string<date-time> | null

Response

Synthesized answer with citations plus the underlying sources. When the LLM step fails, answer is null and cost.synthesis_error is set, but the rest of the payload is unchanged.

answer
string | null
required

Markdown answer citing sources via [N]. Null when the synthesis model failed.

citations
object[]
required
results
object[]
required
sources_failed
object[]
required
cost
object
required