Rerank Documents
POST/v1/reranking
Authorization
Authorizationstringrequired
Bearer token for API authentication. Format: `Bearer YOUR_API_KEY`
Request Body
modelstringdefault:
mixedbread-ai/mxbai-rerank-large-v2
The model to use for reranking documents.
Constraints
•Minimum length: 1•Maximum length: 500
querystringrequired
The query to rerank the documents.
Constraints
•Minimum length: 1•Maximum length: 32000
inputany[]required
The input documents to rerank.
Constraints
•Minimum items: 1•Maximum items: 1000
rank_fieldsarray
The fields of the documents to rank.
Constraints
•Minimum items: 1
top_kintegerdefault:
-1
The number of documents to return.
Constraints
•Minimum: 1
return_inputbooleandefault:
false
Whether to return the documents.
rewrite_querybooleandefault:
false
Wether or not to rewrite the query before passing it to the reranking model
Response Body
usageobjectrequired
Usage
modelstringrequired
The model used
dataRankedDocument[]required
The ranked documents.
objectstringdefault:
list
The object type of the response
top_kintegerrequired
The number of documents to return.
return_inputbooleanrequired
Whether to return the documents.
Create Embeddings
Create embeddings for text or images using the specified model, encoding format, and normalization.
List Parsing Jobs
List parsing jobs with pagination.
Last updated: August 19, 2025