Skip to main content
Searches for nearest neighbors in the encrypted index using vector similarity search. Supports single vector queries, batch queries, and semantic search with text content.

Parameters

QueryParams

Include defaults differ between endpoints: Query returns [] (only Id) by default, while Get returns ["vector", "contents", "metadata"].

Returns

  • *QueryResponse: Search results containing vectors, distances, and requested fields
  • error: Any error encountered during the search operation

Error Handling

  • Returns error if the API request fails due to network connectivity issues
  • Returns error if authentication fails (invalid API key)
  • Returns error if the encryption key is invalid for the specified index
  • Returns error if there are internal server errors during the search
  • Returns error if none of QueryVector, BatchQueryVectors, or QueryContents is provided
  • Returns error if vector dimensions don’t match the index configuration
  • Returns error if parameter values are out of valid ranges
  • Returns error if the Include parameter contains invalid field names

Example Usage

Single Vector Query

Batch Vector Query

Semantic Search with Text

BinaryQueryParams is available as an alternative to QueryParams that uses binary transfer for large batch queries. This can significantly improve performance when querying with many vectors at once.
BinaryQueryParams does not accept RerankMult — it is supported only on QueryParams. Use QueryParams if you need to tune the stage-1 candidate multiplier on a reranking index.