question

Devendra avatar image
Devendra asked ·

Information mapping on Sale response parameters

Hi All,
We are getting below response for Sale in case of POS system Xstore to clover mini integration but we have doubts on some response parameters which we need to store for future reference in our database. Could you please clear below doubts we have on this response?

1. Card number - does Clover provide full card number in response?
2. Bank reference number - is this same as "referenceId", and is there any use for this in future like in refund, post void process etc?
3. Token number - what is the use of this token? do we have to send this number in refund process or any other one of the ID which we are getting in below response?
4. What is the meaning of id, external id, reference id, external payment id, payment id, order id etc.?And which id will be used to retrieve a payment info in case of refund?
Payment{json='{"tender":{"instructions":null,"visible":true,"editable":false,"id":"6WHB6HGMQGS1W","label":"Credit Card","labelKey":"com.clover.tender.credit_card","opensCashDrawer":false,"enabled":true},"amount":1453,"lineItemPayments":null,"cardTransaction":{"vaultedCard":{"last4":"6668","cardholderName":"DISCOVER TEST CARD","first6":"601136","expirationDate":"1218","token":"7297162975886668"},"entryType":"SWIPED","last4":"6668","authCode":"OK0153","cardholderName":"DISCOVER TEST CARD","extra":{"authorizingNetworkName":"DISCOVER","cvmResult":"SIGNATURE"},"transactionNo":null,"cardType":"DISCOVER","state":"CLOSED","type":"AUTH","referenceId":"805700000284","token":"7297162975886668"},"cashTendered":null,"tipAmount":0,"transactionSettings":{"cardEntryMethods":34567,"signatureEntryLocation":null,"disableDuplicateCheck":null,"disableReceiptSelection":null,"autoAcceptSignature":null,"signatureThreshold":null,"autoAcceptPaymentConfirmations":null,"tippableAmount":1453},"cashbackAmount":null,"employee":{"id":"53E4RDTBSHHBG"},"result":"SUCCESS","offline":false,"taxRates":{"elements":[]},"createdTime":1519624513070,"externalPaymentId":"MR0ZYVPDTP53E","id":"WN3ES65K2S900","taxAmount":95,"order":{"id":"QKCDDF4E53662"}}', bundle=null, changeLog=null}
Thanks.
RefundSale
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.

justin.a avatar image
justin.a answered ·
Hello @Devendra,

1. No, Clover does not expose the full card number in our Payment object. This keeps you outside of PCI scope.

2. The referenceId contains information provided by the payment gateway, which is used to correlate the equivalent card transaction object on their side. There is not a future use for this in regards to refunds, post voids, etc.

3. The token field of the cardTransaction object is what you would provide when you would like to make a payment with a vaulted card. It is not used in the refund process.

4. The process of refunding a payment through our Remote Pay SDK requires you to set an orderId and paymentId when building out the RefundPayment object that gets passed into CloverConnector#refundPayment().

In the response you provided this would correspond to the values:

"id":"WN3ES65K2S900"  
"order":{"id":"QKCDDF4E53662"} 

The Payment#getId() andPayment#getOrder() are methods you can use to grab these values.

id / paymentId: identifier value for the Clover Payment class
orderId: identifier value for the Clover Order class
externalId / externalPaymentId: a value you would manually generate and set when building out a TransactionRequest that serves a number of different purposes:

  1. Your POS can use it to associate your Order and Payment models with Clover's Payment objects.
  2. It helps prevent accidental duplicate charges. The Clover device will reject back-to-back TransactionRequests that have identical ExternalIds.
  3. If you use universally unique ExternalIds on every transaction, they can be used as a last resort to help Clover Engineering investigate a particular transaction. Providing the transaction's Clover PaymentId will resolve issues quicker. However, in rare cases, your POS may know the ExternalId of a TransactionRequest, but not its Clover PaymentId (e.g., if connectivity between the POS and Clover device is dropped mid-transaction).
Please let me know if you have any further questions.

Regards,
Justin

Share
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.

knikhil avatar image
knikhil answered ·
how to get the above data?
Share
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.

Welcome to the
Clover Developer Community