API Test Facility

In order to verify that Plaza API partner systems can interact with the Plaza API in a sandboxed environment, a test facility is provided, offering the same API as the production environment, but with fixed responses. This implies that no personalized data is used in the test facility, and that none of the data sent to the system is stored in a database. Calls to this system will not impact production data, and are therefore safe for partners to use while developing their systems.

All error conditions that apply to the production system apply to the test facility too: posts with malformed XML, missing and/or wrong headers, requests to non-existing resources, etc, will all result in the same errors as on the production system. See section Error codes and messages for more details.

The sections below detail the responses that the test facility will give to API requests.

The technical specifications of the interfaces are the same as those of the production system, and can be found at:

Note: The test facility support both Order API v1 and v2, even though only v1 is shown in the examples below.

7.1. Open orders

For open orders, send a HTTP GET request to the following url: https://test-plazaapi.bol.com/services/rest/orders/v1/open.

The test facility will return the following XML, containing one order with all allowed fields, and with only the required fields:

<?xml version="1.0" ?>
<bns:OpenOrders xmlns:bns="http://plazaapi.bol.com/services/xsd/plazaapiservice-1.0.xsd">
 <bns:OpenOrder>
 <bns:OrderId>123</bns:OrderId>
 <bns:DateTimeCustomer>2011-12-05T10:12:29</bns:DateTimeCustomer>
 <bns:DateTimeDropShipper>2011-12-05T10:12:29</bns:DateTimeDropShipper>
 <bns:Paid>true</bns:Paid>
 <bns:Buyer>
 <bns:ShipmentDetails>
 <bns:SalutationCode>01</bns:SalutationCode>
 <bns:FirstName>Jan</bns:FirstName>
 <bns:Surname>Janssen</bns:Surname>
 <bns:Streetname>Shipmentstraat</bns:Streetname>
 <bns:Housenumber>42</bns:Housenumber>
 <bns:HousenumberExtended>bis</bns:HousenumberExtended>
 <bns:AddressSupplement>3 hoog achter</bns:AddressSupplement>
 <bns:ZipCode>1000 AA</bns:ZipCode>
 <bns:City>Amsterdam</bns:City>
 <bns:CountryCode>NL</bns:CountryCode>
 <bns:Email>nospam4me@myaccount.com</bns:Email>
 <bns:Telephone>12345</bns:Telephone>
 <bns:Company>The Company</bns:Company>
 </bns:ShipmentDetails>
 <bns:BillingDetails>
 <bns:SalutationCode>02</bns:SalutationCode>
 <bns:FirstName>Jans</bns:FirstName>
 <bns:Surname>Janssen</bns:Surname> <bns:Streetname>Billingstraat</bns:Streetname>
 <bns:Housenumber>1</bns:Housenumber>
 <bns:HousenumberExtended>a</bns:HousenumberExtended>
 <bns:AddressSupplement>Onder de brievanbus huisnummer 1</bns:AddressSupplement>
 <bns:ZipCode>5000 ZZ</bns:ZipCode>
 <bns:City>Amsterdam</bns:City>
 <bns:CountryCode>NL</bns:CountryCode>
 <bns:Email>dontemail@me.net</bns:Email>
 <bns:Telephone>67890</bns:Telephone>
 <bns:Company>Bol.com</bns:Company>
 </bns:BillingDetails>
 </bns:Buyer>
 <bns:OpenOrderItems>
 <bns:OpenOrderItem>
 <bns:OrderItemId>123</bns:OrderItemId>
 <bns:EAN>9789062387410</bns:EAN>
 <bns:ReferenceCode>PARTNERREF001</bns:ReferenceCode>
 <bns:Title>Regelmaat en Inbakeren</bns:Title>
 <bns:Quantity>1</bns:Quantity>
 <bns:Price>123.45</bns:Price>
 <bns:DeliveryPeriod>Binnen 24 uur</bns:DeliveryPeriod>
 <bns:TransactionFee>19.12</bns:TransactionFee>
 </bns:OpenOrderItem>
 </bns:OpenOrderItems>
 </bns:OpenOrder>
 <bns:OpenOrder>
 <bns:OrderId>321</bns:OrderId>
 <bns:DateTimeCustomer>2011-12-05T10:12:29</bns:DateTimeCustomer>
 <bns:DateTimeDropShipper>2011-12-05T10:12:29</bns:DateTimeDropShipper>
 <bns:Paid>false</bns:Paid>
 <bns:Buyer>
 <bns:ShipmentDetails>
 <bns:Salutation>Dhr. Janssen</bns:Salutation>
 <bns:Streetname>Shipmentstraat</bns:Streetname>
 <bns:Housenumber>42</bns:Housenumber>
 <bns:ZipCode>1000 AA</bns:ZipCode>
 <bns:City>Amsterdam</bns:City>
 <bns:CountryCode>NL</bns:CountryCode>
 <bns:Email>nospam4me@myaccount.com</bns:Email>
 </bns:ShipmentDetails>
 <bns:BillingDetails>
 <bns:Salutation>Mevr. Pietersen</bns:Salutation>
 <bns:Streetname>Billingstraat</bns:Streetname>
 <bns:Housenumber>1</bns:Housenumber>
 <bns:ZipCode>5000 ZZ</bns:ZipCode>
 <bns:City>Amsterdam</bns:City>
 <bns:CountryCode>NL</bns:CountryCode>
 <bns:Email>dontemail@me.net</bns:Email>
 </bns:BillingDetails>
 </bns:Buyer>
 <bns:OpenOrderItems>
 <bns:OpenOrderItem>
 <bns:OrderItemId>321</bns:OrderItemId>
 <bns:EAN>9789062387410</bns:EAN>
 <bns:Title>Regelmaat en Inbakeren</bns:Title>
 <bns:Quantity>1</bns:Quantity>
 <bns:Price>123.45</bns:Price>
 <bns:DeliveryPeriod>Binnen 24 uur</bns:DeliveryPeriod>
 <bns:TransactionFee>19.12</bns:TransactionFee>
 </bns:OpenOrderItem>
 </bns:OpenOrderItems>
 </bns:OpenOrder>
