OriginChainDB
Database endpoints

Store a vector

Stores one dense vector, with optional metadata, in a vector collection.

POST /v1/tenants/{tenant}/vector/{table}/put

Store an embedding for later comparisonGenerate the embedding separately; success returns an empty 201 response.
  1. Prepare the numeric vectorMatch its component count to the collection dimension.
  2. Assign an ID and metadataKeep a link to the source item.
  3. Store it in the collectionUse matching metric and index settings.

Before you start

Use your database bearer token.

Connection setup

Use a collection with the intended dimension and distance metric. The example uses three-dimensional vectors and cosine distance; use real embeddings for meaningful search.

Path parameters

FieldTypeRequired
tenantstringRequired
tablestringRequired

Headers

FieldTypeRequiredDescription
x-oc-db-userstringOptionalActing database user (role, grant and row-policy checks). Send with x-oc-db-key.
x-oc-db-keystringOptionalAPI key of the x-oc-db-user user.

Request body

application/json

Limits and accepted values
  • metric: cosine | dot | l2 | manhattan (alias l1), defaulting to the collection's declared distance, else cosine;
  • quantization: none | scalar | binary;
  • index: hnsw (default) | ivf | ivf_pq (IVF needs installed centroids).
  • `embedding` must have `dim` components.
  • Success is 201 with an empty body.
FieldTypeRequired
dimintegerRequired
embedderstringOptional
embeddingnumber[]Required
Fields in embedding
FieldTypeRequired
embeddingnumberOptional
FieldTypeRequired
idstringRequired
indexstringOptional
metadataobjectOptional
metricstringOptional
quantizationstringOptional

Read the result

Success is 201 with an empty body. The vector must contain exactly dim numeric components; indexing an embedding is separate from generating one from text.

Response statuses

HTTP status reference
StatusWhat to do
201Created
400Correct the request before retrying.
401Check the credential and Authorization header.
402Check feature access or available credits.
403Check tenant access, roles and permissions.
409Resolve the conflict before retrying.
413Split or reduce the request body.
415Send the required Content-Type.
422Correct the values or unsupported combination.
429Honor Retry-After when present; back off.
500Check the outcome before retrying a write.
503Honor Retry-After when present; check write outcomes.
ยฉ 2026 Silicoyn Technologies Pvt Ltd