Images
Upload Product Image
Changed onPhotos are source and proof of data. The first photo uploaded for a product is auto-selected as the product’s “front” photo.'
post/cgi/product_image_upload.pl
Request
- Base URLhttps://world.openfoodfacts.net
- AuthAPI key in cookie session and API key in header User-Agent
Request body multipart/form-data
Example request
{
"code": "3017620422003",
"imagefield": "front_en"
}Response
OK
Example response
{
"files": [
{
"url": "/product/3017620422003/nutella-ferrero",
"name": "Nutella - Ferrero - 400g",
"thumbnailUrl": "/images/products/301/762/042/2003/123.100.jpg",
"code": "3017620422003"
}
],
"image": {
"thumb_url": "123.100.jpg",
"imgid": 123,
"crop_url": "123.400.jpg"
},
"imgid": 123,
"status": "status ok",
"imagefield": "front_en",
"code": "3017620422003"
}Changes
- breaking
added to the request body
allOflist - breaking
the response's body type changed from no type to
objectfor status - warning
removed from the request body
allOflist
6 more changes in this revision
- breaking