Create a new reranker
POST /v1/rerankers: Creates a new reranker configuration for ranking search results.
Creates a new reranker configuration for ranking search results. Rerankers represent connections to different reranking API services (like TEI, OpenAI, etc.) and include all the necessary configuration to use them for result ranking.
DUPLICATE DETECTION: Returns HTTP 409 Conflict (ALREADY_EXISTS) if another reranker exists with identical {ownerId, providerType, endpointUrl, apiPath, modelIdentifier, credentialsFingerprint} after URL canonicalization. Uniqueness is enforced per-owner, allowing different users to have identical configurations. A SHA-256 credential fingerprint participates in uniqueness checking.
DEFAULTS: apiPath defaults to '/v2/rerank' for Cohere and '/rerank' for other providers if omitted; supportedModalities defaults to [TEXT] if omitted.
OWNER DEFAULTS: Owner defaults to the authenticated principal unless ownerId is provided; CREATE_RERANKER is evaluated against the proposed reranker and owner. This operation is NOT idempotent - each request creates a new reranker record.
In: header
Reranker configuration details
User-facing name of the reranker
"BGE Cross-Encoder Reranker"1 <= length <= 255Description of the reranker
"BAAI BGE reranker for cross-encoder semantic ranking"Type of reranking provider
"TEI""OPENAI" | "VLLM" | "TEI" | "LLAMA_CPP" | "VOYAGE" | "COHERE" | "JINA"API endpoint URL
"http://bge.reranker.goodmem.ai:8010"API path for reranking request (defaults: Cohere /v2/rerank, Jina /v1/rerank, others /rerank)
"/rerank"Model identifier
"BAAI/bge-reranker-base"Supported content modalities (defaults to TEXT if not provided)
["TEXT"]Structured credential payload describing how to authenticate with the provider. Required for SaaS providers; optional for local or proxy providers.
{"kind":"CREDENTIAL_KIND_API_KEY","apiKey":{"inlineSecret":"sk-reranker-api-key"}}Structured credential payload describing how GoodMem should authenticate with an upstream provider.
Credential strategy — fixed to CREDENTIAL_KIND_API_KEY for this variant
Configuration when kind is CREDENTIAL_KIND_API_KEY
{"inlineSecret":"sk-1234567890abcdef","secretRef":{"uri":"vault://path/to/secret"},"headerName":"Authorization","prefix":"Bearer "}Optional annotations to aid operators (e.g., "owner=vertex")
properties <= 20Empty Object
Structured credential payload describing how GoodMem should authenticate with an upstream provider.
Credential strategy — fixed to CREDENTIAL_KIND_GCP_ADC for this variant
Configuration when kind is CREDENTIAL_KIND_GCP_ADC
{"scopes":["https://www.googleapis.com/auth/cloud-platform"],"quotaProjectId":"my-quota-project"}Optional annotations to aid operators (e.g., "owner=vertex")
properties <= 20Empty Object
User-defined labels for categorization
{"environment":"production","team":"search"}properties <= 20Empty Object
Version information
"1.0.0"Monitoring endpoint URL
"https://monitoring.example.com/rerankers/status"Optional owner principal UUID. If omitted, defaults to the authenticated principal. CREATE_RERANKER is evaluated against the proposed reranker and owner.
"550e8400-e29b-41d4-a716-446655440000"uuidOptional client-provided UUID for idempotent creation. If not provided, server generates a new UUID. Returns ALREADY_EXISTS if ID is already in use.
"550e8400-e29b-41d4-a716-446655440000"uuidResponse Body
curl -X POST "https://your-goodmem-server.example.com/v1/rerankers" \ -H "Content-Type: application/json" \ -d '{ "displayName": "BGE Cross-Encoder Reranker", "description": "BAAI BGE reranker for cross-encoder semantic ranking", "endpointUrl": "http://bge.reranker.goodmem.ai:8010", "apiPath": "/rerank", "modelIdentifier": "BAAI/bge-reranker-base", "supportedModalities": [ "TEXT" ], "credentials": { "apiKey": { "inlineSecret": "sk-demo-api-key", "secretRef": { "uri": "vault://path/to/secret" }, "headerName": "Authorization", "prefix": "Bearer " }, "kind": "CREDENTIAL_KIND_API_KEY" }, "labels": { "environment": "production", "team": "search" }, "version": "1.0.0", "monitoringEndpoint": "https://monitoring.example.com/rerankers/status", "ownerId": "550e8400-e29b-41d4-a716-446655440000", "rerankerId": "550e8400-e29b-41d4-a716-446655440000", "providerType": "TEI" }'{
"rerankerId": "550e8400-e29b-41d4-a716-446655440000",
"displayName": "BGE Cross-Encoder Reranker",
"description": "BAAI BGE reranker for cross-encoder semantic ranking",
"providerType": "TEI",
"endpointUrl": "http://bge.reranker.goodmem.ai:8010",
"apiPath": "/rerank",
"modelIdentifier": "BAAI/bge-reranker-base",
"supportedModalities": [
"TEXT"
],
"credentials": {
"apiKey": {
"inlineSecret": "sk-1234567890abcdef",
"secretRef": {
"uri": "vault://path/to/secret"
},
"headerName": "Authorization",
"prefix": "Bearer "
},
"gcpAdc": {
"scopes": [
"https://www.googleapis.com/auth/cloud-platform"
],
"quotaProjectId": "my-quota-project"
}
},
"labels": {
"environment": "production",
"team": "search"
},
"version": "1.0.0",
"monitoringEndpoint": "https://monitoring.example.com/rerankers/status",
"ownerId": "550e8400-e29b-41d4-a716-446655440000",
"createdAt": 1617293472000,
"updatedAt": 1617293472000,
"createdById": "550e8400-e29b-41d4-a716-446655440000",
"updatedById": "550e8400-e29b-41d4-a716-446655440000"
}