strife's devLog

Month: July, 2014

prestashop-logo[Prestashop] How to Debug Prestashop API?

There are severals ways to make it right. Below I described my way of testing Prestashop API using cURL as the tool that checkes all dependencies. After enabling Prestashop API in your administration panel, save the API Key.

Depends what you want to check your xml files would be different. All possibilites you can find in the Prestashop API documentation, for instance: http://doc.prestashop.com/display/PS14/Chapter+4+-+Retrieve+Data+-+Retrieving+a+Client. Most important thing here is the XML file.

In our example we will add a new product to the Prestashop API. Here is ours XML file with data.

product.xml

Save it and execute command below.

Pretashop has RESTful API so it depends on the http methods that you would be able to add / edit or remove products.

Share