question

gnibloop avatar image
gnibloop asked David Marginian Deactivated edited

Remote Pay IOS SDK can't get refund object from RetrievePaymentResponse

In case of we successfully issue a refund to a payment but later want to find out this payment 's refunded status. We use RetrievePaymentRequest but inside response.payment, the refund object (should be array) is nil. So we just can't tell whether this payment has been refunded or not. Is it a bug?
Paymentssemi-integrationsRefund
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 edited
The retrievePayment API is a light-weight API designed to retrieve just the payment data (not associated data) from the device.

The most reliable way to get the refunds for a payment is by using the REST API - https://community.clover.com/questions/16044/refu...
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.

gnibloop avatar image gnibloop commented ·

David, it's not time issue. It was long enough (more than 20 minutes) and the refund status has been shown up in "Transactions" app of clover long time ago. Right now we are reluctant to use REST API because our pos app is ios based and can't be installed into clover device and that's why we talk to remote pay network app to communicate with clover device. Thus it would be really difficult for us to get API token for each merchant pro grammatically. (We have to go through every merchant to ask them creating API token manually through their dashboard, which is really painful). Since in the API document from clover STATES that the "refunds" is an array object inside "payment" object, I believe it's a bug need to be fixed in your ios SDK to make it pass correct refund data. Thanks.

0 Likes 0 ·
David Marginian avatar image David Marginian ♦♦ gnibloop commented ·

I will look into it and create an internal issue if necessary.

Right now we are reluctant to use REST API because our pos app is ios based and can't be installed into clover device and that's why we talk to remote pay network app to communicate with clover device. 

What? You can make a REST call from your iOS POS. You would NOT be using merchant tokens you would be following our OAUTH2 process. Your app would have to follow the flow (require the merchant to login, etc.) and then you could securely store the token (1 year expiration).

0 Likes 0 ·
gnibloop avatar image gnibloop David Marginian ♦♦ commented ·

David, good to know we can get 1 year token from OAuth process. However,almost all of our customers (restaurant owners) are just using clover device as their credit card processing hardware. All they do every day are charging the card, close out on deivce and then check the balance from monthly statement (paper mail). 90% of them never logon clover dashboard before. They don't know the login process and they wont even bother using it. So to get them authorize our app through oauth process we have to educate them how to logon to their account. Anyway, it's not a good trade off for us to just get refund status of a payment. It's a pretty simple demand and I just hope your ios SDK can have it in future version. Thanks a lot.

0 Likes 0 ·
Show more comments

Welcome to the
Clover Developer Community