question

Guille Bauza avatar image
Guille Bauza asked David Marginian Deactivated commented

Error at RefundPaymentReponse PaymentConnector

I was making a Payment with Cash on my own App and all good. but when I try to refund it says fail, and still it registers the refund request successfully...

Does anyone know what could do this?

Request:

RefundPaymentRequest refundPaymentRequest = new RefundPaymentRequest();
refundPaymentRequest.setAmount(total_amount);
refundPaymentRequest.setPaymentId(wpsTransaction.getPayment_id());
refundPaymentRequest.setOrderId(wpsTransaction.getOrder_id());
refundPaymentRequest.setDisablePrinting(true);
refundPaymentRequest.setDisableReceiptSelection(true);
paymentConnector.refundPayment(refundPaymentRequest);

Response:

{"success":false,"result":"FAIL","message":"Refund failed","refund":null}

SANDBOX ENVIRONMENT


Regards

OrdersPaymentConnectorRefund
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

1 Answer

·
David Marginian avatar image
David Marginian Deactivated answered David Marginian Deactivated commented

"This refund would make the order's total refunded amount greater than the original order's amount.". What doesn't make sense about that? You can't perform a refund for more than the original order amount.

6 comments
10 |2000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Guille Bauza avatar image Guille Bauza commented ·

I'm I copied the wrong response, still it says sucess false, refund failed when it did in fact refunded.

0 Likes 0 ·
David Marginian avatar image David Marginian ♦♦ Guille Bauza commented ·

I can't help you if you can't provide accurate details. What is the real response? What environment are you doing this in and include the payment id in a private (moderators only) post.

0 Likes 0 ·
Guille Bauza avatar image Guille Bauza David Marginian ♦♦ commented ·

I updated the question details, please review and advise, thank you

{"success":false,"result":"FAIL","message":"Refund failed","refund":null}

Payment ID: 4JAT5XFTJASQA

Order ID: 1BAAXKQNFXR1Y

Refund ID: 8PYX9W4E2MSSG

Merchant ID: 60NVSS3NE2RV1

SANDBOX ENVIRONMENT


Regards.

0 Likes 0 ·
Show more comments

Write an Answer

Hint: Notify or tag a user in this post by typing @username.

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Welcome to the
Clover Developer Community