Skip to main content
POST
Get context
This endpoint retrieves relevant context from the workspace context based on a textual prompt. Understanding how the system processes your prompt is critical to achieving best-in-class results.
  1. Hybrid search: The file index is first searched to find files that are most relevant to the prompt. This ensures that only the most relevant information is considered for retrieval.
  2. The retrieved files are read and returned as sources with their content.

Authorizations

X-API-Key
string
header
required

API key for the Qontext API

Body

application/json
prompt
string
required

The prompt to retrieve context for.

Example:

"Give me the following information regarding Harry Potter. 1) Who is he?, 2) What is his relationship with Gryffindor Inc., Weasleys Wizard Wheezes, and Ollivanders?"

limit
number
required

Maximum number of files to return in the context response.

Example:

5

Response

Context successfully retrieved