Assets

Upload an asset

Multipart upload of a single image to your asset library. Use this when you have a reference you'll reuse across multiple generations — for example a recurring model headshot or a brand-approved background. For one-off references, attaching to POST /v1/generations directly is fine; that endpoint also saves uploads as assets automatically. Counts against your storage quota.

post/v1/assets

Request

  • Base URL: https://nanostudiopro.com/api
  • URL: https://nanostudiopro.com/api/v1/assets
  • Auth: HTTP bearer

Response

The same file (byte for byte) was already uploaded to this account in this category: the existing asset comes back with duplicate: true. Nothing is stored, scanned or charged; a project_id adds it to that project.

idstring
category'model' | 'pose' | 'background' | 'shoe' | 'accessory' | 'upload' | 'product'
namestring
file_pathstring

Internal storage key (use url for fetching).

urlstring uri

Signed URL tied to a ~6-hour signing window. Use this to display or download the asset; re-fetch the resource for a fresh one.

permanent_urlstring uri

A link that never expires: embed it in a page, an email or another product. Append &size=xs|thumb|preview|large|original (default original). Anyone holding it can view this one image; deleting the asset revokes it. See GET /v1/media/{type}/{id}.

project_idstring nullable
metadataobject nullable

The fields you sent as metadata on upload, returned unchanged.

widthinteger nullable
heightinteger nullable
sizeinteger nullable

File size in bytes.

mime_typestring nullable
created_atstring date-time

Changes

No recorded changes to this operation across all 2 revisions of this API.