For the complete documentation index, see llms.txt. This page is also available as Markdown.

Create a special image

Assigns the image_type role to a product's image. Because (product, image_type) is unique, any existing special image of the same type for the same product is replaced — the previous record is removed and this one is created in its place.

post
/special_image/
Authorizations
AuthorizationstringRequired

Token credential sent in the Authorization header, in the form: Token <your-token>. Requires a staff (admin) account.

Body

Fields for creating or fully replacing a special image.

productintegerRequired

Identifier of the product the image belongs to.

product_imageintegerRequired

Identifier of the product image to flag.

image_typestring · enumRequired

The role a special image plays for its product. Each type is unique per product.

  • base — the product's primary/base image
  • swatch — a color or material swatch image
  • listing — the image used in product listings
  • picto — a pictogram / icon image
Possible values:
Responses
201

The special image was created.

application/json

A special image record — marks one of a product's images with a specific role.

pkintegerRead-onlyRequired

Unique identifier of the special image.

productintegerRequired

Identifier of the product the image belongs to.

product_imageintegerRequired

Identifier of the underlying product image that is being flagged.

image_typestring · enumRequired

The role a special image plays for its product. Each type is unique per product.

  • base — the product's primary/base image
  • swatch — a color or material swatch image
  • listing — the image used in product listings
  • picto — a pictogram / icon image
Possible values:
post/special_image/
POST /api/v1/remote/1/special_image/ HTTP/1.1
Host: sandbox.akinon.com
Authorization: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 55

{
  "product": 340,
  "product_image": 981,
  "image_type": "base"
}
{
  "pk": 12,
  "product": 340,
  "product_image": 981,
  "image_type": "base"
}

Last updated

Was this helpful?