</bns:OpenOrders>

In this result, the DateTimeCustomer and DateTimeDropShipper fields contain the date and time of generating the XML. All other fields are static. The first order item contains all optional fields, the second doesn’t.

7.2 Shipments and cancellations

This interface provides the following functionality:

  1. request processing for order shipments and/or order cancellations
  2. retrieve process status

Request processing for order shipments and/or cancellations

For shipments and cancellations, send a HTTP POST request to the following url: https://test- plazaapi.bol.com/services/rest/orders/v1/process.

7.3 Process status

For retrieving the status of a process call, send a HTTP GET request to the following url: https://test- plazaapi.bol.com/services/rest/orders/v1/process/{ProcessOrderId}. Where {ProcessOrderId} is the process id returned by the ‘process’ call.

The test facility recognizes the following process order ids:

  • 123: Mimics a process request that was handled successfully.
  • 456: Mimics a process request that resulted in errors.
  • 789: Mimics a process request that has not been finalized yet.

All other process ids will result in a HTTP 404 (Not Found) result.

The DateTime fields contain the date and time of generating the XML. All other fields are static.

7.4 Payments

For retrieving the payment of a given month, send a HTTP GET request to the following url: https://test- plazaapi.bol.com/services/rest/payments/v1/payments/{YearMonth}, where {YearMonth} is the year and month of which the payments are retrieved.

The test facility recognizes the following year/month combinations:

  • A year/month in the past, or the current year/month: This will return a non-empty result.
  • A year/month in the future: This will return an empty result.

The DateTimePayment and DateTimeShipment fields contain the date and time of generating the XML. All other fields are static.

7.5. Empty result

The test facility will return the following XML:

