Attach Image
POST
/products/{product}/imagesThis endpoint allows you to add up to 10 images to a specific product by passing the product
as a path parameter.
:::tip[Note]
- You can only send one image per request.
- You can attach an image to a product either via URL link or by uploading an image.
:::
Request
The Product ID. List of Product ID can be found here.
A specific location or directory on a computer's file system that indicates the file's location.
Set the image as default
Sorting order of the image
Alternative text to appear when the image doesn't load properly.
Request samples
[api.label.responses]
Response status code, a numeric or alphanumeric identifier used to convey the outcome or status of a request, operation, or transaction in various systems and applications, typically indicating whether the action was successful, encountered an error, or resulted in a specific condition.
Response flag, boolean indicator used to signal a particular condition or state in the response of a system or application, often representing the presence or absence of certain conditions or outcomes.
A unique identifier associated with the product image.
Sort Order
Whether or not the image the default picture
Alternative SEO Text for the image
Video web address.
Attachment Type
{
"status": 201,
"success": true,
"data": {
"id": 713368802,
"image": {
"original": {
"url": "https://cdn.salla.sa/bYQEn/9oJoUzXfR8zzXAwAlTRHNIl1xBsuFpgcXdPnkAXd.png",
"width": 0,
"height": 0
},
"standard_resolution": {
"url": "https://cdn.salla.sa/bYQEn/9oJoUzXfR8zzXAwAlTRHNIl1xBsuFpgcXdPnkAXd.png",
"width": 0,
"height": 0
},
"low_resolution": {
"url": "https://cdn.salla.sa/bYQEn/9oJoUzXfR8zzXAwAlTRHNIl1xBsuFpgcXdPnkAXd.png",
"width": 0,
"height": 0
},
"thumbnail": {
"url": "https://cdn.salla.sa/bYQEn/9oJoUzXfR8zzXAwAlTRHNIl1xBsuFpgcXdPnkAXd.png",
"width": 0,
"height": 0
}
},
"sort": 5,
"default": true,
"alt_seo": "image",
"video_url": "",
"type": "image"
}
}