Shopify Function query Channel information

Shopify Function query Channel information

jakeshw
Shopify Partner
2 0 0

I am looking to query the channel that a buyer is coming from in order to change the discount based on which storefront the buyer is shopping from. Anyone know if this is possible? I haven't seen what graphql resource works for this in the shopify functions api here https://shopify.dev/docs/api/functions/reference/cart-checkout-validation/graphql

 

I have tried to add the channel and other shop data in my schema types, but getting an error in the console. see attached.

 

Screenshot 2024-09-13 at 11.13.48 AM.png

 

Any help would be appreciated. Thanks!

Replies 0 (0)