Skip to main content
Back to API List This API retrieves answers and search results for a specific query. By default, the API returns answers. Along with search results and answers, the API also provides details about the chunks used and their associated metadata.

Query Parameters

Request Parameters

Sample Request

Response

The response is in JSON format. Key fields within the template field:
  • results: Search results grouped by source type. Chunks from the same document are grouped together.
  • answer_details: The answer to the query along with metadata.
  • chunk_result: Array of all chunks used for answers or search results. Each item contains chunk details and metadata.
  • facets: Filter information. Each unique value of the selected filter field creates a bucket with a key, chunk count, and document count.
  • tabFacet: Content for the static filter used to create tabs. Each bucket corresponds to a unique value of the tab field.
Additional response fields (not within template):
  • llmResponseTime: Time (in milliseconds) taken by the language model to generate the response.
  • retrievalResponseTime: Time (in milliseconds) taken by Search AI to retrieve and process relevant chunks.

Custom Data Examples

Example 1: Pass user information
Example 2: Pass user location
Example 3: Pass previous conversation as context to the Query Rephrasing Agent