Databases
Update Metadata Schema
Add new database metadata schema fields after database creation.
PATCH
Use this endpoint to add new fields to a database’s
database_metadata_schema.
Request
Path parameters
Body
Each
add_fields[] item uses the same field shape as database_metadata_schema on Create Database:
Rules
- Additions only.
- Existing field names cannot be reused, case-insensitively.
- Existing fields cannot be deleted or changed.
- Total custom database metadata fields cannot exceed 32.
- Reserved names such as
source_id,chunk_id,metadata, anddocument_metadataare rejected. - Dense/sparse embedding flags are only valid on
VARCHARfields. - MongoDB indexes for
enable_matchfields are created before the merged schema is persisted.
Response
Errors
Related
Authorizations
API key sent as a Bearer token: "Bearer prefix.secret"
Path Parameters
Database identifier
Example:
"acme_corp"
Body
application/json
Metadata schema fields to add
New metadata schema fields to add to the database. Additive only — no deletes, renames, or type changes.
Example: