Refunds
The screenshots and names of Components and Fields were taken on an installation that was using the ‘Accept Blue’ gateway. Other gateways screens and components will be similar but a bit different, and the names of the fields will be specific to the gateway you are configuring for (eg. ‘Authorize.net Credit Card Fields Component’ instead of ‘Accept Blue Credit Card Fields Component’)
Required Data
The Transaction ID
A payment, or the payment gateway log record attached to a payment.
The Amount to refund
A record, or entered into the screenflow field
Named Credential
API Name of the Credential you created with the Configuration steps above.
This will generally be constant, but can vary if you are using Paytram with multiple gateway accounts.
Logical next steps to do in your Screenflow
Create a new payment record with a negative value to offset the original payment, or adjust the original payment amount.
Show the error message response
Making a Refund
To Refund a payment, create a Refund Screen Flow using the Void/Refund Transaction Subflow. You must have the Transaction ID stored in a record, which is usually the Payment Record that was created at the time of the transaction.
- In your Flow, use the Get Records component to retrieve the record ID that contains the Transaction ID that you wish to refund (eg the Payment Record). 
- Add the Void/Refund Transaction Subflow to the canvas. 
- Map the following fields: 
- Info_DoRefund: Set as True 
- Info_NamedCredential: Type ‘AcceptBlue’ or the name of the External Credential 
- Info_TransactionID: Select Transaction ID for the payment from the Get Records component. 
- Refund_Amount: The amount to refund (it must be equal to or less than the original transaction amount. 
- Refund_Description: Optional 
 
- Add a ‘WasError’ decision to continue to the next step in your Flow. If there was no error, for example, you might opt to mark the Payment Record as Refunded in Salesforce or you might choose to create a new, negative value record. If there is an error, you can use the error message you created to display to the user. 
Last updated