List Delivery Options #
Service Url: POST /baskets/{ref}/orders/deliveryOptions
Request Body
CustomerOrderAddress
— Todo –
Response body
ListDeliveryOptionsResponse
deliveryOptions – List<DeliveryOption> – the list of available delivery options for a request.
Entities
DeliveryOption
deliverySlot – DeliverySlot – todo
deliveryDescription – String – A description for this option in the specified locale
deliveryReference – String – A string, can be used as a reference for this delivery option
deliveryPromiseText – String – A text, used to display the delivery promise for this option
products – List<ProductQuantity> – The list of products and the quantity available with this delivery option
Remarks
- Lists the available delivery options for a delivery address. Each delivery options states what products (including quantity) the delivery options can fulfill.
Example Request
Expand source
{
“street1”: “Enactor House”,
“street2”: “1 Bluecoats Avenue”,
“town”: “Hertford”,
“county”: “Hertfordshire”,
“postCode”: “SG14 1PB”
}
Example Response
Expand source
{
“deliveryOptions”: [
{
“@type”: “addressDeliveryOption”,
“address”: {
“countryCodeId”: {},
“typeId”: {},
“postCode”: “sg124 9tf”,
“street1”: “Great Amwell”,
“isTemplate”: false
},
“deliverySlot”: {
“currencyId”: {},
“fulfilmentOptions”: [
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0003”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-8”
}
}
}
]
},
“products”: [
{
“productKey”: {
“id”: “VV639JS-8”
},
“quantity”: 1
}
]
},
{
“@type”: “locationReservationDeliveryOption”,
“locationId”: {
“id”: “0001”
},
“deliveryDescription”: “Enactor Store”,
“deliverySlot”: {
“currencyId”: {},
“fulfilmentOptions”: [
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0001”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-8”
}
}
}
]
},
“products”: [
{
“productKey”: {
“id”: “VV639JS-8”
},
“quantity”: 1
}
]
},
{
“@type”: “locationCollectionDeliveryOption”,
“locationId”: {
“id”: “0001”
},
“deliveryDescription”: “Enactor Store”,
“deliverySlot”: {
“currencyId”: {},
“fulfilmentOptions”: [
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0100”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-8”
}
}
}
]
},
“products”: [
{
“productKey”: {
“id”: “VV639JS-8”
},
“quantity”: 1
}
]
},
{
“@type”: “locationReservationDeliveryOption”,
“locationId”: {
“id”: “0003”
},
“deliveryDescription”: “Enactor (Demo Room)”,
“deliverySlot”: {
“currencyId”: {},
“fulfilmentOptions”: [
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0003”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-8”
}
}
}
]
},
“products”: [
{
“productKey”: {
“id”: “VV639JS-8”
},
“quantity”: 1
}
]
},
{
“@type”: “locationCollectionDeliveryOption”,
“locationId”: {
“id”: “0003”
},
“deliveryDescription”: “Enactor (Demo Room)”,
“deliverySlot”: {
“currencyId”: {},
“fulfilmentOptions”: [
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0001”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-8”
}
}
}
]
},
“products”: [
{
“productKey”: {
“id”: “VV639JS-8”
},
“quantity”: 1
}
]
}
]
}
Update Delivery Details #
Service Url: POST /baskets/{ref}/orders/deliveryDetails
Tokens
basketReference – String – reference of the basket
Request Body
ISetDeliveryDetailsRequest
- address – ICustomerOrderAddress – the address of the order
- deliveryOption – IDeliveryOption – the delivery option for the order.
- deliveryName – IName – the name of delivery address.
Response body
- 200 OK
Remarks
This services update the baskets order details with a delivery name, address, and option. Any existing delivery options will be removed and replaced.
Example Request
Example Set Delivery Details Request Expand source
{
“address”: {
“houseNumber”: “44 Furlong Way, Great Amwellbb”,
“street1”: “Great Amwell”,
“city”: “Ware”,
“postCode”: “sg124 9tf”,
“phoneNumber”: “7565678900”
},
“deliveryOption”: {
“@type”: “addressDeliveryOption”,
“address”: {
“countryCodeId”: {},
“typeId”: {},
“postCode”: “sg124 9tf”,
“street1”: “Great Amwell”,
“isTemplate”: false
},
“deliverySlot”: {
“currencyId”: {},
“deliveryCharge”: 500,
“fulfilmentOptions”: [
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0100”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-12”
}
}
},
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0100”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-8”
}
}
}
],
“deliveryTypeId”: {
“deliveryTypeId”: “Express”
}
},
“products”: [
{
“productKey”: {
“id”: “VV639JS-12”
},
“quantity”: 1
},
{
“productKey”: {
“id”: “VV639JS-8”
},
“quantity”: 1
}
],
“index”: 0
},
“deliveryName”: {
“forename”: “James”,
“surname”: “hanson”
}
}
Update Collection Details #
Service Url: POST /baskets/{ref}/orders/collectionDetails
Request Body
UpdateCollectionDetailsRequest
locationId – String – the id of the location
deliveryOption – IDeliveryOption – the (collection) delivery option to update the order with
deliveryName – IName – the name of the delivery option
Remarks
Updates the collection details for a basket.
Example Request
Expand source
POST http://localhost:8080/WebRestApi/rest/baskets/PRIMARY/orders/collectionDetails
{
“locationId”: “0001”,
“deliveryOption”: {
“@type”: “locationCollectionDeliveryOption”,
“locationId”: {
“id”: “0001”
},
“deliveryDescription”: “Enactor Store”,
“deliverySlot”: {
“currencyId”: {},
“fulfilmentOptions”: [
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0100”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-12”
}
}
},
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0100”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-8”
}
}
}
]
},
“products”: [
{
“productKey”: {
“id”: “VV639JS-12”
},
“quantity”: 1
},
{
“productKey”: {
“id”: “VV639JS-8”
},
“quantity”: 1
}
],
“index”: 1
},
“deliveryName”: {
“forename”: “James”,
“surname”: “hanson”
}
}
Example Response
200 OK
List Collection Options
Service Url: GET /baskets/{ref}/orders/collectionOptions/{locationId}
Remarks
Returns a list of collection delivery options for a given location Id.
Example Request
Expand source
http://localhost:8080/WebRestApi/rest/baskets/PRIMARY/orders/collectionOptions/0001
Example Response
Expand source
{
“deliveryOptions”: [
{
“@type”: “addressDeliveryOption”,
“address”: {
“countryCodeId”: {},
“typeId”: {},
“isTemplate”: false
},
“deliverySlot”: {
“currencyId”: {},
“deliveryCharge”: 500,
“fulfilmentOptions”: [
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0100”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-12”
}
}
},
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0100”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-8”
}
}
}
],
“deliveryTypeId”: {
“deliveryTypeId”: “Express”
}
},
“products”: [
{
“productKey”: {
“id”: “VV639JS-12”
},
“quantity”: 1
},
{
“productKey”: {
“id”: “VV639JS-8”
},
“quantity”: 1
}
]
},
{
“@type”: “locationCollectionDeliveryOption”,
“locationId”: {
“id”: “0001”
},
“deliveryDescription”: “Enactor Store”,
“deliverySlot”: {
“currencyId”: {},
“fulfilmentOptions”: [
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0100”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-12”
}
}
},
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0100”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-8”
}
}
}
]
},
“products”: [
{
“productKey”: {
“id”: “VV639JS-12”
},
“quantity”: 1
},
{
“productKey”: {
“id”: “VV639JS-8”
},
“quantity”: 1
}
]
},
{
“@type”: “locationCollectionDeliveryOption”,
“locationId”: {
“id”: “0003”
},
“deliveryDescription”: “Enactor (Demo Room)”,
“deliverySlot”: {
“currencyId”: {},
“fulfilmentOptions”: [
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0100”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-12”
}
}
},
{
“locationStockFulfilment”: {
“locationId”: {
“id”: “0100”
},
“quantity”: 1,
“productId”: {
“id”: “VV639JS-8”
}
}
}
]
},
“products”: [
{
“productKey”: {
“id”: “VV639JS-12”
},
“quantity”: 1
},
{
“productKey”: {
“id”: “VV639JS-8”
},
“quantity”: 1
}
]
}
]
}
List Collection Locations #
Service Url: POST /baskets/{ref}/orders/collectionLocations
Response body
IListCollectionLocationsResponse
collectionLocationSummaries – List<ICollectionLocationSummary> – the list of collection location summaries.
Entities
ICollectionLocationSummary
locationId – String – the id of the location for the collection location
description – String- the description of the collection location
Remarks
Returns a list of summaries of all the possible collection locations available.
Example Request
Expand source
http://localhost:8080/WebRestApi/rest/baskets/PRIMARY/orders/collectionLocations
Example Response
Expand source
{
“collectionLocationSummaries”: [
{
“locationId”: “0001”,
“description”: “Enactor Store”
},
{
“locationId”: “0003”,
“description”: “Enactor (Demo Room)”
}
]
}