Jump to content

(Résolu) Trying to send image with curl tools and webservices


JCV

Recommended Posts

Hello,

I'm currently interfacing my Erp to Prestashop 1.7.2.4 by the web service and the curl.exe tool.

I write the xml datas in a file and I use curl to send and receive informations.

I already send categories, products, and stocks ... ouff !

Now I'm trying to send pictures  like this :

curl.exe -X POST --header "Content-Type: image/jpeg" --data-binary @c:\gi\fabel\images\tri0000000029.jpg --user XXXXXXXXXXXXXXXXXX: www.MySite.com/shop/api/images/products/23 -o c:\gi\fabel\presta\111800002409img_2gi.xml 

but I always an error 66 !

image.png.4dc74ad17fab03915b7ed0f290a561f6.png

Can you tell me if the method is good ?  or must I put the image inside a XML file ? a sample ?

 

Thank for your help.

JC

 

 

Edited by JCV (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...