BYO Documents

Upsert documents with BYO vectors

Upsert documents with user-provided vectors directly into a namespace. This bypasses the collection/batch/extractor pipeline entirely. Documents go directly to the vector store. Maximum 1000 documents per call.

post/v1/namespaces/{namespace_id}/documents/upsert

Path parameters

namespace_idstring required

The namespace to upsert documents into.

Example:ns_abc123def456

The namespace to upsert documents into.

Request body

collection_idstring nullable

Target collection. Documents are tagged with this collection_id so they appear in collection-scoped queries, list, and clustering. When omitted a namespace-level default collection is used.

Response

Successful Response

insertedinteger required

Number of documents upserted.

document_idsstring[] required

IDs of all upserted documents.

write_tokenstring nullable

Opaque token for read-your-writes consistency (only when requested).

dropped_payload_fieldsobject

document_id -> payload field names that were REMOVED before storage because they collide with reserved internal field names. Their values are not stored anywhere and are not readable back. Rename the field (e.g. 'source_type' -> 'my_source_type') or nest it under 'metadata' to keep the value. Empty when nothing was dropped.

Changes

Changed in 4 of the 31 revisions of this API.12

    • added the new signal enum value to the request property documents/items/source_type/anyOf[subschema #1]/

      request-property-enum-value-added

    • added the optional property dropped_payload_fields to the response with the 200 status

      response-optional-property-added

    • added the new optional request property documents/items/content_hash

      new-optional-request-property

    • added the new optional request property documents/items/lineage_chain

      new-optional-request-property

    • added the new optional request property documents/items/lineage_path

      new-optional-request-property

    • added the new optional request property documents/items/root_bucket_id

      new-optional-request-property

    • added the new optional request property documents/items/root_object_id

      new-optional-request-property

    • added the new optional request property documents/items/source_collection_id

      new-optional-request-property

    • added the new optional request property documents/items/source_document_id

      new-optional-request-property

    • added the new optional request property documents/items/source_object_id

      new-optional-request-property

    • added the new optional request property documents/items/source_type

      new-optional-request-property

    • the endpoint scheme security BearerAuth was added to the API

      api-security-added

    This revision also has 3 changes that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog