How to create and close a sale order with seat selection and payment method

The example below explains how to create an order with specifics physical seat (seat selection) and payment method using REST calls.

Reference data

You must have them under hand before to begin.

Username : PLAY_B2C
Password : P@ssw0rd
Contact : 2258
pointOfSalesId : 101053522324 paymentMethodId : Pending account 16370 - (can be obtained through a call to this method)

Postman collection

Please download and import the postman collection to be able to reproduce de example: Collection - Order with seat selection and payment method

Steps to follow

Authentication

Just execute to get the token for next steps.

Get seat availability

This method is called to get the availability of a specific performance ID, a specific seat category ID and a specific block/area (all these information can be obtained from the catalog). To create the order (next step), we will need the "physicalSeatId" which appears in the result of this call.

Create the order

Using the "physicalSeatId" from the previous step and setting the desired tariff (audience sub category), we will be able to create the order for a specific seat. For next steps, we will need the "orderId" and the "totalAmount" returned by this call.

Set the shipment mode

Using the "orderId" from the previous step and setting the desired shipment mode (information available through the getAvailableShipmentModes), we will be able to set the shipment mode to the specific order.

Close order

Using the "orderId" and the "totalAmount" from the "Create order" step and setting the desired payment mode, we will be able to close the order.

Check the order status

Using the "orderId" from the "Create order" step, we will be able to check the status of the order (the order should be in "CLOSED" status).