latestOpenAPI 3.0.3GNU General Public License v3.0raw.githubusercontent.com2026-08-137961230.0 KB

da017caf56f1

file

Update asset metadata

Updates an asset's metadata. At least one field must be provided. Only name, mime_type, preview_id, and user_metadata can be updated. For tag management, use POST (add) and DELETE (remove) /api/assets/{id}/tags.

put/api/assets/{id}

Path parameters

idstring uuid required

Asset ID

Request body

mime_typestring

Updated MIME type of the asset

namestring

New display name for the asset

preview_idstring uuid

Updated preview asset ID

user_metadataobject

Updated custom metadata

Response

Asset updated successfully

display_namestring nullable

Display name of the asset. Mirrors name for backwards compatibility.

file_pathstring nullable

Relative path in global-namespace-root form (e.g. "models/checkpoints/flux.safetensors")

hashstring

Blake3 hash of the asset content.

idstring uuid required

Asset ID

job_idstring uuid nullable

ID of the job that created this asset, if available

loader_pathstring nullable

The bare value a loader widget consumes for this asset. For models it is the path inside the category folder (e.g. "flux.safetensors" for "models/checkpoints/flux.safetensors"), which is what the model resolver matches. For input/output/temp it is the content hash, because those assets are fetched by hash rather than staged by name — that is the value LoadImage-style widgets must carry. Clients add the "[output]"/"[temp]" annotation from the asset's own type, so it is never included here. Null when no such value can be derived.

mime_typestring

Updated MIME type of the asset

namestring

Updated name of the asset

tagsstring[]

Tags associated with the asset

updated_atstring date-time required

Timestamp of the update

user_metadataobject

Updated custom metadata