Shipping discount shopify functions API

Shopify Partner
5 1 2

I'm trying to build a discount app which gives free shipping on a certain shipping method when items with a certain tag are in the cart.


Currently, I received a cart.deliveryGroups.deliveryOptions.handle handle from on function input, and I applied a discount using discout.targets.deliveryOption.handle and it works great because I basically hardcoded handle variable in my code.


Questions is how can I query what deliveryOptions handles are available via admin API when I built UI for my app?


I want obviously user to be able to select which delivery option he wants to discount, and in order to do it I need to know which ones are available and what their handles are.



Replies 0 (0)