Submit a rerank request

Submits a rerank request to the rerank router

Authentication

AuthorizationBearer
API key as bearer token in Authorization header

Request

This endpoint expects an object.
modelstringRequired
The rerank model to use
querystringRequired
The search query to rerank documents against
documentslist of stringsRequired
The list of documents to rerank
top_nintegerOptional>=0
Number of most relevant documents to return
providerobjectOptional
Provider routing preferences for the request.

Response

Rerank response
modelstring
The model used for reranking
resultslist of objects
List of rerank results sorted by relevance
idstring

Unique identifier for the rerank response (ORID format)

providerstring
The provider that served the rerank request
usageobject
Usage statistics

Errors

400
Bad Request Error
401
Unauthorized Error
402
Payment Required Error
404
Not Found Error
429
Too Many Requests Error
500
Internal Server Error
502
Bad Gateway Error
503
Service Unavailable Error