collections

Copy Collection

Clone metadata, documents, and vectors under a new name. Instant regardless of size.

post/v2/collections/{collection_name}/copy

Path parameters

collection_namestring required

Request body

target_namestring required

Name for the copy. Must be unique within the organization and environment. Same rules as creating a collection: 3-63 characters, alphanumeric start and end, letters, numbers, hyphens and underscores only.

include_graphboolean

Copy the collection's chunk relations and chunk metadata along with its documents and vectors. Defaults to true so a copy is a faithful original; set false to copy documents and vectors only.

Response

Successful Response

successboolean required
messagestring required
source_collectionstring required

Name of the collection copied from.

collection_namestring required

Name of the new copy.

database_idstring required

ID of the new copy.

documents_copiedinteger required

Number of documents cloned.

files_copiedinteger

Number of files cloned.

namespaces_copiedinteger required

Number of Turbopuffer namespaces copied (text plus any media).

relations_copiedinteger

Number of chunk relations cloned. Counts ROWS, not distinct edges: duplicate (source, target, type) triples in the source are reproduced faithfully.

chunk_metadata_copiedinteger

Number of chunk metadata rows cloned.

relations_unresolvedinteger

Relations copied whose target document could not be remapped into the new collection, so their target_document_id is null. Usually these are edges already broken in the source (the target document was deleted, or the id never matched a document); if the source was being indexed while the copy ran, a freshly created edge can also land here. The copy reproduces the edge rather than writing a pointer that resolves to nothing.

Changes