Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Url naar yaml files toegevoegd

Table of Contents

CB Media Interface Description

Revisions

...

DateDescription
1.112-11-2020 Update yaml file MediaOrderB2C v1.2.0.yaml1.108-06-2020

 

Added extra information authorisation: “Basic ”||"Base64 encoding of username and password joined by a single colon : "

 

Media Order B2C: Yaml file version 1.3.0

Changelog version 1.2.0 to version 1.3.0:

  • Add Article with ArticleId as product identification for dedicated stock
  • Use either EAN or Article in placeOrder (EAN is now optional), if both are supplied the EAN is used and Article is ignored
  • Report either EAN or Article in getOrderStatus based on provided input in placeOrder

MediaShipment: Yaml file version 1.0.0 version 1.1.0

Changelog version 1.0.0 to version 1.1.0:

  • Add ArticleId as product identification for dedicated stock
  • Report either EAN or ArticleId in getShippingUnit based on provided input in placeOrder

 

Authentication notify services, CB supports:

  • Basic - username/password
  • Token 

 

Test and order simulation added

 

Add Tag matrix for Green and Standard option

 

Update yaml file MediaOrderNotify v.1.0.2.yaml

 

Update generic error messages

 

Align with updated order notifications

 

Update yaml file MediaOrderB2C v1.2.0.yaml

 

Update MediaOrderB2C version

Correct resource for notifyOrder and notityShipment
1.0

-04-

 

Update yaml versions
0.6

-03-2020 

 

Add volume limits and error messages; Correct typo in process flow diagrams

 

Add flows and sequence diagrams
0.513-01-2020 Add flows and sequence diagrams0.311-11-2019 Add operations0.1

30-08-2019 

Initial document

Introduction

This document contains a description of the standard interfaces for implementation of data exchange with CB via webservices.

The entire set for the standard data exchange with CB consists of the following documents and files:The mapping from file based to webservice based messages

 

Add operations

 

Initial document

Introduction

This document contains a description of the standard interfaces for implementation of data exchange with CB via webservices.

The entire set for the standard data exchange with CB consists of the following documents and files:
The mapping from file based to webservice based messages
Tag matrix for Green and Standard option

CB has two options for submitting e-commerce orders:

  • Green option no document attached to shipment,
  • Standard option packing slip or invoice included with shipment
Expand
titleClick here for tag matrix

Include Page
Tags Green and Standard option
Tags Green and Standard option


yaml definition filesAn OpenAPI Specification file (yaml) for each resource

MediaOrderB2C v1.2.0.yamlhttps://services.cb.nl/rest/api/v1/mediaorderb2c/swagger.yaml  Contains PUT (cancel), GET (status) and POST (place order)

MediaOrderNotify v1.0.02.yamlMediaShipment v1.0.0

Overview webservices

This chapter gives an overview of the available interaction patterns for data exchange with CB. The figure below gives an high level overview of the CB system landscape and the available webservice operations.

...

Webservices are available 24 hours a day, 7 days a week, however order handling is restricted to warehouse working hours. Our regular maintenance window is on Saturday from 08:00 hours until 14:00 hours. The webservice operations are available during this time, but received requests are stored only (i.e. not validated or processed)received requests are stored only (i.e. not validated nor processed at that moment) when our ERP systems are not available. Processing will resume as soon as our ERP systems are available again..

File versus Webservice

Communication about orders is based on the receiving channel, i.e. file base communication is used for orders received via file based interfaces and webservice communication is used for orders received via the webservice.

...

Webservice name: MediaOrderNotify
Definition: MediaOrderNotify.yaml
Resource

Notifications

Operations provided by you:
notifyOrderCB calls your webservice to inform you about status updates of an order

Notifications

Operations provided by you:
notifyOrderCB calls your webservice to inform you about status updates of an order
Authentication modeCB supports:
  • Basic - username:password   “Basic ”||"Base64 encoding of username and password joined by a single colon : "
  • Token 

MediaShipment

Webservice name: MediaShipment
Definition: MediaShipment.yaml
Resource: 

ShippingUnits

Operations provided by CB:
getShippingUnit

Retrieve the shipment information for a shipping unit

...

about a shipment for your order
Webservice name: MediaShipmentNotify
Definition: MediaShipmentNotify.yaml
Resource: 

Notifications

Operations provided by you:
notifyShipment

CB calls your webservice to inform you

about a shipment for your order

Authentication modeCB supports:
  • Basic - username:password  “Basic ”||"Base64 encoding of username and password joined by a single colon : "
  • Token 

