Hello Friends,
Today, In this blog you will learn payment refund of the original transaction. In general, process, if the merchant wants to refund payment of any transaction so he can refund full payment or partial payment using transaction ID because refund process needs the payment method information to refund the money. You can more explore here https://developers.braintreepayments.com/reference/request/transaction/refund/php
Before the refund need some requirements
1) The transaction must be settled or settling.
2) Refund amount cannot be greater than the non-refunded amount of the original payment transaction.
3) Transaction cannot be refunded again after being completely refunded.
Full amount refunds process
$result = Braintree_Transaction::refund('the_transaction_id');
Partial refund process
$result = Braintree_Transaction::refund('a_transaction_id', '50.00');
$result->success
# true
$result->transaction->type
# 'credit'
$result->transaction->amount
0 Comment(s)