Changes

Jump to navigation Jump to search
90 bytes added ,  10:36, 10 May 2016
→‎Posting photos: use only POST parameters
Line 196: Line 196:  
== WRITE API Documentation ==
 
== WRITE API Documentation ==
 
=== Posting photos ===
 
=== Posting photos ===
* Photos post on /cgi/product_image_upload.pl
+
* Use the POST method on /cgi/product_image_upload.pl
 
** code: the barcode
 
** code: the barcode
 
** imagefield: (front | ingredients | nutrition)
 
** imagefield: (front | ingredients | nutrition)
Line 206: Line 206:  
* there must be a HTTP header "Content-Type: multipart/form-data" in the HTTP POST request.
 
* there must be a HTTP header "Content-Type: multipart/form-data" in the HTTP POST request.
 
* the imageupload_(front|ingredients|nutrition) name, size and data needs to be encoded in the multipart/form-data format, usually your HTTP request library will do that for you
 
* the imageupload_(front|ingredients|nutrition) name, size and data needs to be encoded in the multipart/form-data format, usually your HTTP request library will do that for you
 +
* all parameters need to be passed as POST parameters, do not put some in the URL
     

Navigation menu