POST api/v1/ProductImage
Retrieve an image for a given product and image type
You can send either a product code or a product id dending on what you have stored
Request Information
URI Parameters
None.
Body Parameters
ProductImageParamsName | Description | Type | Additional information |
---|---|---|---|
apiKey |
Please contact Caliq support to get your key |
string |
Required |
ImageTypeID |
Derived from a call to ProductImageType |
integer |
Required |
ProductID |
The product id for which you want to retrieve the image. Can be used in place of ProductCode |
integer |
None. |
ProductCode |
The product code for which you want to retrieve the image. Can be used in place of ProductID |
string |
Max length: 25 |
Request Formats
application/json, text/json
{ "apiKey": "sample string 1", "ImageTypeID": 2, "ProductID": 3, "ProductCode": "sample string 4" }
application/xml, text/xml
<ProductImageParams xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <apiKey>sample string 1</apiKey> <ImageTypeID>2</ImageTypeID> <ProductID>3</ProductID> <ProductCode>sample string 4</ProductCode> </ProductImageParams>
Response Information
Resource Description
Returns:
200 OK Returns a base64 encoded version of the jpg image
204 No Content if the requested product code or product id either doesnt exist or has no image of the type requested
400 Bad Request - parameters supplied cannot be properly interpreted
401 Not Authorised if supplied api key is not valid
503 Service Unavailable
Response Formats
application/json, text/json
"sample string 1"
application/xml, text/xml
<string>sample string 1</string>