Create a new embedder
POST /v1/embedders: Creates a new embedder configuration for vectorizing content.
Creates a new embedder configuration for vectorizing content. Embedders represent connections to different embedding API services (like OpenAI, vLLM, etc.) and include all the necessary configuration to use them with memory spaces.
DUPLICATE DETECTION: Returns HTTP 409 Conflict (ALREADY_EXISTS) if another embedder exists with identical {ownerId, providerType, endpointUrl, apiPath, modelIdentifier, dimensionality, distributionType, 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. The apiPath field defaults to '/v2/embed' for Cohere, '/v1/embeddings' for Jina, '/embed' for TEI, and '/embeddings' for other providers when omitted.
OWNER DEFAULTS: Owner defaults to the authenticated principal unless ownerId is provided; CREATE_EMBEDDER is evaluated against the proposed embedder and owner.
In: header
Embedder configuration details
User-facing name of the embedder
"OpenAI Ada-2"1 <= length <= 255Description of the embedder
"OpenAI's text embedding model with 1536 dimensions"Type of embedding provider
"OPENAI""OPENAI" | "VLLM" | "TEI" | "LLAMA_CPP" | "VOYAGE" | "COHERE" | "JINA"API endpoint URL
"https://api.openai.com/v1"API path for embeddings requests (defaults: Cohere /v2/embed, Jina /v1/embeddings, TEI /embed, others /embeddings)
"/embeddings"Model identifier
"text-embedding-3-small"Output vector dimensions
1536int321 <= valueType of embedding distribution (DENSE or SPARSE)
"DENSE""DENSE" | "SPARSE"Maximum input sequence length
8192int321 <= valueSupported 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-example-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":"nlp"}properties <= 20Empty Object
Version information
"1.0.0"Monitoring endpoint URL
"https://monitoring.example.com/embedders/status"Optional owner principal UUID. If omitted, defaults to the authenticated principal. CREATE_EMBEDDER is evaluated against the proposed embedder 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/embedders" \ -H "Content-Type: application/json" \ -d '{ "displayName": "OpenAI Embedding Model", "description": "OpenAI text embedding model with 1536 dimensions", "endpointUrl": "https://api.openai.com/v1", "apiPath": "/embeddings", "modelIdentifier": "text-embedding-3-small", "dimensionality": 1536, "maxSequenceLength": 8192, "supportedModalities": [ "TEXT" ], "credentials": { "apiKey": { "inlineSecret": "sk-your-api-key-here", "secretRef": { "uri": "vault://path/to/secret" }, "headerName": "Authorization", "prefix": "Bearer " }, "kind": "CREDENTIAL_KIND_API_KEY" }, "labels": { "environment": "production", "team": "nlp" }, "version": "1.0.0", "monitoringEndpoint": "https://monitoring.example.com/embedders/status", "ownerId": "550e8400-e29b-41d4-a716-446655440000", "embedderId": "550e8400-e29b-41d4-a716-446655440000", "providerType": "OPENAI", "distributionType": "DENSE" }'{
"embedderId": "550e8400-e29b-41d4-a716-446655440000",
"displayName": "OpenAI Ada-2",
"description": "OpenAI's text embedding model with 1536 dimensions",
"providerType": "OPENAI",
"endpointUrl": "https://api.openai.com/v1",
"apiPath": "/embeddings",
"modelIdentifier": "text-embedding-3-small",
"dimensionality": 1536,
"distributionType": "DENSE",
"maxSequenceLength": 8192,
"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": "nlp"
},
"version": "1.0.0",
"monitoringEndpoint": "https://monitoring.example.com/embedders/status",
"ownerId": "550e8400-e29b-41d4-a716-446655440000",
"createdAt": 1617293472000,
"updatedAt": 1617293472000,
"createdById": "550e8400-e29b-41d4-a716-446655440000",
"updatedById": "550e8400-e29b-41d4-a716-446655440000"
}