Process flows

This chapter contains the identified flows when using webservices to order physical books at CB. The most common and regular scenario is describes in the happy flow. In addition 7 frequent scenarios are described in alternative flows.

...

The customer orders one or more products, stock is available and the order is shipped in one shipment.

Diagram Happy FlowImage RemovedImage Added

Flow description:

  • The customer puts one or more products in the shopping basket
  • The shop forwards the order to CB with the operation placeOrder
  • CB verifies and accepts the order, the shop is notified with the operation notifyOrder and status event In Progress
  • CB assigns stock to the order
  • CB starts order processing prepares for logistic processing of the order. Cancellation of the order is not possible anymore, the shop is notified with the operation notifyOrder and status event ProductionReady
  • The shop can retrieve the order process status to see which orderlines are ready for production and cannot be cancelled anymore
  • CB executes pick and pack for the order and creates a shipment. The shop is notified with the operation notifyShipment and status event Processed
  • The shop retrieves can retrieve the shipment details (including tracking number and a list of products) per shipping unit and can inform the customerCB informs the shop that the order is completed with the operation notifyOrder and status event Processed.

Alternative Flow 1 – multiple shipments

The customer orders multiple products and stock is available for all products. At pick and pack multiple shipping units are created. The order is shipped in multiple shipments.

Diagram Alternative Flow 1 - multiple shipmentsImage RemovedImage Added

Flow description:

  • The customer puts multiple products in the shopping basket
  • The shop forwards the order to CB with the operation placeOrder
  • CB verifies and accepts the order, the shop is notified with the operation notifyOrder and status event In Progress
  • CB assigns stock to the order
  • CB starts order processingCB prepares for logistic processing of the order. The shop is notified with the operation notifyOrder and status event ProductionReady
  • The shop can retrieve the order process status to see which orderline(s) are ready for production and cannot be cancelled anymore

...

  • CB executes pick and pack for orderline 1 and creates a shipment. The shop is notified with the operation notifyShipment and status event Processed
  • The shop retrieves can retrieve the shipment details (including tracking number and a list of products) per shipping unit and can inform the customer

...

  • CB executes pick and pack for orderline 2 and creates a shipment. The shop is notified with the operation notifyShipment and status event Processed
  • The shop retrieves can retrieve the shipment details (including tracking number and a list of products) per shipping unit and can inform the customerCB informs the shop that the order is completed with the operation notifyOrder and status event Processed.

Alternative Flow 2 – multiple shipments due to partial backorder

The customer orders multiple products and stock is available for at least one product. Also at least one product is in backlogbackorder. The order is shipped in multiple shipments.

Image RemovedImage Added

Flow description:

  • The customer puts multiple products in the shopping basket
  • The shop forwards the order to CB with the operation placeOrder
  • CB verifies and accepts the order, the shop is notified with the operation notifyOrder and status event In Progress


  • CB assigns stock and start order processing for prepares for logistic processing of orderline 1. The shop is notified with the operation notifyOrder and status event ProductionReady
  • The shop can retrieve the order process status to see which orderline(s) are ready for production and cannot be cancelled anymore
  • CB executes pick and pack for orderline 1 and creates a shipment. The shop is notified with the operation notifyShipment and status event Processed
  • The shop retrieves can retrieve the shipment details (including tracking number and a list of products) per shipping unit and can inform the customer
  • CB received stock for orderline 2, assigns stock and start order processing for orderline 2. prepares for logistic processing of orderline The shop is notified with the operation notifyOrder and status event ProductionReady
  • The shop can retrieve the order process status to see which orderline(s) are ready for production and cannot be cancelled anymore
  • CB executes pick and pack for orderline 2 and creates a shipment. The shop is notified with the operation notifyShipment and status event Processed
  • The shop retrieves can retrieve the shipment details (including tracking number and a list of products) per shipping unit and can inform the customerCB informs the shop that the order is completed with the operation notifyOrder and status event Processedper shipping unit and can inform the customer.

Alternative Flow 3 – customer cancellation

The customer orders one or more products, but decides to cancel the order shortly after ordering.

Image RemovedImage Added

Flow description:

...

  • The customer decides to cancel the order at the shop
  • The shop forwards the cancel request per orderline to CB with the operation cancelOrderLine. The operation confirms a successful cancellationThe shop confirms acceptance of the cancellation to the customer
  • CB informs the shop that the complete order is cancelled with the operation notifyOrder and status event Cancelled
  • The shop confirms the cancellation to the customer.

 

