I am trying to POST to
192.168.2.153/rest/V1/products/{MYSKU}/media
I used several online picture to BASE64 converter to convert to BASE64.
The first line looks like
data:image/jpeg;base64,/9j/4AAQSkZJRgABAQEAYABgAA
And here is my body (without the BASE64 code to save space here):
{
"entry": {
"media_type": "image",
"label": "new_picture",
"types": [
"image"
],
"file": "pic1.jpg",
"content": {
"base64_encoded_data": "",
"type": "image",
"name": "pic1.jpg"
}
}
}
I am only getting
The image content must be valid base64 encoded data.
Whatever I try no luck.