A space to discuss GraphQL queries, mutations, troubleshooting, throttling, and best practices.
I'm trying to create a refund via GraphQL API for specific line items in an order.
With the REST API we would just send a calculate request and use that to create the subsequent refund call. However the GraphQL API does not have a refund calculate query available.
So, how can I calculate what the correct refund should be for 2 line items in an order, including any taxes?
Thanks!
Hi, there
The GraphQL admin API doesn't require a refund to be "calculated" in a separate call like with REST, it uses the refundCreate mutation instead.
Yes, I'm aware of using the refundCreate mutation, however an amount still needs to be supplied for the refund transaction, so how is that correctly calculated, including the tax paid for the item?
At the moment I can only get the unit price of the item, but as that does not include tax the refund amount is inaccurate.