App reviews, troubleshooting, and recommendations
I am building one app which can be used by multiple retailers. And in that app there is one function called cart transform. Inside that function I want to access the customer tags or know whether a customer has particular tags. I know how to parameterise the input of the graphql query. But when you create/register this function this parameter is not as per the retailers. This is a complete list of tags that is published to my app and that is running for all the customers. But I want to parameterise this query based on the vendor. For different vendors the customer tags would be different. How to achieve that?
query RunInput($customerTag: [String!]) { cart { buyerIdentity { customer { amountSpent { amount } hasTags(tags: $customerTag) { hasTag tag } } } } }
I think you need to use app metafields to store the customer tags for each vendor. Your input uses the customer tag saved in the metafield. See here for more info: Metafields for input queries
2m ago Learn the essential skills to navigate the Shopify admin with confidence. T...
By Shopify Feb 12, 2025Learn how to expand your operations internationally with Shopify Academy’s learning path...
By Shopify Feb 4, 2025Hey Community, happy February! Looking back to January, we kicked off the year with 8....
By JasonH Feb 3, 2025