Update Product Image
PUT/api/product-images/:productImage
Updates a product image's metadata and optionally replaces the image itself.
products:writeGrant this scope to your token under Settings → Developer → Personal Access Tokens.
Body fields (all optional on update):
- image (string) — a new image as an external URL or a base64 data URI (data:image/...;base64,...). Omit to keep the current image and only update metadata.
- name (string, max 255) — display name for the image
- sort_order (integer) — position within the product's image list
- is_primary (boolean) — mark as the product's primary image
- download (boolean) — when true and image is an external URL, the file is downloaded and stored on SKU.io storage instead of hot-linking the URL
If an external image URL cannot be resolved, the update still succeeds but the response includes a warning and the image is stored with resolvable: false.
Authentication: Requires Bearer token.
- swatch_variant_attribute (optional, max 255): marks this image as the variant swatch for the named variant attribute (e.g. "color"). Sales channels that support swatches render it as the variant's swatch image. Omit or send null for a normal gallery image.
Request
Responses
- 200
- 401
- 403
- 404
- 422
- 429
OK
Response Headers
Unauthenticated — the bearer token is missing, revoked, expired, or malformed. Never retry automatically; fix the credential. See the Errors guide.
Forbidden — the token lacks a required scope, the endpoint is not available to API tokens, or the user behind the token lacks the permission. A human must adjust the token scopes or user permissions; do not retry.
Not Found
Response Headers
Unprocessable Entity
Response Headers
Rate limited — platform limit is 1,000 requests/min; individual tokens may carry lower limits. Honor the Retry-After header before retrying. See the Rate Limits guide.