Collection Schema

Sync Collection Schema

Changed on

Sample documents from the vector store and automatically discover new fields to add to the collection's output_schema.

This endpoint:
- Samples N documents from the collection (default: 1000)
- Discovers all fields present in actual documents
- Merges discovered fields into the collection's output_schema (additive only)
- Optionally cascades schema updates to downstream collections
- Respects debounce window (max once per 5 minutes, unless force=true)

The sync operation is additive only - it never removes or changes existing field types.

Use this endpoint to:
- Manually trigger schema discovery after data ingestion
- Force an immediate schema sync (bypassing debounce)
- Update schemas with new fields discovered in documents
post/v1/collections/{collection_id}/sync-schema

Request

  • Base URL: https://api.mixpeek.com
  • URL: https://api.mixpeek.com/v1/collections/{collection_id}/sync-schema
  • Auth: HTTP bearer and API key in header X-Namespace

Path parameters

collection_idstring required

Collection ID to sync schema for

Request body

sample_sizeinteger

Number of documents to sample for schema discovery

forceboolean

Force schema sync even if within debounce window. Default: false (respects 5-minute debounce)

cascade_to_downstreamboolean

Automatically update downstream collections that use this collection as source. Default: true

Response

Successful Response

OR

Changes

    • warning

      removed the optional property from the response with the status

    • info

      added the non-success response with the status

    • info

      added the non-success response with the status

    • info

      added the optional property to the response with the status

    • info

      added the required property to the response with the status

    • info

      added the required property to the response with the status

    • info

      the endpoint scheme security BearerAuth AND NamespaceHeader was added to the API