PreferenceDeliveryMethodType

Good day,
Is there a way to expose this variable within Shopify extension APIs?

Our specific case requires that we show a “pickup helper” that helps customers sort product availability in their cart during checkout but only for “PICKUP” method.

I’ve tried to use “useDeliveryGroups” by checking if it does not return any “deliveryOptions” we would render the said helper.

Problem is, this can also apply to standard shipping.
Example case is when a customer has not filled in the shipping address, this would trigger our “Pickup Helper” to render.

It would be great if we can have a solution or an alternative to this.
Thank you.

Hi :wave:

I’m not familiar with the concept of delivery, but you can use storefront API in checkout extension.

check the below link for more details.

Hello :smiley:

I did try the Storefront API, though there were problems.
First, querying the cart requires the Cart Token.

Correct me if I’m wrong but I was not able to find it within the UI Extension APIs.

Do you perhaps know how to fetch it within the extension?

cart - Storefront API

Second, when I manually fetched the cart session with a static token, there was no value returned.