The actual process involved depends on the payment gateway being used. In version 2.2.6.0 a custom button has been introduced in the panel that processes returns. This feature allows you to extend the Admin App by adding your own administration functionality outside the standard Admin App. The following parameters are added to your defined URL to allow you to check security and/or operate on selected objects:
order_return_id - id of the OrderReturn object
order_id - id of the Order object
total_inc_tax - total amount of the Order
sess - session id
tx_id - gateway transaction id
Note that this button will not be visible unless you define the label to be non-empty in the Admin App Configuration Panel.