Skip to main content
POST
cURL

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Headers

x-portkey-trace-id
string
x-portkey-span-id
string
x-portkey-parent-span-id
string
x-portkey-span-name
string
x-portkey-metadata
object

Body

application/json
model
string
required
query
string
required
documents
(string | object · object)[]
required
Minimum array length: 1
top_n
integer
Required range: x >= 1
return_documents
boolean
default:false
max_tokens_per_doc
integer
Required range: x >= 1
priority
number
rank_fields
string[]
truncation
boolean
parameters
object

Response

200 - application/json
object
enum<string>
required
Available options:
list
results
object[]
required
model
string
required
id
string
usage
object
provider
string
Last modified on September 17, 2026