Methods
- product_media.list
- product_media.types
- product_media.create
- product_media.update
- product_media.remove
Entity Properties
product_media.list
product_media.list (string $sku)
Retrieve list of product images
Parameters
string
Product SKU.
Return Value
An array of objects. Each object will contain Image Data.Example Request
Get product images by product SKU:Request
Example Response
Response
Error Codes
product_media.types
product_media.types (number $setId)
Retrieve product image types
Parameters
integer
Attribute set id.
Return Value
An array of objects. Each object will contain Image Type Properties.Example Request
Request
Example Response
Response
product_media.create
product_media.create (string $sku, object $data)
Upload new product image
Parameters
string
Product SKU.
object
Image data.
Return Value
Image file name (e.g., “/i/m/image.png”)Example Request
Request
Example Response
Response
Error Codes
product_media.update
product_media.update (string $sku, string $file, object $data)
Update product image
Parameters
string
Product SKU.
string
Image file name.
object
Image data.
Return Value
true, if the image has been uploaded
Example Request
Request
Example Response
Response
Error Codes
product_media.remove
product_media.remove (string $sku, string $file)
Remove product image
Parameters
string
Product SKU.
string
Image file.
Return Value
true, if the image has been removed
Example Request
Request
Example Response
Response