API referencererank
Rerank a provided candidate set by relevance and taste
Reranks a caller-supplied list of content objects by relevance/taste relative to the taste profile of a specified entity. Unlike /search, no graph lookup is performed — the candidate set is entirely caller-provided. Candidates are not persisted after the call.
Authorization
ApiKeyAuth X-API-Key<token>
In: header
Query Parameters
relative_to_entity_id*string
The entity whose taste profile is used to rank the candidates.
in_terms_of_entity_type*string
The entity type context for ranking.
Value in
"content" | "place" | "brand" | "user" | "website" | "file"Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
curl -X POST "https://example.com/rerank?relative_to_entity_id=string&in_terms_of_entity_type=content" \ -H "Content-Type: application/json" \ -d '{ "candidates": [ { "url": "http://example.com", "type": "image" } ] }'{
"results": [
{
"id": "string",
"name": "string",
"description": "string",
"url": "http://example.com",
"ref": "string",
"type": "content",
"linked_content": [
{
"id": "string",
"title": "string",
"description": "string",
"url": "http://example.com",
"content": "string",
"type": "image",
"ref": "string"
}
],
"linked_entities": [
{
"id": "string",
"name": "string",
"description": "string",
"url": "http://example.com",
"ref": "string",
"type": "content",
"linked_content": [
{
"id": "string",
"title": "string",
"description": "string",
"url": "http://example.com",
"content": "string",
"type": "image",
"ref": "string"
}
],
"linked_entities": []
}
]
}
]
}{
"error": "string",
"code": "string"
}{
"error": "string",
"code": "string"
}