Marketplace Transaction API

Transaction request

This function enables the request of Marketplace transaction details.

Url: https://app.webshippy.com/wspyapi/getMarketplaceTransactions/{contentType}

The filtering terms given in the table are in an AND relationship with one another, only the filtering terms to be filtered for need to be specified.

In case of XML:

Request (example):

<?xml version="1.0" encoding="UTF-8"?>
<request>
	<apiKey>your-api-key</apiKey>
	<filters>
		<invoiceStatus>invoiced</invoiceStatus>
		<dateFrom>2021-04-21</dateFrom>
		<dateTo>2022-01-12</dateTo>
		<transactionRole>supplier</transactionRole>
	</filters>
</request>

Response (example):

<?xml version="1.0" encoding="UTF-8"?>
<response>
	<status>success</status>
	<result>
		<transactionId>DSPY1000134</transactionId>
		<date>2021-02-14 13:09:11</date>
		<paymentStatus>paid</paymentStatus>
		<transferredAt>2021-06-12 14:12:00</transferredAt>
		<parties>
			<supplier>
				<name>Webshippy</name>
			</supplier>
			<retailer>
				<name>Koala Adventures Teszt Bt.</name>
				<address>7621 Hungary Pécs Asd street</address>
				<email>retail@now.com</email>
				<billingTaxNumber>000000000000-99</billingTaxNumber>
			</retailer>
		</parties>
		<payment>
			<paymentId>500864504</paymentId>
		</payment>
		<products>
			<name>Premium Quality Shirt</name>
			<sku>ws2_dspy_rules_11</sku>
			<barcode>ws2_dspy_rules_11-b</barcode>
			<quantity>2</quantity>
			<transactionAmountNet>3800</transactionAmountNet>
			<vat>0</vat>
			<vatSum>0</vatSum>
			<transactionAmountGross>3800</transactionAmountGross>
			<currency>HUF</currency>
		</products>
		<invoice>
			<url>http://webshippy.lh/dropshippy/getTransactionInvoice/1000134</url>
			<status>invoiced</status>
			<serialNumber>Invoice-12345-1-54365</serialNumber>
		</invoice>
	</result>
</response>

In case of a failed request (example):

<?xml version="1.0" encoding="UTF-8"?>
<response>
	<status>error</status>
	<notagname>Invalid API key</notagname>
</response>

In case of JSON:

Request (example):

{
  "apiKey": "your-api-key",
  "filters": {
    "invoiceStatus": "invoiced",
    "dateFrom": "2021-04-21",
    "dateTo": "2022-01-12",
    "transactionRole": "supplier"
  }
}

Response (example):

{
  "status": "success",
  "result": [
    {
      "transactionId": "DSPY1000134",
      "date": "2021-02-14 13:09:11",
      "paymentStatus": "paid",
      "transferredAt": "2021-06-12 14:12:00",
      "parties": {
        "supplier": {
          "name": "Webshippy"
        },
        "retailer": {
          "name": "Koala Adventures Teszt Bt.",
          "address": "7621 Hungary Pécs Asd street",
          "email": "retail@now.com",
          "billingTaxNumber": "000000000000-99"
        }
      },
      "payment": {
        "paymentId": 500864504
      },
      "products": [
        {
          "name": "Premium Quality Shirt",
          "sku": "ws2_dspy_rules_11",
          "barcode": "ws2_dspy_rules_11-b",
          "quantity": 2,
          "transactionAmountNet": 3800,
          "vat": 0,
          "vatSum": 0,
          "transactionAmountGross": 3800,
          "currency": "HUF"
        }
      ],
      "invoice": {
        "url": "http://webshippy.lh/dropshippy/getTransactionInvoice/1000134",
        "status": "invoiced",
        "serialNumber": "Invoice-12345-1-54365"
      }
    }
  ]
}

In case of a failed request (example):

{
  "status": "error",
  "message": [
    "Invalid API key"
  ]
}

Upload of invoice issued

This function enables the Marketplace suppliers to upload the invoice related to a specific transaction. A single api call allows invoice upload for multiple transactions simultaneously, but only one invoice per transaction is supported. The invoice upload is in base64 format. If there's no invoice associated with a specific transaction ID, the API will create one.

Url: https://app.webshippy.com/wspyapi/uploadMarketplaceTransactionInvoice/{contentType}

In case of XML:

Request (example):

<?xml version="1.0" encoding="UTF-8"?>
<request>
	<apiKey>your-api-key</apiKey>
	<invoice>
		<transactionId>DSPY1000134</transactionId>
		<invoiceSerialNumber>Invoice-12345-1-54365</invoiceSerialNumber>
		<fileInput>iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNkYPhfDwAChwGA60e6kgAAAABJRU5ErkJggg==</fileInput>
	</invoice>
</request>

Response (example):

<?xml version="1.0" encoding="UTF-8"?>
<response>
	<status>success</status>
	<result>
		<transactionId>DSPY1000134</transactionId>
		<invoiceSerialNumber>Invoice-12345-1-54365</invoiceSerialNumber>
		<fileInput>iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNkYPhfDwAChwGA60e6kgAAAABJRU5ErkJggg==</fileInput>
	</result>
</response>

In case of a failed request (example):

<?xml version="1.0" encoding="UTF-8"?>
<response>
	<status>error</status>
	<result>
		<transactionId>DSPY1000134</transactionId>
		<invoiceSerialNumber>Invoice-12345-1-54365</invoiceSerialNumber>
		<fileInput>iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNkYPhfDwAChwGA60e6kgAAAABJRU5ErkJggg==</fileInput>
	</result>
	<message>Invoice [invoiceSerialNumber] upload failed, due to: [error]</message>
</response>

In case of JSON:

Request (example):

{
  "apiKey": "your-api-key",
  "invoice": [
    {
      "transactionId": "DSPY1000134",
      "invoiceSerialNumber": "Invoice-12345-1-54365",
      "fileInput": "iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNkYPhfDwAChwGA60e6kgAAAABJRU5ErkJggg=="
    }
  ]
}

Response (example):

{
  "status": "success",
  "result": [
    {
      "transactionId": "DSPY1000134",
      "invoiceSerialNumber": "Invoice-12345-1-54365",
      "fileInput": "iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNkYPhfDwAChwGA60e6kgAAAABJRU5ErkJggg=="
    }
  ]
}

In case of a failed request (example):

{
  "status": "error",
  "result": [
    {
      "transactionId": "DSPY1000134",
      "invoiceSerialNumber": "Invoice-12345-1-54365",
      "fileInput": "iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAADUlEQVR42mNkYPhfDwAChwGA60e6kgAAAABJRU5ErkJggg=="
    }
  ],
  "message": [
    "Invoice [invoiceSerialNumber] upload failed, due to: [error]"
  ]
}

Additional response options in case of failed request:

  • "[field:example] Example field has to be integer"

  • "Invalid API key"

  • "Entity not found"

  • "Already existing entity"

Last updated