Skip to main content
Write a namespace’s resources in one YAML file, check it, and create everything in dependency order with one call. A manifest lives in version control, replicates an environment, and is how templates ship.

Prerequisites

  • An API key with write permission. A manifest that declares storage connections needs admin.
  • Any secrets the manifest references, created in your organization first.

Apply a manifest

1

Write the file

mixpeek.yaml
Resources refer to each other by name. Every collection needs a source and a feature_extractor; every retriever needs namespace, collections and stages. Copy feature URIs from GET /v1/discovery/schema (extractor_catalog) rather than typing them.
2

Validate and dry-run it

Validate, then show the plan
Validate returns valid, errors, warnings, missing_secrets and a count of resources per type. It runs every check apply runs, so a manifest it passes is one apply accepts. The dry run lists each resource as would_create, exists or drifted and creates nothing.
3

Apply it

Check that it worked

Read success and errors on every response. Apply can answer HTTP 200 with success: false when the plan has errors (nothing is created), when deadline_seconds passes before serving apps are running, or when a resource fails partway (rollback_performed: true, with rollback_orphans listing anything the rollback could not remove). task_id names the apply. GET /v1/tasks/{task_id} lists every resource with its states and times: planned, creating, created, exists, updated or failed, and for a collection also warming and ready. readiness in the response says whether each collection’s real-time serving app is running; an app scaled to zero answers its first call with 503 and Retry-After while it warms. With wait=false, apply answers 202 with pending: true at once and you poll the task.

Apply modes

Under create_only the manifest is a closed world: a reference to a resource it does not declare is an error. create_missing resolves references against what already exists, so use it to add collections over buckets created earlier. upsert is the only mode that changes existing resources. If a resource fails partway, apply rolls back what it created; an apply interrupted by an API restart is rolled back when the API starts again.

What a manifest can declare

Resources apply in this order: namespaces, extractors, storage connections and buckets, bucket syncs, collections, retrievers, alerts, clusters and taxonomies, triggers and webhooks. Apply detects circular references and refuses them. GET /v1/discovery/schema returns a JSON schema for every section, the dependency graph between types, an example per type, and the extractor and stage catalogs. The plan refuses, before anything is created:
  • an extractor that does not exist or is turned off, or a retriever stage that is not registered
  • a feature URI no collection in the manifest writes
  • two collections in one namespace writing the same vector at different sizes (set the same output_dimensionality on both)
  • an alert that does not map an input its retriever requires
  • any resource its own create request would refuse, reported as <type>:<name>: <field>: <reason>
  • a bucket sync whose sync_mode is not initial_only or continuous
Declare inputs so a template needs no hand edit, and reference them as ${{ params.<name> }}. A reference that is the whole value takes the parameter’s type; one inside a longer string is formatted as text. An array parameter must be a whole value.
parameters
Pass values as a JSON form field on validate, diff, lint and apply: -F 'parameters={"camera_url": "rtsp://10.0.0.8/stream"}'. A missing, mistyped, undeclared or duplicated parameter is refused before anything is created.
${{ secrets.NAME }} fills in an organization secret in a storage connection’s config, an alert’s notification_config, a webhook’s channels and a bucket sync’s connection. In a retriever the reference stays a reference ({{secrets.NAME}}) and resolves at each run, so the key is never stored. A secret reference anywhere else is refused, because those fields are readable with a read key. Validate lists missing secrets in missing_secrets.
An extractors: section declares the extractors collections run. Once it exists, every extractor a collection names must be declared in it. source is one of:compute_profile stores a batch override (resource_type, batch_size, max_concurrency, memory). A serve.min_replicas above 0 is refused with its monthly cost. Your own container images as extractors are covered in Custom extractors and models.
Namespace budget
A value above the organization’s budget is lowered to it and reported in warnings. See Budgets.
After resources exist, apply ingests seed: objects into the named bucket in one batch, up to max_objects (default 50, at most 500). Re-applying ingests nothing more. Each blob comes from a Mixpeek sample key (samples/starter/<file>), a public https:// URL, or {connection, path} for one object in your storage through an s3, tigris, gcs, azure_blob, backblaze or supabase connection. Other schema fields sit beside blobs.
seed
For everything under a prefix, use bucket_syncs with sync_mode: initial_only instead; see Object storage and syncs. For an s3, tigris or backblaze connection, source_path starts with the bucket name. A seed batch is billed like any batch.
  • alerts: mirrors the alerts API create request, plus namespace and retriever by name. See Alerts, triggers and webhooks.
  • edges: links two objects, each picked by bucket and a key of field values that matches exactly one object, with a type, optional inverse_type and attributes. Edges are written after the seed, on both objects, and traverse_edge follows them.
  • A flat taxonomy can carry inline labels with match_on (a feature URI) and target_field. Apply generates a <taxonomy>-labels bucket and collection, a <taxonomy>-lookup retriever and a seed. See Taxonomies.
An acceptance: block lists steps and what each must return. Apply runs them only with run_acceptance=true, which also waits for seed batches and serving apps within deadline_seconds (900 by default).max_cost_usd caps the run from your usage meter. success still reports resource creation only; read acceptance.passed. To re-run the steps on an existing namespace, apply again with mode=create_missing&run_acceptance=true. Steps are billed like the same calls made directly.

Diff, lint and export

Add detail=stats to an export for a read-only status section with each collection’s document count, field types and common values. Apply ignores status.
Replicate production into staging
In CI, run validate and diff on every pull request and apply with mode=upsert on merge.

Generate a manifest from a description

POST /v1/manifest/generate takes a plain-language description and returns a manifest. The model writing it reads the live extractor and stage catalogs, then runs the draft through validate and repairs it up to 2 times.
Describe it, get a manifest
GET /v1/discovery/schema returns this manifest as example_manifest, beside a JSON schema for every section, an extractor_catalog and a stage_catalog. It syncs ad videos from S3 once, seeds sample objects, indexes them in two collections, searches them with a hybrid retriever, tags each scene with a taxonomy, groups scenes with a cluster and states what a working setup returns. It validates once ads_s3_bucket is supplied and the secrets AWS_ACCESS_KEY_ID and AWS_SECRET_ACCESS_KEY exist.
Read the manifest, dry-run it, then apply it. To improve a generated manifest against your own labelled questions, score variants with retriever evaluations on a tuning split and compare finalists once on held-out labels. Try retriever changes first (seconds each) before model or extractor changes, which re-process data.

What goes wrong