Skip to main content
Collections support arbitrary key-value metadata. Updates use deep merge — nested dictionaries are merged recursively, preserving existing keys. See Metadata for more on how metadata works in Docent.

Get Metadata

Parameters

str
required
ID of the collection.

Returns

dict
The collection’s metadata dictionary.

Update Metadata

Updates are deep-merged into existing metadata. Existing keys not in the update are preserved.

Parameters

str
required
ID of the collection.
dict
required
Metadata to merge into the existing metadata.

Returns

dict
The full merged metadata dictionary after the update.

Delete Metadata Keys

Remove specific keys from metadata. Supports dot-delimited paths for nested deletion.

Parameters

str
required
ID of the collection.
list[str]
required
Keys to remove. Use dot notation for nested keys (e.g., "config.model").

Returns

Returns a tuple of two values:
dict
The metadata dictionary after deletion.
list[str]
Keys that were not found in the metadata.