Clone Collection
Clone a collection with optional modifications.
Purpose: Creates a NEW collection (with new ID) based on an existing one. This is the recommended way to iterate on collection designs when you need to modify core configuration that PATCH doesn’t allow (source, feature_extractor, field_passthrough).
Clone vs PATCH vs Template:
- PATCH: Update metadata only (enabled, metadata, taxonomy_applications)
- Clone: Copy and modify core configuration (source, feature_extractor)
- Template: Start from a pre-configured pattern (for new projects)
Common Use Cases:
- Change feature extractor configuration (model, parameters)
- Modify field_passthrough to include/exclude fields
- Switch to different source (bucket or collection)
- Test modifications before replacing production collection
- Create variants (e.g., different embedding models)
How it works:
- Source collection is copied
- You provide a new name (REQUIRED)
- Optionally override any other fields
- A new collection is created with a new ID
- Original collection remains unchanged
Headers
Bearer token authentication using your API key. Format: 'Bearer sk_xxxxxxxxxxxxx'. You can create API keys in the Mixpeek dashboard under Organization Settings.
"Bearer YOUR_MIXPEEK_API_KEY"
Namespace identifier for scoping this request. All resources (collections, buckets, taxonomies, etc.) are scoped to a namespace. You can provide either the namespace name or namespace ID. Format: ns_xxxxxxxxxxxxx (ID) or a custom name like 'my-namespace'. Falls back to ?namespace= query parameter if the header is omitted.
"ns_abc123def456"
"production"
"my-namespace"
Path Parameters
Source collection ID or name to clone.
Body
Request to clone a collection with optional modifications.
Purpose: Cloning creates a NEW collection (with new ID) based on an existing one, allowing you to make changes that aren't allowed via PATCH (source, feature_extractor, field_passthrough). This is the recommended way to iterate on collection designs.
Clone vs Template vs Version:
- Clone: Copy THIS collection and modify it (for iteration/fixes)
- Template: Create collection from a reusable pattern (for new projects)
- Version: (Not implemented) - Use clone instead
Use Cases:
- Change feature extractor configuration without breaking production
- Modify field_passthrough to include/exclude fields
- Switch to different source (bucket or collection)
- Test modifications before replacing production collection
- Create variants (e.g., different embedding models)
All fields are OPTIONAL:
- Omit a field to keep the original value
- Provide a field to override the original value
- collection_name is REQUIRED (clones must have unique names)
REQUIRED. Name for the cloned collection. Must be unique and different from the source collection.
1"product_embeddings_v2"
"video_frames_clip_v2"
OPTIONAL. Description override. If omitted, copies from source collection.
"Cloned from product_embeddings with CLIP v2"
OPTIONAL. Override source configuration. If omitted, copies from source collection. Allows switching between buckets or collections.
{
"bucket_ids": ["bkt_marketing_videos"],
"description": "Single bucket source",
"type": "bucket"
}OPTIONAL. Override feature extractor configuration. If omitted, copies from source collection. This is where you'd change models, parameters, or field_passthrough.
{
"description": "Text extractor with field passthrough",
"feature_extractor_name": "text_extractor",
"field_passthrough": [
{ "required": true, "source_path": "title" },
{ "source_path": "author" }
],
"input_mappings": { "text": "content" },
"parameters": { "model": "text-embedding-3-small" },
"version": "v1"
}OPTIONAL. Override enabled status. If omitted, copies from source collection.
OPTIONAL. Override metadata. If omitted, copies from source collection.
OPTIONAL. Override taxonomy applications. If omitted, copies from source collection.
Response
Successful Response
Response after cloning a collection.
Cloned collection configuration with new collection_id.
{
"collection_id": "col_a1b2c3d4e5",
"collection_name": "article_embeddings",
"description": "Simple text collection: News articles with text embeddings from bucket source",
"enabled": true,
"feature_extractor": {
"feature_extractor_name": "text_extractor",
"field_passthrough": [{ "source_path": "title" }],
"input_mappings": { "text": "content" },
"version": "v1"
},
"input_schema": {
"properties": {
"title": { "type": "string" },
"content": { "type": "text" }
}
},
"output_schema": {
"properties": {
"title": { "type": "string" },
"text_extractor_v1_embedding": { "type": "array" }
}
},
"source": {
"bucket_id": "bkt_articles",
"type": "bucket"
}
}{
"collection_id": "col_xyz789abc",
"collection_name": "video_frames",
"description": "Video frames: Extracted at 1 FPS with CLIP embeddings and campaign_id passthrough",
"enabled": true,
"feature_extractor": {
"feature_extractor_name": "multimodal_extractor",
"field_passthrough": [{ "source_path": "campaign_id" }],
"input_mappings": { "video": "video" },
"parameters": { "fps": 1 },
"version": "v1"
},
"input_schema": {
"properties": {
"video": { "type": "video" },
"campaign_id": { "type": "string" }
}
},
"output_schema": {
"properties": {
"campaign_id": { "type": "string" },
"multimodal_extractor_v1_embedding": { "type": "array" }
}
},
"source": {
"bucket_id": "bkt_marketing_videos",
"type": "bucket"
}
}{
"collection_id": "col_scenes_def",
"collection_name": "detected_scenes",
"description": "Tier 2 decomposition: Scenes detected from frame embeddings (collection source)",
"enabled": true,
"feature_extractor": {
"feature_extractor_name": "scene_extractor",
"field_passthrough": [{ "source_path": "campaign_id" }],
"input_mappings": {
"embedding": "multimodal_extractor_v1_embedding"
},
"version": "v1"
},
"input_schema": {
"properties": {
"campaign_id": { "type": "string" },
"multimodal_extractor_v1_embedding": { "type": "array" }
}
},
"output_schema": {
"properties": {
"campaign_id": { "type": "string" },
"scene_extractor_v1_embedding": { "type": "array" }
}
},
"source": {
"collection_id": "col_video_frames",
"type": "collection"
}
}ID of the source collection that was cloned.

