Hi!
I'm starting to use the PS API but I cannot create a resource, I'm able to list a resource but I don't know why the creation doesn't work
I'm trying with a simple table (countries) using postman and putting in the body (raw & xml) this one:
<?xml version="1.0" encoding="UTF-8"?> <prestashop xmlns:xlink="http://www.w3.org/1999/xlink"> <country> <id>9999</id> <id_zone>1999999</id_zone> <id_currency>0</id_currency> <call_prefix>999999</call_prefix> <iso_code>ZZ</iso_code> <active>0</active> <contains_states>0</contains_states> <need_identification_number>0</need_identification_number> <need_zip_code>1</need_zip_code> <zip_code_format>NNNNN</zip_code_format> <display_tax_label>1</display_tax_label> <name><language id="1"></language></name> </country> </prestashop>
using a POST call
https://ncssrl.com/pshop/api/countries/?ws_key=mykey
but I get in response the list of all the countries, without my new one.
tried also with a simple new currency with this xml in body
<prestashop> <currencies> <currency> <id>2</id> <names> <language id="1" xlink:href="https://www.ncssrl.com/pshop/api/languages/1">US Dollar</language> </names> <name notFilterable="true">US Dollar</name> <symbol> <language id="1" xlink:href="https://www.ncssrl.com/pshop/api/languages/1">$</language> </symbol> <iso_code>EUR</iso_code> <numeric_iso_code>840</numeric_iso_code> <precision>2</precision> <conversion_rate>1.000000</conversion_rate> <deleted>0</deleted> <active>1</active> <unofficial>0</unofficial> <modified>0</modified> <pattern> <language id="1" xlink:href="https://www.ncssrl.com/pshop/api/languages/1"></language> </pattern> </currency> </currencies> </prestashop>
postman response says 200 OK but only shows me the old currency and not the new one.
why?