Payment

This API can be used to make a payment transaction. Supported transaction types are Sale, Void and Refund.

Please note that if a payment request also consists of RegisterParameters then the registration process will be executed by using the given values in case of the current registered terminal does not match the provided one. The merchant (sales) app do not need to add register parameters if the registration has been completed earlier with that credentials (MID, TID, Activation Code).

TransactionTypes

TransactionTypesMeaning
200Sales
300Refund
400Void

PaymentParameters

Field

Description

Value

amount

amount for payment

1000

orderId

client ref id for transaction

"9bda71c6-a4b1-414b-97ec-5d36873216f2"

transactionId

txnID for original transaction (only for void or refund txn requests)

300001231240

transactionType

transaction type indicator
For all possible values please see table 4.1

200

Call example

PaymentParameters paymentParameters = new PaymentParameters();
paymentParameters.setAmount(100);
paymentParameters.setTransactionId(12312312314); -> For Void and Refund Transactions Only!!
paymentParameters.setOrderId("9bda71c6-a4b1-414b-97ec-5d36873216f2");
paymentParameters.setTransactionType(200);
app2AppRequest.setPaymentParameters(paymentParameters);

ConfigParameters configParameters = new ConfigParameters();
configParameters.setDrawerMenuEnabled(true);
configParameters.setSalesButtonEnabled(true);
configParameters.setVoidButtonEnabled(true);
configParameters.setRefundButtonEnabled(true);
configParameters.setHistoryButtonEnabled(true);
configParameters.setSettingsButtonEnabled(false);
configParameters.setSettlementButtonEnabled(false);
configParameters.setTipScreenEnabled(false);
configParameters.setUserPhotoEnabled(false);
app2AppRequest.setConfigParameters(configParameters);

app2AppService.getPayment(app2AppRequest, eventListener);

Example request

{
amount":"1400",
"transactionType":"200",
"configParameters": {
          "drawerMenu": "1",
          "salesButton": "1",
          "voidButton": "1",
          "refundButton": "1",
          "historyButton": "1",
          "settingsButton": "1",
          "tipScreen":"0",
          "userPhoto":"1"

  },
  "registerParameters": {
            "terminalId": "16010129",
            "merchantId": "000000009041042",
            "activationCode": "testCode"
  },
  "customMessage":
  "\"installmentCount\":\"3\"}"
}

Example response

Success

{
 "transactionType": "200",
 "appVersion": "1.2.10",
 "amount": "5000",
 "maskedPan": "**** **** **** 0516",
 "transactionStatus": "success",
 "customMessage": "{\"isoStan\":\"001017\"}",
 "refusalCode": "00",
 "transactionDate": "29-11-2022 15:47:24",
 "transactionId": "233394301141"
}

Error

{
 "transactionType": "200",
 "transactionStatus": "decline",
 "refusalCode": "96"
}