commercetools icon

commercetools

Interact with the commercetools API. Operations are auto-generated from the official Postman collection.

Actions671

Store Product → Upload ProductTailoring image by Product ID

AI-generated

Summary

Upload a tailoring image to a specified product variant in a store by providing the Store Product Key, Product ID, and Store Key, along with the image URL and optional parameters such as filename, variant ID or SKU, and whether the update is staged.

Inputs

  • Store Product Key (required) — Key of the store product to which the tailoring image will be uploaded.
  • Product ID (required) — ID of the product within the store to which the image will be attached.
  • Store Key (required) — Key of the store where the product is located.
  • Image URL (required) — Publicly accessible URL of the image (JPEG, PNG, or GIF, max 10 MB) that commercetools fetches to upload.
  • Filename — Optional filename to store with the uploaded image.
  • Variant ID — ID of the ProductVariant to attach the image to; use 0 to attach to the Master Variant.
  • SKU — SKU of the ProductVariant as an alternative to Variant ID.
  • Staged — Boolean flag indicating whether to add the image to staged (true) or current (false) product data.

Output shape

a single JSON object representing the result of the upload operation from the commercetools API

The output is a JSON object reflecting the outcome of the image upload. The operation performs an HTTP request authenticated via OAuth2 credentials. Errors are thrown for failed requests unless 'Continue on Fail' mode is enabled, in which case errors are returned as part of the output with error messages.

Links

Discussion