Compare commits

...

1 Commits

Author SHA1 Message Date
af151fd389 retrieve CardType from the ChepDNA response 2026-05-13 16:48:25 +01:00
4 changed files with 10 additions and 5 deletions

View File

@ -29,7 +29,7 @@ import (
) )
const ( const (
buildVersion = "1.2.6" buildVersion = "1.2.7"
serviceName = "hardlink" serviceName = "hardlink"
pollingFrequency = 8 * time.Second pollingFrequency = 8 * time.Second
) )

View File

@ -155,8 +155,9 @@ func BuildPreauthRedirectURL(result map[string]string) (string, bool) {
func BuildSuccessURL(result map[string]string) string { func BuildSuccessURL(result map[string]string) string {
q := url.Values{} q := url.Values{}
q.Set("CardNumber", hex.EncodeToString([]byte(result[types.PAN_MASKED]))) q.Set("CardNumber", hex.EncodeToString([]byte(result[types.PanMasked])))
q.Set("ExpiryDate", hex.EncodeToString([]byte(result[types.EXPIRY_DATE]))) q.Set("CardType", hex.EncodeToString([]byte(result[types.CardType])))
q.Set("ExpiryDate", hex.EncodeToString([]byte(result[types.ExpiryDate])))
q.Set("TxnReference", result[types.Reference]) q.Set("TxnReference", result[types.Reference])
q.Set("CardHash", hex.EncodeToString([]byte(result[types.CardHash]))) q.Set("CardHash", hex.EncodeToString([]byte(result[types.CardHash])))
q.Set("CardReference", hex.EncodeToString([]byte(result[types.CardReference]))) q.Set("CardReference", hex.EncodeToString([]byte(result[types.CardReference])))

View File

@ -2,6 +2,9 @@
builtVersion is a const in main.go builtVersion is a const in main.go
#### 1.2.7 - 13 May 2026
retrieve CardType from the ChepDNA response
#### 1.2.6 - 20 April 2026 #### 1.2.6 - 20 April 2026
added the second attempt to send the card to the encoder after 6 seconds added the second attempt to send the card to the encoder after 6 seconds

View File

@ -39,8 +39,9 @@ const (
ReceiptDataMerchant = "RECEIPT_DATA_MERCHANT" ReceiptDataMerchant = "RECEIPT_DATA_MERCHANT"
ReceiptDataCardholder = "RECEIPT_DATA_CARDHOLDER" ReceiptDataCardholder = "RECEIPT_DATA_CARDHOLDER"
Reference = "REFERENCE" Reference = "REFERENCE"
PAN_MASKED = "PAN_MASKED" CardType = "CARD_SCHEME_ID"
EXPIRY_DATE = "EXPIRY_DATE" PanMasked = "PAN_MASKED"
ExpiryDate = "EXPIRY_DATE"
TransactionResult = "TRANSACTION_RESULT" TransactionResult = "TRANSACTION_RESULT"
TransactionType = "TRANSACTION_TYPE" TransactionType = "TRANSACTION_TYPE"
TransactionState = "TRANSACTION_STATE" TransactionState = "TRANSACTION_STATE"