/products/preorder-state
Get the pre-order state of a whole product. Useful for determining whether a particular product as a whole is on pre-order, for example when displaying a product in a collection grid.
Request query parameters:
api_key- Required. Your Purple Dot store's public API keyhandle- Required. The Shopify handle of the productcountry- Optional. The country shopper is in
Response:
datastate- One of:NO_OPEN_WAITLISTS- there is no live or scheduled Waitlist inside Purple Dot for this productAVAILABLE_IN_STOCK- when at least 1 variant isAVAILABLE_IN_STOCKON_PREORDER- when none of the variants areAVAILABLE_IN_STOCKbut at least 1 variant isON_PREORDERSOLD_OUT- when all variants areSOLD_OUT
waitlist- The product's waitlist ornullif there isn't an open waitlist.display_dispatch_date- The string that should be shown as the estimated dispatch date for the product.
product- The product that the variant belongs to.handle- The product's Shopify handle.
Examples:
curl --request GET \
--url 'https://www.purpledotprice.com/api/v1/products/preorder-state?api_key=<...>&handle=womens-white-sneakers'{
"meta": {
"result": "success"
},
"data": [
{
"state": "ON_PREORDER",
"waitlist": {
"id": "00fe49ba-8e43-4b10-9588-dccaa30f19ac",
"display_dispatch_date": "Estimated ship date 10–15 Jun",
"payment_plan_descriptions": null,
"selling_plan_id": null,
},
"product": {
"id": "4697179062404",
"product_code": "womens-white-sneakers"
}
}
]
}Last updated