Updates the metadata of an uploaded file. Only whitelisted fields are accepted (originalname, file_title, file_summary, file_authors, file_url, source_url, status, is_private, is_public, institution, account_shared, collection, embeddings_model, summary_model, image_analysis_model, audio_analysis_model). Setting is_public to true automatically forces is_private to false. Sending institution or collection as empty string or null triggers $unset. Users with accountType user can only update their own files. Admins can update files within their own institution, or files they originally uploaded (owner match) regardless of institution.
JWT token passed in x-access-token header
The unique identifier of the upload to update (must be a valid ObjectId)
Only whitelisted fields are accepted. Fields not in the allowed list are silently ignored. Setting is_public to true automatically forces is_private to false.
The original name of the uploaded file
"markdown_render_with_error_boundary"
The new status for the upload. active: default status. selected: file will be included in RAG searches. deleted: soft deleted, hidden from lists and RAG.
active, selected, deleted "selected"
When true, anyone with the link can access the file without authentication. Setting to true automatically clears is_private.
false
When true, marks the file as confidential (owner-only access, hidden from citations). Cannot be true when is_public is true.
true
Institution ID to share the file with. Send an empty string "" or null to unset (remove) the institution field via $unset.
Title for the file
Summary of the file content
Authors of the content
Whether the file is shared across the institution account
Collection ID. Send an empty string "" or null to remove from collection.