POST https://51kik.com/v1/embeddings

Generate embedding vectors for text. Shape follows the OpenAI Embeddings API.

Authentication

Authorization: Bearer YOUR_API_KEY

Request body

FieldRequiredDescription
modelyesCatalog id for an embedding-capable model
inputyesString or array of strings
encoding_formatnofloat (default) or base64
dimensionsnoReduced dimensions when upstream supports
usernoOptional end-user id
extra_bodynoGateway extension: JSON merged into upstream extra_body (OpenAI-compatible routes)

Limit: JSON body up to 32 MB.

Other top-level fields may pass through when allowed.

Example

curl -sS "https://51kik.com/v1/embeddings" \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "YOUR_EMBEDDING_MODEL_ID",
    "input": ["hello world", "routerbrain"]
  }'

Response

OpenAI-shaped: data[] with embedding and index, plus model and usage.

Errors

StatusTypical cause
400Model does not support embeddings, invalid body
401Invalid key
403Model denied or balance
429Rate limit

See Errors.

SDK

embeddings.* on @routerbrain/sdk is not implemented — use this HTTP endpoint.

Related