Alternative Flow 4 – partial customer cancellation

The customer orders multiple products, but decides to cancel at least one of the orderlines but not all shortly after ordering.

Image RemovedImage Added

Flow description:

...

  • The customer decides to cancel orderline 1 in the shop
  • The shop forwards the cancel request for orderline 1 to CB with the operation cancelOrderLine.The operation confirms a successful cancellationoperation confirms acceptance of the cancellation
  • CB informs the shop that an orderline is cancelled with the operation notifyOrder and status event Cancelled
  • The shop confirms the cancellation to the customer


  • CB assigns stock and start order processing for prepares for logistic processing of orderline 2. The shop is notified with the operation notifyOrder and status event ProductionReady
  • CB executes pick and pack for orderline 2 and creates a shipment. The shop is notified with the operation notifyShipment and status event Processed
  • The shop retrieves can retrieve the shipment details (including tracking number and a list of products) per shipping unit and can inform the customerCB informs the shop that the order is completed with the operation notifyOrder and status event Processed.

Alternative Flow 5 – CB order reject

...

The customer orders multiple products and stock is available for at least one product. Also stock is not available for at least one product and backlog is not allowed.

Image RemovedImage Added

Flow description:

  • The customer puts multiple products in the shopping basket
  • The shop forwards the order to CB with the operation placeOrder. The operation confirms acceptance of the orderCB verifies the order and identifies that orderline 1 is not confirms acceptance of the order
  • CB verifies the order and identifies that orderline 1 is not available, the shop is notified with the operation notifyOrder and status event Cancelled
  • CB identifies that orderline 2 is available, the shop is notified with the operation notifyOrder and status event WarningInProgress
  • The shop retrieves the order process status to see which orderline(s) are not available
  • CB assigns stock and start order processing for prepares for logistic processing of orderline 2. The shop is notified with the operation notifyOrder and status event ProductionReady
  • CB executes pick and pack for orderline 2 and creates a shipment. The shop is notified with the operation notifyShipment and status event Processed
  • The shop retrieves can retrieve the shipment details (including tracking number and a list of products) per shipping unit and can inform the customerCB informs the shop that the order is completed with the operation notifyOrder and status event Processed.

Alternative Flow 7 – order during service window

The customer orders one or more products during the service window. Stock is available for all products.

Image RemovedImage Added

Flow description:

  • The customer puts one or more products in the shopping basket
  • The shop forwards the order to CB with the operation placeOrder. The operation confirms receipt of the order during the service windowCB confirms acceptance confirms receipt of the order after during the service window ended


  • CB verifies the order, the shop is notified with the operation notifyOrder and status event In Progress InProgress


  • CB assigns stock and start order processing for prepares for logistic processing of the order. The shop is notified with the operation notifyOrder and status event ProductionReady
  • The shop can retrieve the order process status with operation getOrderStatus to see which orderline(s) are ready for production and cannot be cancelled anymore
  • CB executes pick and pack for the order and creates a shipment. The shop is notified with the operation notifyShipment and status event Processed
  • The shop retrieves can retrieve the shipment details (including tracking number and a list of products) per shipping unit and can inform the customerCB informs the shop that the order is completed with the operation notifyOrder and status event Processed.

Alternative Flow 8 – cancel during service window

...

  • CB confirms a successful cancellation of the order after the service window ended to the . The shop is notified with the operation notifyOrder and status event Cancelled
  • The shop confirms the cancellation to the customer

...

  • WXX-00001         Reported field does not comply with yaml definition
  • WXX-00002         Reported field is not recognized
  • WMS-00001         invalid length for password
  • WMS-00002         invalid username/password combination
  • WMS-00005         No username and/or password provided by the callerdefinition
  • WXX-00002         Reported field is not recognized


  • WMS-00001         Invalid length for password
  • WMS-00002         Invalid username/password combination
  • WMS-00003         Invalid service
  • WMS-00004         Not authorized to use this service
  • WMS-00005         No username and/or password provided by the caller
  • WMS-00006         Unable to authenticate
  • WMS-00007         Unable to authorize


  • WMOWSP-00013        Empty body

Order

...

  • Processed ShippingUnit is ready for shipping

Include Page
General information CB webservice
General information CB webservice

Test environment


Include Page
Order simulation for test purpose
Order simulation for test purpose

Addendum

Migration strategy from batch file to webservice

Suggested migration strategy from batch file to webservice:

...