A space to discuss GraphQL queries, mutations, troubleshooting, throttling, and best practices.
Hey Community! I need some help.
I am working with an app that uses Shopify's REST API. The app creates a new order once a return has been requested. If there is any discount in the original order, I need to reflect it on the new order to avoid inflation on the store's totals.
The new order needs a custom name to relate it to the old order, so I can't add a discount with a draft order since it does not allow to set a custom name for it. I tried using the GraphQL API to add the discount, but it is only possible when I create new items on an order and that will only work for me if I could replace the old items, which is not an option.
Is there any way to add an additional fee or any other negative value in order to adjust a paid total of my new order?