Upload a file
Accepts a file and returns a signed_id to send to the endpoint that
uses it — signed_id on product media, avatar_signed_id on a
customer, attachment_signed_id on an import, and so on.
Two ways to send the bytes, one response:
- Presigned (JSON): send the file’s metadata, then
PUTthe bytes toupload.urlwith exactlyupload.headers. Use this for anything large — the bytes go straight to storage. - Multipart: send the bytes in a
filepart. The file is stored before the response, souploadis null. Limited to 10 MB by default.
signed_id is opaque: pass it back unchanged and never parse it. It
stops being attachable at expires_at, one day after the upload.
visibility picks the storage: public (the default) for images and
videos customers see, private for documents, imports and digital
products. Public uploads accept web images, videos and CSV; private
uploads accept any type. checksum is the file’s MD5 digest,
base64-encoded — the storage service verifies the bytes against it.
Required scope: write_products (for API-key authentication).

