Returning Home Delivery Options for a specific time slot
You would first set up the relevant carrier 'service group(s)' in Delivery Manager. For example, you might create a group and include in it all those services that offer 'Before NOON' delivery (refer to Setup).
You could then use return type lgg to return the cheapest next available delivery option, and include only the NOON
carrier 'service group'. For example:
GET https://dmo.metapack.com/dmoptions/find?key=<API-Key>&wh_code=SL123&r_t=lgg&optionType=HOME&c_pc=WC1X 8HN&incgrp=NOON
The following is an example of the server response (assuming a 200 OK
status):
{ "header": { "requestId": "7600153d-b917-4242-ba2c-8151d6fe3112", "requestDate": "2020-04-07T16:36:54.654Z", "inputParameters": { "c_pc": [ "WC1X 8HN" ], "r_t": [ "lgg" ], "wh_code": [ "SL123" ], "key": [ "<API-Key>" ], "incgrp": [ "NOON" ] }, "responseDate": "2020-04-07T16:36:54.756Z" }, "results": [ { "groupCodes": [ "NOON" ], "photoUrls": [], "telephoneNumber": null, "distance": { "unit": "m", "value": 0 }, "description": null, "carrierServiceCode": "PLPRE1000", "long": null, "optionType": "HOME", "countryCode": null, "storeName": "", "shippingCharge": 0, "lat": null, "delivery": { "from": "2020-04-08T07:00:00.000Z", "to": "2020-04-08T09:30:59.999Z" }, "address": "", "carrierServiceName": "BEFORE 10:30", "postcode": "", "fullName": "DPD BEFORE 10:30", "collection": { "from": "2020-04-07T17:30:00.000Z", "to": "2020-04-07T18:30:59.999Z" }, "storeId": null, "logoUrl": null, "storeTimes": {}, "carrierCode": "DPD", "hasDisabledAccess": false, "bookingCode": "PLPRE1000/2020-04-07/*-*/*/*-*", "cutOffDateTime": "2020-04-07T17:00:00.000Z" } ] }
You can now display the option(s) under NOON
on your checkout page.