Preuzimanje otpremnice

Webservice URL : http://sws.spartoo.com.hr/mp/xml_export_bl.php

This webservice can be used to retrieve the delivery slip that needs to be put in your Spartoo order parcel.

Lista parametara

The parameters of this webservice are required to be in POST

Setting Description
partner Must contain your unique identifier code:
xml XML feed containing the list of information on the items for the delivery note


XML parameter format


The text fields must be protected by CDATA tags if they contain special characters that would make the XML invalid.

XML format

<root>
	<order_id>string</order_id>
	<products>
		<product>
			<reference_partenaire>string</reference_partenaire>
			<product_quantity>int</product_quantity>
		</product>
	</products>
</root>

Entry XML field description

Tag Description Compulsory
order_id Order ID Yes
partner_reference Merchant product name
The product ID can contain alphanumeric characters as well as characters - (dash) _ (underscore) et . (period).
Yes
product_quantity Product quantity in the parcel Yes


xml example parameter

<root>
	<order_id>3FF75E96C3434E92</order_id>
	<products>
		<product>
			<reference_partenaire>39870-42</reference_partenaire>
			<product_quantity>1</product_quantity>
		</product>
	</products>
</root>

XML format returned

<root>
	<bl>
		<order_id>string</order_id>
		<pdf>string</pdf>
	</bl>
	<errors>int</errors>
</root>

List of webservice error codes


Kod Opis
1 Nema pogreške u parametrima
-1 The parameter partenaire has not been set up or it is empty
-2 The parameter partenaire does not exist
-5 The rID/oID parameter or the status parameter is missing
-6 The order or return were not found, verify the OID / RID parameter or the partner parameter.
-11 The parameter xml has not been set up or it is empty
-12 The parameter reference_partenaire has not been set up or it is empty
-15 XML syntax error, verify your XML file
-428 Vaš račun je deaktiviran. Više ne možete koristiti web servise.
-429 Prekoračili ste broj mogućih korištenja navedenog webservisa u posljednjih sat vremena.

XML response field description

Tag Description
order_id Order identification number
pdf Packing slip in encoded PDF format
errors Error code


Examples of XML return

Primjer neispravnog odgovora na poziv web servisa
<root>
	<errors>int</errors>
</root>
Primjer ispravnog odgovora na poziv web servisa
<root>
	<errors>1</errors>
	<bl>
		<order_id>25CF31A736506CE8</order_id>
		<pdf>string PDF encode</pdf>
	</bl>
</root>