Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

A refund or void can be submitted via the API using the /txns endpoint. You can look up additional information about the /txns endpoint in theAPI Reference.

How to submit a refund or void a payment via the API

The process of submitting a card payment (sale) refund, an eCheck refund, or voiding an approved transaction is virtually the same. The only difference between these three options is the type value included in the request.

...

Code Block
{
	"fortxn": "t1_txn_5f6276c12269b0cc77adb44",
	"type": "5",
      	"amount": "100"
}

At a minimum, the only fields required to submit a refund/void are:

...

Other optional fields (e.g. fee, first [name], last [name] etc.) can be included in the API request, but they are not required for the refund/void to process successfully.

How to cancel an approved payment via the API

As covered elsewhere, the fundamental difference between voiding and canceling a payment is that canceling a transaction simply removes the approved payment from the Merchant’s daily batch, but does not actually reverse the authorization (as voiding does).

...