Unable to enable "combinesWith" flags through graphql api

Shopify Partner
7 1 6

Hi all,


I'm trying to programmatically create a price rule using GraphQL:

mutation {
combinesWith: {
productDiscounts: true
shippingDiscounts: true
And the price rule is created successfully, but with the checkboxes off in the admin (discounts tab) - screenshot attached.
Can please someone explain what's going on? 🙂
Want to sell more?
Check Zoorix
Reply 1 (1)

Shopify Staff
1322 217 457

Hey @ArielCabib - thanks for getting in touch. That is definitely odd. I wasn't able to replicate the issue on my end. Can you try using the discountCodeBasicCreate mutation and letting us know if the issue persists? The priceRuleCreate mutation has been deprecated and while it's still usable, we don't recommend relying on it for implementation - it's possible this could be related to that. 

If the issue persists with the discountCodeBasicCreate mutation, just reply back here and we'll definitely take a deeper look. If there is a use case for in terms of needing to continue to use the priceRuleCreate mutation, I'm happy to keep looking into this as well - just let us know!

Hope this helps! 

Al | Shopify Developer Support

Developer Support @ Shopify
- Was this reply helpful? Click Like to let us know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog