Open2b versione 7.5

product-images

Returns the images of the given products.

Request

HTTP POST
/api/v10/storefront.product-images
{
  "products" : [ 281, 89, … ], // products (ID) - int(1…)
  "onlyFirst" : true, // reports whether return only the first image of each gallery - bool
  "fields" : [ "product", "option", … ] // fields to return - string
}

Response

{
  "status" : "ok",
  "images" : [ { // images
    "product" : 281, // product (ID) - int(1…)
    "option" : null, // option (ID) (can be null) - int(1…)
    "thumbnail" : { // thumbnail image
      "url" : "https://…", // URL - string(10…)
      "url2x" : "https://…", // double resolution URL (can be null) - string(10…)
      "width" : 40, // width in pixel - int(30…50)
      "height" : 40 // height in pixel - int(30…50)
    },
    "small" : { // small image
      "url" : "https://…", // URL - string(10…)
      "url2x" : "https://…", // double resolution URL (can be null) - string(10…)
      "width" : 70, // width in pixel - int(50…250)
      "height" : 70 // height in pixel - int(50…250)
    },
    "medium" : { // medium image
      "url" : "https://…", // URL - string(10…)
      "url2x" : "https://…", // double resolution URL (can be null) - string(10…)
      "width" : 150, // width in pixel - int(50…250)
      "height" : 150 // height in pixel - int(50…250)
    },
    "large" : { // large image
      "url" : "https://…", // URL - string(10…)
      "url2x" : "https://…", // double resolution URL (can be null) - string(10…)
      "width" : 300, // width in pixel - int(250…800)
      "height" : 300 // height in pixel - int(250…800)
    },
    "zoom" : { // zoom image (can be null)
      "url" : "https://…", // URL - string(10…)
      "url2x" : "https://…", // double resolution URL (can be null) - string(10…)
      "width" : 1200, // width in pixel - int(250…)
      "height" : 1200 // height in pixel - int(250…)
    }
  }, … ]
}