<?xml version="1.0" ?>
<bns:Payments xmlns:bns="http://plazaapi.bol.com/services/xsd/plazaapiservice-1.0.xsd">
</bns:Payments>

Non-empty result
The test facility will return the following XML:

<?xml version="1.0" ?>
<bns:Payments xmlns:bns="http://plazaapi.bol.com/services/xsd/plazaapiservice-1.0.xsd">
 <bns:Payment>
 <bns:CreditInvoiceNumber>123</bns:CreditInvoiceNumber>
 <bns:DateTimePayment>2011-11-22T13:55:19</bns:DateTimePayment>
 <bns:PaymentAmount>425.77</bns:PaymentAmount>
 <bns:PaymentShipments>
 <bns:PaymentShipment>
 <bns:PackageSlipNumber>456</bns:PackageSlipNumber>
 <bns:OrderId>123001</bns:OrderId>
 <bns:PaymentShipmentAmount>425.77</bns:PaymentShipmentAmount>
 <bns:PaymentStatus>FINAL</bns:PaymentStatus>
 <bns:DateTimeShipment>2011-11-22T13:55:19</bns:DateTimeShipment>
 <bns:PaymentShipmentItems>
 <bns:PaymentShipmentItem>
 <bns:OrderItemId>123001001</bns:OrderItemId>
 <bns:EAN>9789062387410</bns:EAN>
 <bns:ReferenceCode>PARTNERREF001</bns:ReferenceCode>
 <bns:Quantity>1</bns:Quantity>
 <bns:Price>425.77</bns:Price>
 <bns:ShippingContribution>1.95</bns:ShippingContribution>
 <bns:TransactionFee>10.00</bns:TransactionFee>
 <bns:TotalAmount>425.77</bns:TotalAmount>
 <bns:ShipmentStatus>NORMAL</bns:ShipmentStatus>
 </bns:PaymentShipmentItem>
 </bns:PaymentShipmentItems>
 </bns:PaymentShipment>
 </bns:PaymentShipments>
 </bns:Payment>
 <bns:Payment>
 <bns:CreditInvoiceNumber>456</bns:CreditInvoiceNumber>
 <bns:DateTimePayment>2011-11-22T13:55:19</bns:DateTimePayment>
 <bns:PaymentAmount>699.99</bns:PaymentAmount>
 <bns:PaymentShipments>
 <bns:PaymentShipment>
 <bns:PackageSlipNumber>456</bns:PackageSlipNumber>
 <bns:OrderId>456001</bns:OrderId>
 <bns:PaymentShipmentAmount>699.99</bns:PaymentShipmentAmount>
 <bns:PaymentStatus>CONTINUATION</bns:PaymentStatus>
 <bns:DateTimeShipment>2011-11-22T13:55:19</bns:DateTimeShipment>
 <bns:PaymentShipmentItems>
 <bns:PaymentShipmentItem>
 <bns:OrderItemId>456001001</bns:OrderItemId>
 <bns:EAN>4016572008364</bns:EAN>
 <bns:ReferenceCode>PARTNERREF002</bns:ReferenceCode>
 <bns:Quantity>1</bns:Quantity>
 <bns:Price>699.99</bns:Price>
 <bns:ShippingContribution>1.95</bns:ShippingContribution>
 <bns:TransactionFee>10.00</bns:TransactionFee>
 <bns:TotalAmount>699.99</bns:TotalAmount>
 <bns:ShipmentStatus>NORMAL</bns:ShipmentStatus>
 </bns:PaymentShipmentItem>
 </bns:PaymentShipmentItems>
 </bns:PaymentShipment>
 </bns:PaymentShipments>
 </bns:Payment>
</bns:Payments>

In this result, the DateTimePayment and DateTimeShipment fields contain the date and time of generating the XML. All other fields are static.

Nieuws via e-mail

Mochten we nieuws hebben, dan stellen we je via deze weg op de hoogte.
Helemaal onderin deze pagina vind je ook ons Twitter en Google+ kanaal.