question

vishal388 avatar image
vishal388 asked David Marginian answered

Error in processing Refund

Hello,


I am using Remote Cloud SDK in sandbox environment and facing an error when processing a refund for the payment (that was done less than $50).


What is interesting is that when original Sale is > $50, there is no issue in processing refund for amount less than $50.


Here are the logs I see in console for refund transaction:

Can you please let me know what I am doing wrong in refund request?

debug Sending: {"id":"6","type":"COMMAND","packageName":"com.clover.remote.protocol.websocket","method":"REFUND_REQUEST","payload":"{\"method\":\"REFUND_REQUEST\",\"messageId\":\"6\",\"version\":2,\"fullRefund\":false,\"amount\":4002,\"orderId\":\"NTYVGCERCXY8G\",\"paymentId\":\"J0V6ZR5Q2YAGE\"}","remoteSourceSDK":"com.clover.cloverconnector.cloud:4.0.5","remoteApplicationID":"RPXDGYZC339GM","version":2}
POS?v=nF68Nru6lYrD3pJTh4zNWiFr9gUIb-4tg3g4erMPtJM1:40386 debug DefaultCloverDevice, handling remote message receipt.  Message: {"attachment":null,"attachmentEncoding":null,"attachmentUri":null,"authentication":null,"directed":false,"fragmentIndex":null,"id":null,"lastFragment":null,"method":null,"packageName":"com.clover.remote.protocol.websocket","payload":null,"remoteApplicationID":null,"remotePayCompatibilityVersion":1,"remoteSourceSDK":null,"type":"PING","version":2}.
POS?v=nF68Nru6lYrD3pJTh4zNWiFr9gUIb-4tg3g4erMPtJM1:40386 debug Sending: {"type":"PONG","packageName":"com.clover.remote.protocol.websocket","remoteSourceSDK":"com.clover.cloverconnector.cloud:4.0.5","remoteApplicationID":"RPXDGYZC339GM"}
POS?v=nF68Nru6lYrD3pJTh4zNWiFr9gUIb-4tg3g4erMPtJM1:40386 debug DefaultCloverDevice, handling remote message receipt.  Message: {"attachment":null,"attachmentEncoding":null,"attachmentUri":null,"authentication":null,"directed":false,"fragmentIndex":null,"id":null,"lastFragment":null,"method":null,"packageName":"com.clover.remote.protocol.websocket","payload":null,"remoteApplicationID":null,"remotePayCompatibilityVersion":1,"remoteSourceSDK":null,"type":"PING","version":2}.
POS?v=nF68Nru6lYrD3pJTh4zNWiFr9gUIb-4tg3g4erMPtJM1:40386 debug Sending: {"type":"PONG","packageName":"com.clover.remote.protocol.websocket","remoteSourceSDK":"com.clover.cloverconnector.cloud:4.0.5","remoteApplicationID":"RPXDGYZC339GM"}
POS?v=nF68Nru6lYrD3pJTh4zNWiFr9gUIb-4tg3g4erMPtJM1:40386 debug DefaultCloverDevice, handling remote message receipt.  Message: {"attachment":null,"attachmentEncoding":null,"attachmentUri":null,"authentication":null,"directed":false,"fragmentIndex":null,"id":"8913","lastFragment":null,"method":"ACK","packageName":"com.clover.remote.protocol.websocket","payload":"{\"METHOD_TYPE\":\"ACK\",\"method\":\"ACK\",\"reason\":null,\"rejected\":false,\"sourceMessageId\":\"6\",\"sourceMethod\":\"REFUND_REQUEST\"}","remoteApplicationID":"com.clover.remote.protocol.websocket:1.0-356","remotePayCompatibilityVersion":1,"remoteSourceSDK":"com.clover.internal.apps","type":"COMMAND","version":2}.
POS?v=nF68Nru6lYrD3pJTh4zNWiFr9gUIb-4tg3g4erMPtJM1:40386 debug DefaultCloverDevice, handling remote message receipt.  Message: {"attachment":null,"attachmentEncoding":null,"attachmentUri":null,"authentication":null,"directed":false,"fragmentIndex":null,"id":"8914","lastFragment":null,"method":"REFUND_RESPONSE","packageName":"com.clover.remote.protocol.websocket","payload":"{\"code\":\"FAIL\",\"message\":\"This payment can no longer be refunded back to the card. Refund customer via manual refund or in cash.\",\"orderId\":\"NTYVGCERCXY8G\",\"paymentId\":\"J0V6ZR5Q2YAGE\",\"reason\":\"FAIL\",\"method\":\"REFUND_RESPONSE\",\"version\":1}","remoteApplicationID":"com.clover.remote.protocol.websocket:1.0-356","remotePayCompatibilityVersion":1,"remoteSourceSDK":"com.clover.internal.apps","type":"COMMAND","version":2}.


semi-integrationsRefund
10 |2000 characters needed characters left characters exceeded

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

1 Answer

· Write an Answer
David Marginian avatar image
David Marginian answered

Sandbox uses an emulated gateway that has some pecularities, and this is probably one of them. I wouldn't worry about it unless it is blocking you.

10 |2000 characters needed characters left characters exceeded

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

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