Hello,
I am trying to sent partial refund but get error code 5 "A valid amount is required."
$creditCard = new AnetAPI\CreditCardType();
$creditCard->setCardNumber($lastFourDigits);
$creditCard->setExpirationDate("XXXX");
$paymentOne = new AnetAPI\PaymentType();
$paymentOne->setCreditCard($creditCard);
$transactionRequest = new AnetAPI\TransactionRequestType();
$transactionRequest->setTransactionType('refundTransaction');
$transactionRequest->setAmount(2.4);
$transactionRequest->setPayment($paymentOne);
$transactionRequest->setRefTransId($transaction_id);Original transaction amount $8.39.
There are no filters for the size of the payment.
With a full refund, this code works.
What should I do for refund an amount that is less than that of orginal transaction amount?
Thank you in advance
05-30-2021 12:26 AM