POST
/
v1
/
knowledge

Authorizations

x-api-key
string
header
required

Body

application/json
Parameters for the context search.
query
string
required

The question or topic the user wants information on.

search_type
enum<string>
required

Defines whether to search in "proprietary", "web", or "all" sources.

Available options:
proprietary,
web,
all
max_price
number
required

The maximum allowed price per thousand queries (CPM).

data_sources
string[]

(Optional) List of index names to search over. If omitted, all relevant indices are used.

max_num_results
integer
default:
10

Number of results returned after reranking.

similarity_threshold
number
default:
0.4

(Optional) The minimum similarity score for a result to be included.

query_rewrite
boolean
default:
true

(Optional) Whether to rewrite the query to improve query performance.

Response

200
application/json
Successful response.
success
boolean
required

Indicates whether the request was successful.

query
string
required

Echoes the input query.

results
object[]
required

List of retrieved documents.

results_by_source
object
required

Count of results by source type.

total_deduction_pcm
number
required

Total cost extrapolated to 1000 queries (CPM) for retrieved content.

total_deduction_dollars
number
required

Total cost for the results in USD.

total_characters
integer
required

Total number of characters retrieved across all results.

error
string

Describes the issue if only a partial response is available.