Skip to main content
Adds new vectors to the index or updates existing ones. Vector data is encrypted end-to-end before being stored.

Parameters (Upsert)

Parameters (UpsertVectors)

UpsertVectors automatically uses an optimized binary transfer format for better performance with large batches.

VectorItem

Contents is a generated nullable wrapper and is not directly constructible from the public package. See the Types reference for the helper-based setter pattern; most Go code leaves it zero-valued.

Returns

Exceptions

  • Throws if the API request fails due to network connectivity issues.
  • Throws if authentication fails (invalid API key).
  • Throws if the encryption key is invalid for the specified index.
  • Throws if there are internal server errors preventing the upsert.
  • Throws detailed validation errors for invalid VectorItem objects.
  • Throws if vector dimensions don’t match the index configuration.
  • Throws if required fields are missing from vector items.
  • Throws if array lengths don’t match in parallel array format.
  • Throws if vector elements are not finite numbers.

Example Usage

Upsert with Metadata

UpsertVectors (Binary Format)