Rerank API (v2)
Authentication
Bearer authentication of the form Bearer <token>, where token is your auth token.
Headers
Request
The identifier of one of the available Rerank models.
A list of texts that will be compared to the query.
For optimal performance we recommend against sending more than 1,000 documents in a single request.
Note: long documents will automatically be truncated to the value of max_tokens_per_doc.
Note: structured data should be formatted as YAML strings for best performance.
Defaults to 4096. Long documents will be automatically truncated to the specified number of tokens.
When enabled, the API response will include the relevant spans of each document that contributed to its rank. This feature is only supported for Rerank v5 and newer models.
Controls how early the request is handled. Lower numbers indicate higher priority (default: 0, the highest). When the system is under load, higher-priority requests are processed first and are the least likely to be dropped.