refund method
Triggers a refund (credit). Pass originalTransactionId for a
referenced refund. Must be activated by hobex; the terminal asks for a
password.
Implementation
Future<TransactionResponse> refund({
required num amount,
String? originalTransactionId,
String? reference,
String? transactionId,
String? currency,
String? language,
}) {
final body = _txBody(
amount: amount,
reference: reference,
transactionId: transactionId ?? _newTransactionId(),
currency: currency,
language: language,
originalTransactionId: originalTransactionId,
);
return _sendTransaction('POST', 'api/transaction/refund', body);
}