Hi Clover,
I'm trying to refund an Order using the Android SDK. I'm getting my Order:
Order order = orderConnector.getOrder(orderId);
I'm constructing a refund as:
Refund refund = new Refund();
refund.setAmount(order.getTotal());
I've tried both of:
orderConnector.refund(orderId, refund);
orderConnector.addRefund(orderId, refund);
But every time I get an exception
com.clover.sdk.v1.ForbiddenException: App doesn't have required permission
I can confirm that the App has all permissions granted in the App console and I have uninstalled/reinstalled several times to ensure that the permissions are being pulled through correctly.
Are you actually able to add refunds to an order using the SDK or would we need to use the REST API? (I know this is the case for adding payments for instance). Or is there something wrong with the way I'm constructing the Refund (does it have to be linked to a specific payment?)